--help should work in CLI
This commit is contained in:
parent
aa0d848ba5
commit
e6256d0178
|
@ -42,8 +42,13 @@ require "middleman-core/extensions"
|
|||
|
||||
require "middleman-core/cli"
|
||||
|
||||
# Change flag to a module
|
||||
ARGV.unshift("help") if ARGV.delete("--help")
|
||||
|
||||
# Default command is server
|
||||
ARGV.unshift("server") if ARGV.length < 1 || ARGV.first.include?("-")
|
||||
if ARGV[0] != "help" && (ARGV.length < 1 || ARGV.first.include?("-"))
|
||||
ARGV.unshift("server")
|
||||
end
|
||||
|
||||
# Start the CLI
|
||||
if ENV["MM_ROOT"]
|
||||
|
|
Loading…
Reference in a new issue