forked from Azure/azure-cli-extensions
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Generated from 692005a0f4e7bf6408bf20193ec16166b80b4a38
- Loading branch information
SDK Automation
committed
Sep 22, 2020
1 parent
9de47ae
commit d77132e
Showing
44 changed files
with
2,322 additions
and
1,119 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,6 @@ | |
Release History | ||
=============== | ||
|
||
0.1.1 | ||
0.1.0 | ||
++++++ | ||
* Initial release. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,50 @@ | ||
# -------------------------------------------------------------------------------------------- | ||
# -------------------------------------------------------------------------- | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. See License.txt in the project root for license information. | ||
# -------------------------------------------------------------------------------------------- | ||
# Licensed under the MIT License. See License.txt in the project root for | ||
# license information. | ||
# | ||
# Code generated by Microsoft (R) AutoRest Code Generator. | ||
# Changes may cause incorrect behavior and will be lost if the code is | ||
# regenerated. | ||
# -------------------------------------------------------------------------- | ||
|
||
from azure.cli.core import AzCommandsLoader | ||
from .generated._help import helps # pylint: disable=unused-import | ||
from azext_portal.generated._help import helps # pylint: disable=unused-import | ||
try: | ||
from azext_portal.manual._help import helps # pylint: disable=reimported | ||
except ImportError: | ||
pass | ||
|
||
|
||
class PortalCommandsLoader(AzCommandsLoader): | ||
|
||
def __init__(self, cli_ctx=None): | ||
from azure.cli.core.commands import CliCommandType | ||
from .generated._client_factory import cf_portal | ||
from azext_portal.generated._client_factory import cf_portal_cl | ||
portal_custom = CliCommandType( | ||
operations_tmpl='azext_portal.custom#{}', | ||
client_factory=cf_portal) | ||
super(PortalCommandsLoader, self).__init__(cli_ctx=cli_ctx, | ||
custom_command_type=portal_custom) | ||
client_factory=cf_portal_cl) | ||
parent = super(PortalCommandsLoader, self) | ||
parent.__init__(cli_ctx=cli_ctx, custom_command_type=portal_custom) | ||
|
||
def load_command_table(self, args): | ||
from .generated.commands import load_command_table | ||
from azext_portal.generated.commands import load_command_table | ||
load_command_table(self, args) | ||
try: | ||
from azext_portal.manual.commands import load_command_table as load_command_table_manual | ||
load_command_table_manual(self, args) | ||
except ImportError: | ||
pass | ||
return self.command_table | ||
|
||
def load_arguments(self, command): | ||
from .generated._params import load_arguments | ||
from azext_portal.generated._params import load_arguments | ||
load_arguments(self, command) | ||
try: | ||
from azext_portal.manual._params import load_arguments as load_arguments_manual | ||
load_arguments_manual(self, command) | ||
except ImportError: | ||
pass | ||
|
||
|
||
COMMAND_LOADER_CLS = PortalCommandsLoader |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
{ | ||
"azext.isExperimental": true, | ||
"azext.minCliCoreVersion": "2.3.1" | ||
"azext.minCliCoreVersion": "2.11.0" | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,24 @@ | ||
# -------------------------------------------------------------------------------------------- | ||
# -------------------------------------------------------------------------- | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. See License.txt in the project root for license information. | ||
# -------------------------------------------------------------------------------------------- | ||
# Licensed under the MIT License. See License.txt in the project root for | ||
# license information. | ||
# | ||
# Code generated by Microsoft (R) AutoRest Code Generator. | ||
# Changes may cause incorrect behavior and will be lost if the code is | ||
# regenerated. | ||
# -------------------------------------------------------------------------- | ||
|
||
|
||
def cf_portal(cli_ctx, *_): | ||
def cf_portal_cl(cli_ctx, *_): | ||
from azure.cli.core.commands.client_factory import get_mgmt_service_client | ||
from ..vendored_sdks.portal import Portal | ||
return get_mgmt_service_client(cli_ctx, Portal) | ||
return get_mgmt_service_client(cli_ctx, | ||
Portal) | ||
|
||
|
||
def cf_dashboard(cli_ctx, *_): | ||
return cf_portal(cli_ctx).dashboard | ||
return cf_portal_cl(cli_ctx).dashboard | ||
|
||
|
||
def cf_tenant_configuration(cli_ctx, *_): | ||
return cf_portal_cl(cli_ctx).tenant_configuration |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,61 +1,65 @@ | ||
# -------------------------------------------------------------------------------------------- | ||
# -------------------------------------------------------------------------- | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. See License.txt in the project root for license information. | ||
# -------------------------------------------------------------------------------------------- | ||
# pylint: disable=line-too-long | ||
# Licensed under the MIT License. See License.txt in the project root for | ||
# license information. | ||
# | ||
# Code generated by Microsoft (R) AutoRest Code Generator. | ||
# Changes may cause incorrect behavior and will be lost if the code is | ||
# regenerated. | ||
# -------------------------------------------------------------------------- | ||
# pylint: disable=too-many-lines | ||
# pylint: disable=too-many-statements | ||
|
||
from argcomplete.completers import FilesCompleter | ||
from azure.cli.core.commands.parameters import ( | ||
tags_type, | ||
get_three_state_flag, | ||
resource_group_name_type, | ||
get_location_type, | ||
file_type | ||
get_location_type | ||
) | ||
from azure.cli.core.commands.validators import ( | ||
get_default_location_from_resource_group, | ||
validate_file_or_dict | ||
) | ||
from azure.cli.core.commands.validators import get_default_location_from_resource_group | ||
|
||
|
||
def load_arguments(self, _): | ||
|
||
with self.argument_context('portal dashboard list') as c: | ||
c.argument('resource_group_name', resource_group_name_type, | ||
help='The name of the resource group.') | ||
c.argument('resource_group_name', resource_group_name_type) | ||
|
||
with self.argument_context('portal dashboard show') as c: | ||
c.argument('resource_group_name', resource_group_name_type) | ||
c.argument('name', options_list=[ | ||
'--name', '-n'], help='The name of the dashboard.') | ||
c.argument('dashboard_name', options_list=['--name', '-n', '--dashboard-name'], type=str, help='The name of ' | ||
'the dashboard.', id_part='name') | ||
|
||
with self.argument_context('portal dashboard create') as c: | ||
c.argument('resource_group_name', resource_group_name_type, | ||
help='The name of the resource group.') | ||
c.argument('name', options_list=[ | ||
'--name', '-n'], help='The name of the dashboard.') | ||
c.argument('resource_group_name', resource_group_name_type) | ||
c.argument('dashboard_name', options_list=['--name', '-n', '--dashboard-name'], type=str, help='The name of ' | ||
'the dashboard.') | ||
c.argument('location', arg_type=get_location_type(self.cli_ctx), | ||
validator=get_default_location_from_resource_group) | ||
c.argument('tags', tags_type) | ||
c.argument('input_path', type=file_type, | ||
help='The path to the dashboard properties JSON file.', completer=FilesCompleter()) | ||
c.argument('lenses', type=validate_file_or_dict, help='The dashboard lenses. Expected value: ' | ||
'json-string/@json-file.') | ||
c.argument('metadata', type=validate_file_or_dict, help='The dashboard metadata. Expected value: ' | ||
'json-string/@json-file.') | ||
|
||
with self.argument_context('portal dashboard update') as c: | ||
c.argument('resource_group_name', resource_group_name_type, | ||
help='The name of the resource group.') | ||
c.argument('name', options_list=[ | ||
'--name', '-n'], help='The name of the dashboard.') | ||
c.argument('input_path', type=file_type, | ||
help='The path to the dashboard properties JSON file.', completer=FilesCompleter()) | ||
c.argument('resource_group_name', resource_group_name_type) | ||
c.argument('dashboard_name', options_list=['--name', '-n', '--dashboard-name'], type=str, help='The name of ' | ||
'the dashboard.', id_part='name') | ||
c.argument('tags', tags_type) | ||
c.argument('lenses', type=validate_file_or_dict, help='The dashboard lenses. Expected value: ' | ||
'json-string/@json-file.') | ||
c.argument('metadata', type=validate_file_or_dict, help='The dashboard metadata. Expected value: ' | ||
'json-string/@json-file.') | ||
|
||
with self.argument_context('portal dashboard delete') as c: | ||
c.argument('resource_group_name', resource_group_name_type, | ||
help='The name of the resource group.') | ||
c.argument('name', options_list=[ | ||
'--name', '-n'], help='The name of the dashboard.') | ||
|
||
with self.argument_context('portal dashboard import') as c: | ||
c.argument('resource_group_name', resource_group_name_type, | ||
help='The name of the resource group.') | ||
c.argument('name', options_list=[ | ||
'--name', '-n'], help='The name of the dashboard.') | ||
c.argument('input_path', type=file_type, | ||
help='The path to the dashboard json file.', completer=FilesCompleter()) | ||
c.argument('resource_group_name', resource_group_name_type) | ||
c.argument('dashboard_name', options_list=['--name', '-n', '--dashboard-name'], type=str, help='The name of ' | ||
'the dashboard.', id_part='name') | ||
|
||
with self.argument_context('portal tenant-configuration create') as c: | ||
c.argument('enforce_private_markdown_storage', arg_type=get_three_state_flag(), help='When flag is set to true ' | ||
'Markdown tile will require external storage configuration (URI). The inline content configuration ' | ||
'will be prohibited.') |
Oops, something went wrong.