-
-
Save jtimberman/78338 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TestCLI | |
include Mixlib::CLI | |
option :config_file, | |
:short => "-c CONFIG", | |
:long => "--config CONFIG", | |
:default => 'config.rb', | |
:description => "The configuration file to use" | |
option :log_level, | |
:short => "-l LEVEL", | |
:long => "--log_level LEVEL", | |
:description => "Set the log level (debug, info, warn, error, fatal)", | |
:required => true, | |
:proc => nil | |
option :help, | |
:short => "-h", | |
:long => "--help", | |
:description => "Show this message", | |
:on => :tail, | |
:boolean => true, | |
:show_options => true, | |
:exit => 0 | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment