From 03293d88b085bfc8d5895b5feef943ad5ff35964 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Wed, 15 Nov 2017 15:38:59 -0500 Subject: [PATCH] Have nodeeventlog print help on incorrect arguments --- confluent_client/bin/nodeeventlog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/confluent_client/bin/nodeeventlog b/confluent_client/bin/nodeeventlog index 4614f81b..d5245e8d 100755 --- a/confluent_client/bin/nodeeventlog +++ b/confluent_client/bin/nodeeventlog @@ -45,9 +45,15 @@ except IndexError: sys.exit(1) client.check_globbing(noderange) deletemode = False +if len(sys.argv) > 3: + argparser.print_help() + sys.exit(1) if len(sys.argv) == 3: if sys.argv[2] == 'clear': deletemode = True + else: + argparser.print_help() + sys.exit(1) session = client.Command() exitcode = 0