Alv*_*nez 6 git repository azure azure-cli azure-devops
更新
我正在尝试从 git bash 命令行创建一个存储库到 AzureDevops 团队平台,
我一直遵循这些说明:
我在先决条件方面遇到问题,我运行了下一行:
az --version # version is greater than v2.0.49
az extension add --name azure-devops # no problem with this line
az devops login --organization org_url
PAT # problem arises here....
Run Code Online (Sandbox Code Playgroud)
运行结束行后出现下一行:
Failed to authenticate using the supplied token.
我按照以下说明创建 PAT:
我是否必须要求提供经理凭据,否则我可以采取什么措施来解决此问题?
从错误消息来看,您可能需要安装 Azure CLI。您必须至少有v2.0.49
,您可以使用命令验证az --version
。然后你可以运行az login
命令使用您的Azure帐户登录。
跟着文章走就行了。您可以在 git bash 或其他终端中执行以下步骤:
az extension add --name azure-devops
az login #login in with your Azure account
az devops configure --defaults organization=https://dev.azure.com/contoso project=contoso
Run Code Online (Sandbox Code Playgroud)
cd /home/fabrikam/fiber
git init .
git add --all
git commit -m "first commit of my code"
Run Code Online (Sandbox Code Playgroud)
remoteUrl
在 Azure Repos 中创建一个新的 Git 存储库,并使用创建的 Git 存储库的响应将本地存储库连接到 Azure Repos 中的 Git 存储库:az repos create --name mywebapprepos
git remote add origin https://xxx.xxx.com/webapp-test/_git/mywebapprepos
Run Code Online (Sandbox Code Playgroud)
git push origin master
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
3324 次 |
最近记录: |