diff options
author | elijah <elijah@riseup.net> | 2013-02-02 01:43:03 -0800 |
---|---|---|
committer | elijah <elijah@riseup.net> | 2013-02-02 01:43:03 -0800 |
commit | 05494b7861e7883d273d42c30a7bc799c5384873 (patch) | |
tree | 32fc8776a0e25ff257e423ac4e0b4f61abc7cf6c /lib/leap_cli/commands | |
parent | d0247e01c08cf2ce0fefb5808f11c824b681d61f (diff) |
logging - output of leap command is now additionally sent to --log=FILE command line switch or @log value in Leapfile.
Diffstat (limited to 'lib/leap_cli/commands')
-rw-r--r-- | lib/leap_cli/commands/pre.rb | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/lib/leap_cli/commands/pre.rb b/lib/leap_cli/commands/pre.rb index 346814b..26dce40 100644 --- a/lib/leap_cli/commands/pre.rb +++ b/lib/leap_cli/commands/pre.rb @@ -6,10 +6,15 @@ module LeapCli module Commands desc 'Verbosity level 0..2' - arg_name 'level' + arg_name 'LEVEL' default_value '1' flag [:v, :verbose] + desc 'Override default log file' + arg_name 'FILE' + default_value nil + flag :log + desc 'Display version number and exit' switch :version, :negatable => false @@ -40,6 +45,11 @@ module LeapCli end # + # set log file + # + LeapCli.log_file = global[:log] || LeapCli.leapfile.log + + # # load all the nodes everything # manager |