I have created custom command *| cloudcidrlookup cloud=azure* but how to change it to be just *| cloudcidrlookup azure* ?
@Configuration()
class CloudCidrLookup(GeneratingCommand):
cloud = Option(require=False)
...
def generate(self):
if self.cloud=='azure':
...
dispatch(CloudCidrLookup, sys.argv, sys.stdin, sys.stdout, __name__)
Refer to the field name by index rather than by name.
cloud = self.fieldnames[0]
Refer to the field name by index rather than by name.
cloud = self.fieldnames[0]