'elm --help' output could be improved
Qqwy opened this issue · 1 comments
Qqwy commented
When running $ elm --help
to see how the executable can be used...
Expected output
Elm Platform 0.18.0 - a way to run all Elm tools
Usage: elm <command> [<args>]
Available commands include:
make Compile an Elm file or project into JS or HTML
package Manage packages from <http://package.elm-lang.org>
reactor Develop with compile-on-refresh and time-travel debugging
repl A REPL for running individual expressions
You can learn more about a specific command by running things like:
elm make --help
elm package --help
elm <command> --help
In all these cases we are simply running 'elm-<command>' so if you create an
executable named 'elm-foobar' you will be able to run it as 'elm foobar' as
long as it appears on your PATH.
Actual output
Could not find command `--help`. Maybe there is a typo?
Default commands include:
make Compile an Elm file or project into JS or HTML
package Manage packages from <http://package.elm-lang.org>
reactor Develop with compile-on-refresh and time-travel debugging
repl A REPL for running individual expressions
When you try to run the command `--help` we actually search for an
executable named elm---help. Are you able to run elm---help?
Is it on your PATH?
While the information is there, clearly the output is confusing since --help
is treated as the name of an executable.
I think it would help if we could check for this flag (and possibly -h
and maybe also plain the word help
) directly, especially since --help
is a recognized flag to see more information about each of these separate commands (like elm-package --help
).
evancz commented
It should be nicer with 0.19