class MagicReveal::Cli::Options
Command line options
Attributes
command[RW]
project[RW]
Public Instance Methods
parse(args)
click to toggle source
# File lib/magic_reveal/cli/options.rb, line 14 def parse(args) # rubocop:disable MethodLength case args.first when 'new' if args.length != 2 @command = :help else @command = :new @project = args[1] end when 'force-reload' @command = :force_reload when 'start' @command = :start when 'static' @command = :static else # including help @command = :help end end
program_name()
click to toggle source
# File lib/magic_reveal/cli/options.rb, line 10 def program_name @program_name ||= File.basename($PROGRAM_NAME) end