diff --git a/CHANGELOG.md b/CHANGELOG.md index 293868e..e3f125a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +## 0.9.1 01/24/2018 +* Add --format to silenced list + ## 0.9.0 01/18/2018 * Add token authorization diff --git a/lib/sensu-cli/cli.rb b/lib/sensu-cli/cli.rb index 58b44b1..0886b97 100644 --- a/lib/sensu-cli/cli.rb +++ b/lib/sensu-cli/cli.rb @@ -328,8 +328,10 @@ def silenced opt :subscription, 'The subscription entries to return', :short => 's', :type => :string opt :limit, 'The number of aggregates to return', :short => 'l', :type => :string opt :offset, 'The number of aggregates to offset before returning', :short => 'o', :type => :string + opt :format, 'Available formats; single, table, json', :short => 'f', :type => :string end Trollop::die :offset, 'Offset depends on the limit option --limit ( -l )'.color(:red) if p[:offset] && !p[:limit] + Trollop::die :format, 'Available optional formats: single, table, json'.color(:red) if p[:format] != 'table' && p[:format] != 'single' && p[:format] != 'json' && p[:format] { :command => 'silenced', :method => 'Get', :fields => p } when 'create' p = Trollop::options do diff --git a/lib/sensu-cli/version.rb b/lib/sensu-cli/version.rb index 4a3904e..a38d1d0 100644 --- a/lib/sensu-cli/version.rb +++ b/lib/sensu-cli/version.rb @@ -1,3 +1,3 @@ module SensuCli - VERSION = '0.9.0' + VERSION = '0.9.1' end