Class: Mu::Command::Curl

Inherits:
Mu::Command show all
Defined in:
lib/mu/command/curl.rb

Constant Summary

Constants inherited from Mu::Command

Api

Constants included from Helper

Helper::ESCAPES

Instance Attribute Summary

Attributes inherited from Mu::Command

#options, #opts

Instance Method Summary collapse

Methods inherited from Mu::Command

#initialize

Methods included from Helper

#ask, #bin2hex, #error, #escape, #format_float, #get_file_as_string_array, #make_xml, #msg, #shift, #to_boolean

Constructor Details

This class inherits a constructor from Mu::Command

Instance Method Details

#authorize_error(e) ⇒ Object



8
9
10
11
12
13
# File 'lib/mu/command/curl.rb', line 8

def authorize_error e
    base_url = "#{e.scheme}://#{e.host}:#{e.port}"
    puts
    error "You haven't verified that you are the dev/ops for #{e.host}"
    puts
end

#cmd_help(argv) ⇒ Object



4
5
6
# File 'lib/mu/command/curl.rb', line 4

def cmd_help argv
    help
end

#cmd_run(argv) ⇒ Object Also known as: cmd_default



15
16
17
18
19
20
21
22
23
24
25
# File 'lib/mu/command/curl.rb', line 15

def cmd_run argv
    args = parse_cli argv
    if args['help']
        return help
    end

    if not args['pattern']
        verify args
        return
    end
end