Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,18 @@
# Licensed under the MIT License. See License.txt in the project root for license information.
# --------------------------------------------------------------------------------------------


def _resource_client_factory(cli_ctx, **_):
from azure.cli.core.commands.client_factory import get_mgmt_service_client
from azure.cli.core.profiles import ResourceType
return get_mgmt_service_client(cli_ctx, ResourceType.MGMT_RESOURCE_RESOURCES)


def _resource_deployments_client_factory(cli_ctx, **_):
from azure.cli.core.commands.client_factory import get_mgmt_service_client
from azure.cli.core.profiles import ResourceType
return get_mgmt_service_client(cli_ctx, ResourceType.MGMT_RESOURCE_RESOURCES)


def _resource_feature_client_factory(cli_ctx, **_):
from azure.cli.core.commands.client_factory import get_mgmt_service_client
from azure.cli.core.profiles import ResourceType
Expand Down Expand Up @@ -76,7 +81,7 @@ def _resource_privatelinks_client_factory(cli_ctx, **_):
return get_mgmt_service_client(cli_ctx, ResourceType.MGMT_RESOURCE_PRIVATELINKS)


def cf_resource_groups(cli_ctx, _):
def cf_resource_groups(cli_ctx, *_):
return _resource_client_factory(cli_ctx).resource_groups


Expand All @@ -92,12 +97,16 @@ def cf_tags(cli_ctx, _):
return _resource_client_factory(cli_ctx).tags


def cf_deployments(cli_ctx, _):
return _resource_client_factory(cli_ctx).deployments
def cf_deployments(cli_ctx, *_):
return _resource_deployments_client_factory(cli_ctx).deployments


def cf_deployment_operations(cli_ctx, _):
return _resource_client_factory(cli_ctx).deployment_operations
def cf_deployment_operations(cli_ctx, *_):
return _resource_deployments_client_factory(cli_ctx).deployment_operations


def cf_deploymentscripts(cli_ctx, *_):
return _resource_deploymentscripts_client_factory(cli_ctx).deployment_scripts


def cf_features(cli_ctx, _):
Expand Down Expand Up @@ -128,10 +137,6 @@ def cf_resource_links(cli_ctx, _):
return _resource_links_client_factory(cli_ctx).resource_links


def cf_resource_deploymentscripts(cli_ctx, _):
return _resource_deploymentscripts_client_factory(cli_ctx).deployment_scripts


def cf_resource_managedapplications(cli_ctx, _):
return _resource_managedapps_client_factory(cli_ctx).applications

Expand Down Expand Up @@ -160,11 +165,11 @@ def cf_hierarchy_settings(cli_ctx, _):
return _resource_managementgroups_client_factory(cli_ctx).hierarchy_settings


def cf_resource_templatespecs(cli_ctx, _):
def cf_resource_templatespecs(cli_ctx, *_):
return _resource_templatespecs_client_factory(cli_ctx).template_specs


def cf_resource_deploymentstacks(cli_ctx, _):
def cf_resource_deploymentstacks(cli_ctx, *_):
return _resource_deploymentstacks_client_factory(cli_ctx).deployment_stacks


Expand Down
5 changes: 5 additions & 0 deletions src/azure-cli/azure/cli/command_modules/resource/_help.py
Original file line number Diff line number Diff line change
Expand Up @@ -1402,6 +1402,11 @@
short-summary: Manage deployment operations.
"""

helps['group deployment operation show'] = """
type: command
short-summary: Show a deployment operation at resource group.
"""

helps['group deployment validate'] = """
type: command
short-summary: Validate whether a template is syntactically correct.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from knack.util import CLIError
from azure.cli.core.azclierror import BadRequestError
from azure.cli.core.util import read_file_content, shell_safe_json_parse
from azure.cli.command_modules.resource.custom import _remove_comments_from_json
from azure.cli.command_modules.resource.custom_deployments import _remove_comments_from_json
from azure.cli.core.profiles import ResourceType, get_sdk


Expand Down
41 changes: 21 additions & 20 deletions src/azure-cli/azure/cli/command_modules/resource/commands.py

Large diffs are not rendered by default.

Loading
Loading