vmware / python-client-for-vmware-cloud-on-aws

Python Client for VMware Cloud on AWS is an open-source Python-based tool. Written in Python, the tool enables VMware Cloud on AWS users to automate the consumption of their VMware Cloud on AWS SDDC.
Other
24 stars 20 forks source link

Usage help info needs updating #188

Open mixologee opened 1 year ago

mixologee commented 1 year ago

Describe the bug

pyvmc.py inventory show-inv-group -h usage: inventory show-inv-group [-h] [--oauth [OAUTH]] [--nsxm [NSXM]] [-n OBJECTNAME] [{cgw,mgw,both}]

positional arguments: {cgw,mgw,both} Show the inventory groups associated with the MGW or CGW gateways.

options: -h, --help show this help message and exit --oauth [OAUTH] Used to specify use of OAuth app ID and secret in config.ini instead of 'refresh_token' (default). --nsxm [NSXM] Used to specify NSX Manager instead of NSX proxy (Default). -n OBJECTNAME, --objectname OBJECTNAME The name of the inventory group to retrieve details for. Use 'pyVMC.py inventory show-group' for a complete list.

pyvmc.py inventory show-inv-group-association -h usage: inventory show-inv-group-association [-h] [--oauth [OAUTH]] [--nsxm [NSXM]] {cgw,mgw} objectname

positional arguments: {cgw,mgw} Show the inventory groups associated with the MGW or CGW gateways. objectname The name of the inventory group to retrieve details for. Use 'pyVMC.py inventory show-group' for a complete list.

options: -h, --help show this help message and exit --oauth [OAUTH] Used to specify use of OAuth app ID and secret in config.ini instead of 'refresh_token' (default). --nsxm [NSXM] Used to specify NSX Manager instead of NSX proxy (Default).

Reproduction steps

  1. pyvmc.py inventory show-inv-group -h
  2. pyvmc.py inventory show-inv-group-association -h

Expected behavior

pyvmc.py inventory show-inv-group -h usage: inventory show-inv-group [-h] [--oauth [OAUTH]] [--nsxm [NSXM]] [-n OBJECTNAME] [{cgw,mgw,both}]

positional arguments: {cgw,mgw,both} Show the inventory groups associated with the MGW or CGW gateways.

options: -h, --help show this help message and exit --oauth [OAUTH] Used to specify use of OAuth app ID and secret in config.ini instead of 'refresh_token' (default). --nsxm [NSXM] Used to specify NSX Manager instead of NSX proxy (Default). -n OBJECTNAME, --objectname OBJECTNAME The name of the inventory group to retrieve details for. Use 'pyVMC.py inventory show-inv-group' for a complete list.

pyvmc.py inventory show-inv-group-association -h usage: inventory show-inv-group-association [-h] [--oauth [OAUTH]] [--nsxm [NSXM]] {cgw,mgw} objectname

positional arguments: {cgw,mgw} Show the inventory groups associated with the MGW or CGW gateways. objectname The name of the inventory group to retrieve details for. Use 'pyVMC.py inventory show-inv-group' for a complete list.

options: -h, --help show this help message and exit --oauth [OAUTH] Used to specify use of OAuth app ID and secret in config.ini instead of 'refresh_token' (default). --nsxm [NSXM] Used to specify NSX Manager instead of NSX proxy (Default).

Additional context

Just cleanup of usage help. Functionality not impacted.

maulepilot117 commented 1 year ago

Is the ask that we add functionality to display both the MGW and CGW inventory groups in one command?

mixologee commented 1 year ago

No, the ask is to update the usage help info to the new command versus the old command (I have them in bold).

mixologee commented 1 year ago

pyVMC.py inventory show-group usage: inventory [-h] {new-inv-group,remove-inv-group,show-inv-group,show-inv-group-association,new-service,import-service,remove-service,show-services} ... inventory: error: argument {new-inv-group,remove-inv-group,show-inv-group,show-inv-group-association,new-service,import-service,remove-service,show-services}: invalid choice: 'show-group' (choose from 'new-inv-group', 'remove-inv-group', 'show-inv-group', 'show-inv-group-association', 'new-service', 'import-service', 'remove-service', 'show-services')