Azure CLI: az devops configure --defaults... has no effect. What am I missing?

g.pickardou

I am using Azure CLI azure-devops extension to manage my projects and git repositories in dev.azure.com.

az extension add --name azure-devops

To make code more readable and configurable I would like to use: (it does not matter if the values are between quotation marks or not)

az devops configure --defaults organization=https://dev.azure.com/myname
az devops configure --defaults project=f514a982-...  

Those commands executed without error (powershell) but it seems they has no effect on the following commands.

For example

az repos list # lists an other project's repos, not the required f514a982

However executing

az repos list --project f514a982....

gives the expected result.

Missing I something or is this a bug?

g.pickardou

Actually I figured it out, hopefully spares time someone in the future:

There is a --detect parameter which is on by default and if it is on then overrules the --defaults settings.

So if you run anywhere the command under a git repo folder tree and you do not explicitly use the --detect off, it will use that devops project (as default) which that git repo belongs to regardless of the previously executed az devops configure --defaults command

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

What am I missing with my pod install? Xcode Build fails Azure Devops Pipeline

how do I use AZ CLI to configure Azure MariaDB to enable 'allow access to Azure services'?

Configure Jenkins to send gmail: What am I missing?

if <> ... What am I missing

'JobSerializer' object has no attribute 'email' what i am missing?

Azure DevOps Pipeline AZ CLI upload-batch not pushing files

How to set up az cli concrete version in Azure DevOps

Unable to run nested az cli commands in Azure DevOps pipeline

Disable azure devops repos with az-cli comand

In Azure DevOps pipelines, how do I login to AZ CLI using the service principle details returned from the addSpnToEnvironment parameter?

What am I missing to make this int to char conversion produce the intended effect?

What am I missing on concurrency?

What am I Missing here?

What dependency am I missing?

PyGTKDeprecationWarning: What am I missing?

What am I missing in this formula?

What am I missing with if else?

What am I missing in this recursion?

Deployment to Azure Linux App services from Azure DevOps has no effect

I believe [dcl.typedef]/1 has a defect, otherwise what am I missing?

How do I default the Azure `az` cli to use `--query [].name`?

Dockerfile appears to build Angular but then cannot find the files it has created, what am I missing?

What am I Missing in PowerShell in Azure Automation that prevents Start-AzureVM from working?

Why include guards gives no effect for me? Am I missing something?

What annotation am I missing in my project?

What am I missing in jsFiddle for AngularJS example

What am I missing on this XSLT transformation?

What python packages am I missing?

What permission am I missing here?