From 4f1c1d90e5cd459bf40543664b502d387ff81eb6 Mon Sep 17 00:00:00 2001 From: Jimmy Brisson Date: Wed, 12 Sep 2018 11:05:42 -0500 Subject: [PATCH] `mbed dm`: Remove references to internal script from help ### Description Now that we are delegating the help text to `device_managment.py`, it should print out help as if it's invoked with `mbed device-management`. This PR changes the argument parser and the help text to do just that. ### Pull request type [x] Fix [ ] Refactor [ ] Target update [ ] Functionality change [ ] Breaking change --- tools/device_management.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tools/device_management.py b/tools/device_management.py index 14733f2c02..397d56d615 100644 --- a/tools/device_management.py +++ b/tools/device_management.py @@ -44,6 +44,15 @@ from tools.options import extract_mcus class MbedExtendedArgs(MainArgumentParser): + + def __init__(self, *args, **kwargs): + MainArgumentParser.__init__(self, *args, **kwargs) + self.parser.prog = "mbed device-management" + self.parser.description = ( + "Create or transform a manifest. " + "Use {} [command] -h for help on each command." + ).format(self.parser.prog) + def _addCreateArgs(self, parser, exclusions=[]): if 'payload' not in exclusions: parser.add_argument(