From 36514fc748dbc8fff202e8b6c6992c53b479fef4 Mon Sep 17 00:00:00 2001 From: eholtam Date: Thu, 7 Jan 2016 10:44:35 -0600 Subject: [PATCH] Fixed manifestutil traceback if no subcommands are given In manifestutil if no subcommands are given manifestutil exits with a trackback. I added a check to see if the number of subcommands is < 1 and to list the available subcommands if so. --- code/client/manifestutil | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/code/client/manifestutil b/code/client/manifestutil index f0fc1af0..714808aa 100755 --- a/code/client/manifestutil +++ b/code/client/manifestutil @@ -882,6 +882,12 @@ def setUpTabCompleter(): def handleSubcommand(args): '''Does all our subcommands''' + # check if any arguments are passed. + # if not, list subcommands. + if len(args) < 1: + help(args) + return 2 + # strip leading hyphens and # replace embedded hyphens with underscores # so '--add-pkg' becomes 'add_pkg'