az devops wiki page
Note
This reference is part of the azure-devops extension for the Azure CLI (version 2.30.0 or higher). 该扩展将在首次运行 az devops wiki page 命令时自动安装。 Learn more about extensions.
管理 Wiki 页面。
命令
名称 | 说明 | 类型 | Status |
---|---|---|---|
az devops wiki page create |
添加新页面。 |
Extension | GA |
az devops wiki page delete |
删除页面。 |
Extension | GA |
az devops wiki page show |
获取页面的内容或打开页面。 |
Extension | GA |
az devops wiki page update |
编辑页面。 |
Extension | GA |
az devops wiki page create
添加新页面。
az devops wiki page create --path
--wiki
[--comment]
[--content]
[--detect {false, true}]
[--encoding {ascii, utf-16be, utf-16le, utf-8}]
[--file-path]
[--org --organization]
[--project]
示例
使用内联内容在名为“myprojectwiki”的 Wiki 中创建路径为“my page”的新页面
az devops wiki page create --path 'my page' --wiki myprojectwiki --content "Hello World"
使用文件中的内容在名为“myprojectwiki”的 Wiki 中创建路径为“my page”的新页面
az devops wiki page create --path 'my page' --wiki myprojectwiki --file-path a.txt --encoding utf-8
必需参数
Wiki 页面的路径。
Wiki 的名称或 ID。
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
文件添加作的提交消息中的注释。
属性 | 值 |
---|---|
默认值: | Added a new page using Azure DevOps CLI |
Wiki 页面的内容。 如果指定了 --file-path,则忽略。
自动检测组织。
属性 | 值 |
---|---|
接受的值: | false, true |
文件的编码。 与 --file-path 参数结合使用。
属性 | 值 |
---|---|
默认值: | utf-8 |
接受的值: | ascii, utf-16be, utf-16le, utf-8 |
如果在文件中指定了内容,则文件输入的路径。
Azure DevOps 组织 URL。 可以使用 az devops configure -d organization=ORG_URL 配置默认组织。 如果未配置为默认或通过 git 配置选取,则为必需。示例:https://dev.azure.com/MyOrganizationName/
。
项目的名称或 ID。 可以使用 az devops configure -d project=NAME_OR_ID 配置默认项目。 如果未配置为默认或通过 git 配置进行选取,则为必需。
全局参数
提高日志记录详细程度以显示所有调试日志。
属性 | 值 |
---|---|
默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
属性 | 值 |
---|---|
默认值: | False |
Output format.
属性 | 值 |
---|---|
默认值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID
配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
属性 | 值 |
---|---|
默认值: | False |
az devops wiki page delete
删除页面。
az devops wiki page delete --path
--wiki
[--comment]
[--detect {false, true}]
[--org --organization]
[--project]
[--yes]
必需参数
Wiki 页面的路径。
Wiki 的名称或 ID。
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
删除作的提交消息中的注释。
属性 | 值 |
---|---|
默认值: | Deleted the page using Azure DevOps CLI |
自动检测组织。
属性 | 值 |
---|---|
接受的值: | false, true |
Azure DevOps 组织 URL。 可以使用 az devops configure -d organization=ORG_URL 配置默认组织。 如果未配置为默认或通过 git 配置选取,则为必需。示例:https://dev.azure.com/MyOrganizationName/
。
项目的名称或 ID。 可以使用 az devops configure -d project=NAME_OR_ID 配置默认项目。 如果未配置为默认或通过 git 配置进行选取,则为必需。
不要提示确认。
属性 | 值 |
---|---|
默认值: | False |
全局参数
提高日志记录详细程度以显示所有调试日志。
属性 | 值 |
---|---|
默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
属性 | 值 |
---|---|
默认值: | False |
Output format.
属性 | 值 |
---|---|
默认值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID
配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
属性 | 值 |
---|---|
默认值: | False |
az devops wiki page show
获取页面的内容或打开页面。
az devops wiki page show --path
--wiki
[--detect {false, true}]
[--include-content]
[--open]
[--org --organization]
[--project]
[--recursion-level]
[--version]
必需参数
Wiki 页面的路径。
Wiki 的名称或 ID。
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
自动检测组织。
属性 | 值 |
---|---|
接受的值: | false, true |
包括页面的内容。
属性 | 值 |
---|---|
默认值: | False |
在 Web 浏览器中打开 Wiki 页面。
属性 | 值 |
---|---|
默认值: | False |
Azure DevOps 组织 URL。 可以使用 az devops configure -d organization=ORG_URL 配置默认组织。 如果未配置为默认或通过 git 配置选取,则为必需。示例:https://dev.azure.com/MyOrganizationName/
。
项目的名称或 ID。 可以使用 az devops configure -d project=NAME_OR_ID 配置默认项目。 如果未配置为默认或通过 git 配置进行选取,则为必需。
包括页面的子页。
wiki 页面) 版本 (ETag。
全局参数
提高日志记录详细程度以显示所有调试日志。
属性 | 值 |
---|---|
默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
属性 | 值 |
---|---|
默认值: | False |
Output format.
属性 | 值 |
---|---|
默认值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID
配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
属性 | 值 |
---|---|
默认值: | False |
az devops wiki page update
编辑页面。
az devops wiki page update --path
--version
--wiki
[--comment]
[--content]
[--detect {false, true}]
[--encoding {ascii, utf-16be, utf-16le, utf-8}]
[--file-path]
[--org --organization]
[--project]
示例
使用内联内容更新名为“myprojectwiki”的 Wiki 中路径“my page”的页面内容
az devops wiki page update --path 'my page' --wiki myprojectwiki --content "Hello World" --version 4ae78ad5835cb7dd55072fe210c9ee7eb6d6413b
使用文件内容在 Wiki 中使用路径“my page”更新页面的内容
az devops wiki page update --path 'my page' --wiki myprojectwiki --file-path a.txt --encoding utf-8 --version 4ae78ad5835cb7dd55072fe210c9ee7eb6d6413b
必需参数
Wiki 页面的路径。
要编辑的文件的版本(ETag)。
Wiki 的名称或 ID。
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
文件编辑作的提交消息中的注释。
属性 | 值 |
---|---|
默认值: | Updated the page using Azure DevOps CLI |
Wiki 页面的内容。 如果指定了 --file-path,则忽略。
自动检测组织。
属性 | 值 |
---|---|
接受的值: | false, true |
文件的编码。 与 --file-path 参数结合使用。
属性 | 值 |
---|---|
默认值: | utf-8 |
接受的值: | ascii, utf-16be, utf-16le, utf-8 |
如果在文件中指定了内容,则文件输入的路径。
Azure DevOps 组织 URL。 可以使用 az devops configure -d organization=ORG_URL 配置默认组织。 如果未配置为默认或通过 git 配置选取,则为必需。示例:https://dev.azure.com/MyOrganizationName/
。
项目的名称或 ID。 可以使用 az devops configure -d project=NAME_OR_ID 配置默认项目。 如果未配置为默认或通过 git 配置进行选取,则为必需。
全局参数
提高日志记录详细程度以显示所有调试日志。
属性 | 值 |
---|---|
默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
属性 | 值 |
---|---|
默认值: | False |
Output format.
属性 | 值 |
---|---|
默认值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID
配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
属性 | 值 |
---|---|
默认值: | False |