From 0491fa1dda425f5d8dd19b94b95a798a5476e310 Mon Sep 17 00:00:00 2001 From: Michael DeHaan Date: Tue, 28 Feb 2012 04:02:29 -0500 Subject: [PATCH] have command module raise an error if no arguments are supplied --- command | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/command b/command index fbef7944d99..7d3c2f32bd3 100755 --- a/command +++ b/command @@ -28,6 +28,13 @@ import sys import datetime 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:] startd = datetime.datetime.now()