Slim down help command.

This commit is contained in:
Parker Moore 2014-08-06 21:20:39 -04:00
parent a0f449d613
commit 23515acc31
1 changed files with 2 additions and 8 deletions

View File

@ -5,8 +5,8 @@ module Jekyll
def init_with_program(prog)
prog.command(:help) do |c|
c.syntax 'help <command>'
c.description 'Show the help for'
c.syntax 'help [subcommand]'
c.description 'Show the help message, optionally for a given subcommand.'
c.action do |args, _|
if args.empty?
@ -18,12 +18,6 @@ module Jekyll
end
end
def usage_message(prog, cmd)
Jekyll.logger.error "Error:", "No command specified."
Jekyll.logger.warn "Usage:", cmd.syntax
Jekyll.logger.info "Valid commands:", prog.commands.keys.join(", ")
end
end
end
end