Skip to content

Commit

Permalink
domain update
Browse files Browse the repository at this point in the history
  • Loading branch information
xmdanni committed Oct 22, 2024
1 parent a7a218e commit 37b9a46
Show file tree
Hide file tree
Showing 268 changed files with 3,927 additions and 3,927 deletions.
2 changes: 1 addition & 1 deletion .github/azure-client-tools-bot/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ cli_common_issues:
- https://github.com/Azure/azure-cli/issues/19640#issuecomment-1133875268
- https://github.com/Azure/azure-cli/issues/19640#issuecomment-1148202854
Please follow https://docs.microsoft.com/en-us/cli/azure/install-azure-cli-linux to install Microsoft official Azure CLI.
Please follow https://learn.microsoft.com/en-us/cli/azure/install-azure-cli-linux to install Microsoft official Azure CLI.
If you feel that further discussion is needed, please add a comment with the text `/clibot unresolve` to reopen the issue.
- tag: latest_api_version_not_available
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile.nanoserver
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ LABEL maintainer="Microsoft" \
org.label-schema.version=$CLI_VERSION \
org.label-schema.license="MIT" \
org.label-schema.description="The Azure CLI 2.0 is the new Azure CLI and is applicable when you use the Resource Manager deployment model." \
org.label-schema.url="https://docs.microsoft.com/cli/azure/overview" \
org.label-schema.usage="https://docs.microsoft.com/cli/azure/install-az-cli2#docker" \
org.label-schema.url="https://learn.microsoft.com/cli/azure/overview" \
org.label-schema.usage="https://learn.microsoft.com/cli/azure/install-az-cli2#docker" \
org.label-schema.build-date=$BUILD_DATE \
org.label-schema.vcs-url="https://github.com/Azure/azure-cli.git" \
org.label-schema.docker.cmd="docker run -v $HOME\.azure:C:\Users\ContainerUser\.azure -it mcr.microsoft.com/azure-cli:$CLI_VERSION"
Expand Down
26 changes: 13 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Take a test run now from [Azure Cloud Shell](https://portal.azure.com/#cloudshel

## Installation

Please refer to the [install guide](https://docs.microsoft.com/cli/azure/install-azure-cli) for detailed install instructions.
Please refer to the [install guide](https://learn.microsoft.com/cli/azure/install-azure-cli) for detailed install instructions.

A list of common install issues and their resolutions are available at [install troubleshooting](https://github.com/Azure/azure-cli/blob/dev/doc/install_troubleshooting.md).

Expand All @@ -28,7 +28,7 @@ $ az [ group ] [ subgroup ] [ command ] {parameters}

### Get Started

Please refer to the ["get started" guide](https://docs.microsoft.com/cli/azure/get-started-with-az-cli2) for in-depth instructions.
Please refer to the ["get started" guide](https://learn.microsoft.com/cli/azure/get-started-with-az-cli2) for in-depth instructions.

For usage and help content, pass in the `-h` parameter, for example:

Expand Down Expand Up @@ -87,21 +87,21 @@ For scripting purposes, we output certain exit codes for differing scenarios.

### Common scenarios and use Azure CLI effectively

Please check [Tips for using Azure CLI effectively](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively). It describes some common scenarios:
Please check [Tips for using Azure CLI effectively](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively). It describes some common scenarios:

- [Output formatting (json, table, or tsv)](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#output-formatting-json-table-or-tsv)
- [Pass values from one command to another](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#pass-values-from-one-command-to-another)
- [Async operations](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#async-operations)
- [Generic update arguments](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#generic-update-arguments)
- [Generic resource commands - `az resource`](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#generic-resource-commands---az-resource)
- [REST API command - `az rest`](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#rest-api-command---az-rest)
- [Quoting issues](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#quoting-issues)
- [Work behind a proxy](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#work-behind-a-proxy)
- [Concurrent builds](https://docs.microsoft.com/en-us/cli/azure/use-cli-effectively#concurrent-builds)
- [Output formatting (json, table, or tsv)](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#output-formatting-json-table-or-tsv)
- [Pass values from one command to another](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#pass-values-from-one-command-to-another)
- [Async operations](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#async-operations)
- [Generic update arguments](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#generic-update-arguments)
- [Generic resource commands - `az resource`](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#generic-resource-commands---az-resource)
- [REST API command - `az rest`](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#rest-api-command---az-rest)
- [Quoting issues](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#quoting-issues)
- [Work behind a proxy](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#work-behind-a-proxy)
- [Concurrent builds](https://learn.microsoft.com/en-us/cli/azure/use-cli-effectively#concurrent-builds)

### More samples and snippets

For more usage examples, take a look at our [GitHub samples repo](http://github.com/Azure/azure-cli-samples) or [https://docs.microsoft.com/cli/azure/overview](https://docs.microsoft.com/cli/azure/overview).
For more usage examples, take a look at our [GitHub samples repo](http://github.com/Azure/azure-cli-samples) or [https://learn.microsoft.com/cli/azure/overview](https://learn.microsoft.com/cli/azure/overview).

### Write and run commands in Visual Studio Code

Expand Down
6 changes: 3 additions & 3 deletions build_scripts/windows/Product.wxs
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@
<Icon Id="AzureIcon" SourceFile="$(var.ProductResources)windowsazure.ico" />

<Property Id="ARPPRODUCTICON" Value="AzureIcon" />
<Property Id="ARPHELPLINK" Value="https://docs.microsoft.com/cli/azure" />
<Property Id="ARPURLINFOABOUT" Value="https://docs.microsoft.com/cli/azure/overview" />
<Property Id="ARPURLUPDATEINFO" Value="https://docs.microsoft.com/cli/azure/overview" />
<Property Id="ARPHELPLINK" Value="https://learn.microsoft.com/cli/azure" />
<Property Id="ARPURLINFOABOUT" Value="https://learn.microsoft.com/cli/azure/overview" />
<Property Id="ARPURLUPDATEINFO" Value="https://learn.microsoft.com/cli/azure/overview" />
<Property Id="MSIFASTINSTALL" Value="7" />
<Property Id="ApplicationFolderName" Value="Microsoft SDKs\Azure" />
<Property Id="WixAppFolder" Value="WixPerMachineFolder" />
Expand Down
2 changes: 1 addition & 1 deletion doc/authoring_command_modules/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The document provides instructions and guidelines on how to author command modul

**Test Authoring**:<br>https://github.com/Azure/azure-cli/blob/dev/doc/authoring_tests.md

**Generating Documentation**:<br>https://review.docs.microsoft.com/help/onboard/admin/reference/cli/azure-cli-ci?branch=master#documenting-a-new-azure-cli-module
**Generating Documentation**:<br>https://review.learn.microsoft.com/help/onboard/admin/reference/cli/azure-cli-ci?branch=master#documenting-a-new-azure-cli-module

<a name="heading_set_up"></a>Set Up
------
Expand Down
2 changes: 1 addition & 1 deletion scripts/ci/codegen_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
KUSTO_CLUSTER = os.environ.get('KUSTO_CLUSTER')
KUSTO_DATABASE = os.environ.get('KUSTO_DATABASE')
KUSTO_TABLE = os.environ.get('KUSTO_TABLE')
# get tenant id from https://docs.microsoft.com/en-us/onedrive/find-your-office-365-tenant-id
# get tenant id from https://learn.microsoft.com/en-us/onedrive/find-your-office-365-tenant-id
KUSTO_TENANT_ID = os.environ.get('KUSTO_TENANT_ID')


Expand Down
2 changes: 1 addition & 1 deletion scripts/live_test/sendemail.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
KUSTO_CLUSTER = os.environ.get('KUSTO_CLUSTER')
KUSTO_DATABASE = os.environ.get('KUSTO_DATABASE')
KUSTO_TABLE = os.environ.get('KUSTO_TABLE')
# get tenant id from https://docs.microsoft.com/en-us/onedrive/find-your-office-365-tenant-id
# get tenant id from https://learn.microsoft.com/en-us/onedrive/find-your-office-365-tenant-id
KUSTO_TENANT_ID = os.environ.get('KUSTO_TENANT_ID')
PYTHON_VERSION = os.environ.get('PYTHON_VERSION')
USER_BRANCH = os.environ.get('USER_BRANCH')
Expand Down
2 changes: 1 addition & 1 deletion scripts/release/homebrew/docker/formula_template.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ class AzureCli < Formula
include Language::Python::Virtualenv

desc "Microsoft Azure CLI 2.0"
homepage "https://docs.microsoft.com/cli/azure/overview"
homepage "https://learn.microsoft.com/cli/azure/overview"
url "{{ upstream_url }}"
version "{{ cli_version }}"
sha256 "{{ upstream_sha }}"
Expand Down
2 changes: 1 addition & 1 deletion scripts/release/rpm/azure-cli.spec
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ License: MIT
Name: %{name}
Version: %{version}
Release: %{release}
Url: https://docs.microsoft.com/cli/azure/install-azure-cli
Url: https://learn.microsoft.com/cli/azure/install-azure-cli
Requires: %{python_package}
Prefix: /usr
Prefix: /etc
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def __init__(self, credential, resource=None, auxiliary_credentials=None):
:param resource: AAD resource for Track 1 only
:param auxiliary_credentials: Credentials from .msal_authentication for cross tenant authentication.
Details about cross tenant authentication:
https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant
https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant
"""

self._credential = credential
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="refresh" content="60;url=https://docs.microsoft.com/cli/azure/">
<meta http-equiv="refresh" content="60;url=https://learn.microsoft.com/cli/azure/">
<title>Login successfully</title>
<style>
body {
Expand All @@ -20,6 +20,6 @@
</head>
<body>
<h3>You have logged into Microsoft Azure!</h3>
<p>You can close this window, or we will redirect you to the <a href="https://docs.microsoft.com/cli/azure/">Azure CLI documentation</a> in 1 minute.</p>
<p>You can close this window, or we will redirect you to the <a href="https://learn.microsoft.com/cli/azure/">Azure CLI documentation</a> in 1 minute.</p>
</body>
</html>
4 changes: 2 additions & 2 deletions src/azure-cli-core/azure/cli/core/auth/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
def aad_error_handler(error, **kwargs):
""" Handle the error from AAD server returned by ADAL or MSAL. """

# https://docs.microsoft.com/en-us/azure/active-directory/develop/reference-aadsts-error-codes
# https://learn.microsoft.com/en-us/azure/active-directory/develop/reference-aadsts-error-codes
# Search for an error code at https://login.microsoftonline.com/error

# To trigger this function for testing, simply provide an invalid scope:
Expand Down Expand Up @@ -67,7 +67,7 @@ def resource_to_scopes(resource):
:param resource: The ADAL resource ID
:return: A list of scopes
"""
# https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-permissions-and-consent#trailing-slash-and-default
# https://learn.microsoft.com/en-us/azure/active-directory/develop/v2-permissions-and-consent#trailing-slash-and-default
# We should not trim the trailing slash, like in https://management.azure.com/
# In other word, the trailing slash should be preserved and scope should be https://management.azure.com//.default
scope = resource + '/.default'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ def _prepare_mgmt_client_kwargs_track2(cli_ctx, cred):
# Track 2 currently lacks the ability to take external credentials.
# https://github.com/Azure/azure-sdk-for-python/issues/8313
# As a temporary workaround, manually add external tokens to 'x-ms-authorization-auxiliary' header.
# https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant
# https://learn.microsoft.com/en-us/azure/azure-resource-manager/management/authenticate-multi-tenant
if hasattr(cred, "get_auxiliary_tokens"):
aux_tokens = cred.get_auxiliary_tokens(*scopes)
if aux_tokens:
Expand Down
4 changes: 2 additions & 2 deletions src/azure-cli-core/azure/cli/core/intercept_survey.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@
PROMPT_INTERVAL_IN_DAYS = 180

# VT code for text formatting:
# https://docs.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences#extended-colors
# https://learn.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences#extended-colors
SURVEY_STYLE = '\x1b[0;38;2;255;255;255;48;2;0;120;212m' # Default & Foreground #FFFFFF & Background #0078D4

# VT code for text modification:
# https://docs.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences#text-modification
# https://learn.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences#text-modification
NEW_LINE = '\x1b[1L'
ERASE_IN_LINE = '\x1b[0K'

Expand Down
2 changes: 1 addition & 1 deletion src/azure-cli-core/azure/cli/core/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
EXTENSION_REFERENCE = ("If the command is from an extension, "
"please make sure the corresponding extension is installed. "
"To learn more about extensions, please visit "
"'https://docs.microsoft.com/cli/azure/azure-cli-extensions-overview'")
"'https://learn.microsoft.com/cli/azure/azure-cli-extensions-overview'")

OVERVIEW_REFERENCE = ("https://aka.ms/cli_ref")

Expand Down
2 changes: 1 addition & 1 deletion src/azure-cli-core/azure/cli/core/style.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
https://devdivdesignguide.azurewebsites.net/command-line-interface/color-guidelines-for-command-line-interface/
Console Virtual Terminal Sequences:
https://docs.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences#text-formatting
https://learn.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences#text-formatting
For a complete demo, see `src/azure-cli/azure/cli/command_modules/util/custom.py` and run `az demo style`.
"""
Expand Down
16 changes: 8 additions & 8 deletions src/azure-cli-core/azure/cli/core/tests/test_help.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,15 +202,15 @@ def set_help_yaml(self):
description: Group yaml description. A.K.A long description
links:
- title: Azure Test Docs
url: "https://docs.microsoft.com/azure/test"
url: "https://learn.microsoft.com/azure/test"
- url: "https://aka.ms/just-a-url"
- command:
name: test alpha
summary: Command yaml summary
description: Command yaml description. A.K.A long description
links:
- title: Azure Test Alpha Docs
url: "https://docs.microsoft.com/azure/test/alpha"
url: "https://learn.microsoft.com/azure/test/alpha"
- url: "https://aka.ms/just-a-long-url"
arguments:
- name: --arg2 # we do not specify the short option in the name.
Expand Down Expand Up @@ -251,7 +251,7 @@ def set_help_json(self):
"hyper-links": [
{
"title": "Azure Json Test Docs",
"url": "https://docs.microsoft.com/azure/test"
"url": "https://learn.microsoft.com/azure/test"
},
{
"url": "https://aka.ms/just-a-url"
Expand All @@ -267,7 +267,7 @@ def set_help_json(self):
"hyper-links": [
{
"title": "Azure Json Test Alpha Docs",
"url": "https://docs.microsoft.com/azure/test/alpha"
"url": "https://learn.microsoft.com/azure/test/alpha"
},
{
"url": "https://aka.ms/just-a-long-url"
Expand Down Expand Up @@ -403,15 +403,15 @@ def test_load_from_help_yaml(self, mocked_load, mocked_pkg_util):
self.assertIsNotNone(group_help_obj)
self.assertEqual(group_help_obj.short_summary, "Group yaml summary.")
self.assertEqual(group_help_obj.long_summary, "Group yaml description. A.K.A long description.")
self.assertEqual(group_help_obj.links[0], {"title": "Azure Test Docs", "url": "https://docs.microsoft.com/azure/test"})
self.assertEqual(group_help_obj.links[0], {"title": "Azure Test Docs", "url": "https://learn.microsoft.com/azure/test"})
self.assertEqual(group_help_obj.links[1], {"url": "https://aka.ms/just-a-url"})

# Test command help
self.assertIsNotNone(command_help_obj)
self.assertEqual(command_help_obj.short_summary, "Command yaml summary.")
self.assertEqual(command_help_obj.long_summary, "Command yaml description. A.K.A long description.")
self.assertEqual(command_help_obj.links[0], {"title": "Azure Test Alpha Docs",
"url": "https://docs.microsoft.com/azure/test/alpha"})
"url": "https://learn.microsoft.com/azure/test/alpha"})
self.assertEqual(command_help_obj.links[1], {"url": "https://aka.ms/just-a-long-url"})

# test that parameters and help are loaded from command function docstring, argument registry help and help.yaml
Expand Down Expand Up @@ -478,15 +478,15 @@ def test_load_from_help_json(self, mocked_load, mocked_pkg_util, mocked_getmembe
self.assertEqual(group_help_obj.short_summary, "Group json summary.")
self.assertEqual(group_help_obj.long_summary, "Group json description. A.K.A long description.")
self.assertEqual(group_help_obj.links[0], {"title": "Azure Json Test Docs",
"url": "https://docs.microsoft.com/azure/test"})
"url": "https://learn.microsoft.com/azure/test"})
self.assertEqual(group_help_obj.links[1], {"url": "https://aka.ms/just-a-url"})

# Test command help
self.assertIsNotNone(command_help_obj)
self.assertEqual(command_help_obj.short_summary, "Command json summary.")
self.assertEqual(command_help_obj.long_summary, "Command json description. A.K.A long description.")
self.assertEqual(command_help_obj.links[0], {"title": "Azure Json Test Alpha Docs",
"url": "https://docs.microsoft.com/azure/test/alpha"})
"url": "https://learn.microsoft.com/azure/test/alpha"})
self.assertEqual(command_help_obj.links[1], {"url": "https://aka.ms/just-a-long-url"})

# test that parameters and help are loaded from command function docstring, argument registry help and help.yaml
Expand Down
8 changes: 4 additions & 4 deletions src/azure-cli-core/azure/cli/core/tests/test_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,8 @@ def test_send_raw_requests(self, send_mock, get_raw_token_mock):
expected_header_with_auth['Authorization'] = 'Bearer eyJ0eXAiOiJKV1'

# Test basic usage
# Mock Put Blob https://docs.microsoft.com/en-us/rest/api/storageservices/put-blob
# Authenticate with service SAS https://docs.microsoft.com/en-us/rest/api/storageservices/create-service-sas
# Mock Put Blob https://learn.microsoft.com/en-us/rest/api/storageservices/put-blob
# Authenticate with service SAS https://learn.microsoft.com/en-us/rest/api/storageservices/create-service-sas
sas_token = ['sv=2019-02-02', '{"srt": "s"}', "{'ss': 'bf'}"]
send_raw_request(cli_ctx, 'PUT', 'https://myaccount.blob.core.windows.net/mycontainer/myblob?timeout=30',
uri_parameters=sas_token, body=test_body,
Expand Down Expand Up @@ -312,7 +312,7 @@ def test_send_raw_requests(self, send_mock, get_raw_token_mock):
self.assertDictEqual(dict(request.headers), expected_header_with_auth)

# Test ARM Subscriptions - List
# https://docs.microsoft.com/en-us/rest/api/resources/subscriptions/list
# https://learn.microsoft.com/en-us/rest/api/resources/subscriptions/list
# /subscriptions?api-version=2020-01-01
send_raw_request(cli_ctx, 'GET', '/subscriptions?api-version=2020-01-01', body=test_body,
generated_client_request_id_name=None)
Expand All @@ -323,7 +323,7 @@ def test_send_raw_requests(self, send_mock, get_raw_token_mock):
self.assertDictEqual(dict(request.headers), expected_header_with_auth)

# Test ARM Tenants - List
# https://docs.microsoft.com/en-us/rest/api/resources/tenants/list
# https://learn.microsoft.com/en-us/rest/api/resources/tenants/list
# /tenants?api-version=2020-01-01
send_raw_request(cli_ctx, 'GET', '/tenants?api-version=2020-01-01', body=test_body,
generated_client_request_id_name=None)
Expand Down
Loading

0 comments on commit 37b9a46

Please sign in to comment.