Method: AppStack::CliOptions#initialize

Defined in:
lib/app_stack/cli_options.rb

#initialize(argv = ARGV) ⇒ CliOptions

Returns a new instance of CliOptions.



11
12
13
14
15
16
17
18
# File 'lib/app_stack/cli_options.rb', line 11

def initialize(argv = ARGV)
  parse_opt!(argv)
  case argv.size
  when 1 then self.conf_file = argv.shift
  when 0 then self.conf_file = nil
  else fail "too many configuration files (#{argv.join(', ')})."
  end
end