.bundle/gems/mercenary-0.3.4/lib/mercenary/program.rb
# Public: Run the program
#
# argv - an array of string args (usually ARGV)
#
# Returns nothing
Run the program
argv - an array of string args (usually ARGV)

Returns nothing
Run the program argv - an array of string args ( usually ARGV ) Returns nothing
def go(argv)
      logger.debug("Using args passed in: #{argv.inspect}")
      cmd = nil
      @optparse = OptionParser.new do |opts|
        cmd = super(argv, opts, @config)
      end
      @optparse.parse!(argv)
      logger.debug("Parsed config: #{@config.inspect}")
      begin
        cmd.execute(argv, @config)
      rescue => e
        if cmd.trace
          raise e
        else
          logger.error e.message
          abort
        end
      end
    end
def go ( argv ) logger . debug ( "Using args passed in: #{argv.inspect}" ) cmd = nil @optparse = OptionParser . new do | opts | cmd = super ( argv , opts , @config ) end @optparse . parse! ( argv ) logger . debug ( "Parsed config: #{@config.inspect}" ) begin cmd . execute ( argv , @config ) rescue => e if cmd . trace raise e else logger . error e . message abort end end end
Public: Run the program
argv - an array of string args (usually ARGV)
Public : Run the program argv - an array of string args ( usually ARGV )
argv
<not_specific>