[SWDEV-529603] Fix subcommand aliasing

Signed-off-by: Maisam Arif <Maisam.Arif@amd.com>
Change-Id: I1c15faffa5fda1b8f5c2f5d6e4c7ae746ff8ee7c


[ROCm/amdsmi commit: 4099fee17f]
Этот коммит содержится в:
Maisam Arif
2025-04-28 10:41:40 -05:00
коммит произвёл Arif, Maisam
родитель cf3a1aceca
Коммит c0cc1b3360
+3 -3
Просмотреть файл
@@ -102,9 +102,9 @@ if __name__ == "__main__":
except NameError:
logging.debug("argcomplete module not found. Autocomplete will not work.")
valid_commands = ['version', 'list', 'static', 'firmware', 'bad-pages',
'metric', 'process', 'profile', 'event', 'topology', 'set',
'reset', 'monitor', 'xgmi', 'partition', 'ras', '--help', '-h']
# Store possible subcommands & aliases for later errors
valid_commands = amd_smi_parser.possible_commands
valid_commands += ['--help', '-h']
sys.argv = [arg.lower() if arg.startswith('--') or not arg.startswith('-')
else arg for arg in sys.argv]