From 342589e781cd92eed3f720fb1df330d92ab3b7b4 Mon Sep 17 00:00:00 2001 From: yucgu <95731623+yucgu@users.noreply.github.com> Date: Mon, 3 Oct 2022 08:08:25 -0700 Subject: [PATCH] Added cisco config platform commands (#2242) (#2418) What I did Add cisco sub-command option under 'config platform' command How I did it In config/main.py, check the platform type and import the cisco.py file under cisco platform code when it's cisco-8000. How to verify it Run config platform -h to see all commands. We will be able to see config platform cisco. This is only available on cisco devices. Signed-off-by: Yucai Gu yucgu@cisco.com Signed-off-by: Yucai Gu yucgu@cisco.com --- config/main.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/main.py b/config/main.py index 5801a096a1..39b12cdf08 100644 --- a/config/main.py +++ b/config/main.py @@ -1130,6 +1130,10 @@ def config(ctx): print("Caught an exception: " + str(e)) raise click.Abort() + if asic_type == 'cisco-8000': + from sonic_platform.cli.cisco import cisco + platform.add_command(cisco) + # Load database config files load_db_config()