diff --git a/lib/acclaim/command/help.rb b/lib/acclaim/command/help.rb index 556c928..6e423ea 100644 --- a/lib/acclaim/command/help.rb +++ b/lib/acclaim/command/help.rb @@ -34,14 +34,17 @@ def create(base_command, options = {}) Class.new(base_command).tap do |help_command| add_options_to! base_command, help_command, options if options.options? true + help_command.when_called do # TODO: implement a way to specify a command to the help option # and command. # display_for options.command || args.pop help_options = Ribbon.merge({ io: help_command.io }, options) + display_for base_command.root, help_options exit end + base_command.const_set :Help, help_command end end