Azure / Azure/autorest.cli

Useful statements that can be generated for Azure CLI

Open
#98 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
8
Forks
18
PR merge metrics
No merged PRs in 30d

Description

Add to _params.py:
```
from azure.cli.core.commands.validators import get_default_location_from_resource_group
from knack.arguments import CLIArgumentType

name_arg_type = CLIArgumentType(options_list=['--name', '-n'], metavar='NAME')
image_template_name = CLIArgumentType(overrides=name_arg_type,
help='The name of the image Template', id_part='name')

c.argument('location', arg_type=get_location_type(self.cli_ctx),
validator=get_default_location_from_resource_group)
```

Add to custom.py:
```
from knack.util import CLIError
from msrestazure.tools import resource_id, is_valid_resource_id
from azure.cli.core.commands.client_factory import get_subscription_id
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.