lib/heirloom/cli/destroy.rb in heirloom-0.2.0 vs lib/heirloom/cli/destroy.rb in heirloom-0.3.0.rc1

- old
+ new

@@ -2,13 +2,16 @@ module CLI class Destroy def initialize @opts = read_options + @logger = HeirloomLogger.new :log_level => @opts[:level] + exit 1 unless CLI::Shared.valid_options? :provided => @opts, + :required => [:name, :id], + :logger => @logger @name = @opts[:name] @id = @opts[:id] - @logger = HeirloomLogger.new :log_level => @opts[:level] @archive = Archive.new :name => @name, :id => @id, :logger => @logger end @@ -30,11 +33,11 @@ heirloom destroy -n NAME -i ID [-l LOG_LEVEL] EOS opt :help, "Display Help" opt :id, "ID of the archive to display.", :type => :string - opt :level, "Log level.", :type => :string, - :default => 'info' + opt :level, "Log level [debug|info|warn|error].", :type => :string, + :default => 'info' opt :name, "Name of archive.", :type => :string end end end end