have command module raise an error if no arguments are supplied
This commit is contained in:
parent
1427ade3af
commit
19fdb7305d
1 changed files with 7 additions and 0 deletions
|
@ -28,6 +28,13 @@ import sys
|
||||||
import datetime
|
import datetime
|
||||||
import traceback
|
import traceback
|
||||||
|
|
||||||
|
if len(sys.argv) == 1:
|
||||||
|
print json.dumps({
|
||||||
|
"failed" : True,
|
||||||
|
"msg" : "at least a command name is required"
|
||||||
|
})
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
args = sys.argv[1:]
|
args = sys.argv[1:]
|
||||||
startd = datetime.datetime.now()
|
startd = datetime.datetime.now()
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue