diff --git a/README.md b/README.md index 054c6bb8..c6f29a21 100644 --- a/README.md +++ b/README.md @@ -58,4 +58,3 @@ This should ideally be part of `gulp`, however there doesn't seems to be any plu - Some interactive widgets don't work on [Cygwin](https://cygwin.com/). If you're running Windows, it's preferrable that you use `cmd.exe`. - Most commands require an `` argument, however [Commander](https://github.com/tj/commander.js) refuses to show that in the help page. This will be fixed soon. -- If you make a typo when writing a command, or run the app without any command, nothing is shown. This will be fixed soon. diff --git a/lib/cli/cli.coffee b/lib/cli/cli.coffee index ff3f7065..a8108c3a 100644 --- a/lib/cli/cli.coffee +++ b/lib/cli/cli.coffee @@ -87,9 +87,14 @@ exports.addResource = (options = {}) -> exports.parse = (argv) -> + # Matches unknown commands exports.addCommand command: '*' action: -> program.outputHelp() program.parse(argv) + + # Show help if no command is passed + if _.isEmpty(program.args) + program.outputHelp()