lib/godofwar/payloads.rb
#
# list_payloads_tree List all available payloads using folder name conversion
#
# @return [Array]
#
list_payloads_tree List all available payloads using folder name conversion
list_payloads_tree List all available payloads using folder name conversion
def list_payloads_tree
      payloads.map do |payload|
        if payload.conf["true"]
          payload.conf = payload.conf.values.first
        else
          payload.conf["false"] = 'No Settings required!'
        end
        "├── " + "#{payload.name}\n".bold   +
        "│   └── Information:\n"        +
        "│       ├── Description: #{payload.desc}\n" +
        "│       ├── OS:          #{payload.os}\n"   +
        "│       ├── Defaults:    #{payload.conf}\n" +
        "│       ├── Usage:       #{payload.url}\n"  +
        "│       ├── References:  #{payload.ref}\n"  +
        "│       └── Local Path:  #{payload.path}"
      end
    end
def list_payloads_tree payloads . map do | payload | if payload . conf [ "true" ] payload . conf = payload . conf . values . first else payload . conf [ "false" ] = 'No Settings required!' end "├── " + "#{ a load.name}\n".bold   + "│   └── Information:\n"        + "│       ├── Description: #{payload.desc}\n" + "│       ├── OS:          #{payload.os}\n"   + "│       ├── Defaults:    #{payload.conf}\n" + "│       ├── Usage:       #{payload.url}\n"  + "│       ├── References:  #{payload.ref}\n"  + "│       └── Local Path:  #{payload.path}" end end
list_payloads_tree List all available payloads using folder name conversion
list_payloads_tree List all available payloads using folder name conversion
None
Array