diff --git a/lib/hammer_cli_katello.rb b/lib/hammer_cli_katello.rb index 76907eaf..66da0c2d 100644 --- a/lib/hammer_cli_katello.rb +++ b/lib/hammer_cli_katello.rb @@ -60,6 +60,12 @@ def self.exception_handler_class 'hammer_cli_katello/lifecycle_environment' ) + HammerCLI::MainCommand.lazy_subcommand("content-view-environment", + _("Manipulate content view environments"), + 'HammerCLIKatello::ContentViewEnvironment', + 'hammer_cli_katello/content_view_environment' + ) + HammerCLI::MainCommand.lazy_subcommand("product", _("Manipulate products"), 'HammerCLIKatello::Product', 'hammer_cli_katello/product' diff --git a/lib/hammer_cli_katello/content_view_environment.rb b/lib/hammer_cli_katello/content_view_environment.rb new file mode 100644 index 00000000..b418f43b --- /dev/null +++ b/lib/hammer_cli_katello/content_view_environment.rb @@ -0,0 +1,27 @@ +module HammerCLIKatello + class ContentViewEnvironment < HammerCLIKatello::Command + resource :content_view_environments + + class ListCommand < HammerCLIKatello::ListCommand + output do + field :id, _("Id") + field :label, _("Label") + from :environment do + field :name, _("Lifecycle Environment") + end + from :content_view do + field :name, _("Content View") + end + field :default, _("Default") + field :hosts_count, _("Hosts Count") + from :organization do + field :name, _("Organization") + end + end + + build_options + end + + autoload_subcommands + end +end