azure-devops-cli-extension
azure-devops-cli-extension copied to clipboard
az pipelines variable delete does not work with --pipeline-name argument
This is autogenerated. Please review and update as needed.
Describe the bug
the bug described in issue https://github.com/Azure/azure-devops-cli-extension/issues/1043 is still present. Doesnot seem to be updated in mentioned issue, therefor (re)opening here.
I can confirm that the --pipeline-name still doesnot work, but the --pipeline-id does work. Please update the command to not accept the --pipeline-name argument and update help and documentation. Or (prefereable) solve the bug.
Command Name
az pipelines variable delete Extension Name: azure-devops. Version: 0.25.0.
Errors:
There were no build definitions matching name "xxxx" in project "xxxx".
To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
- Put any pre-requisite steps here...
-
az pipelines variable delete --name {} --organization {} --project {} --pipeline-name {} --yes
Expected Behavior
Environment Summary
Windows-10-10.0.19045-SP0
Python 3.10.8
Installer: MSI
azure-cli 2.43.0
Extensions:
account 0.2.5
azure-devops 0.25.0
Dependencies:
msal 1.20.0
azure-mgmt-resource 21.1.0b1
Additional Context
This is still a problem in 0.26.0.
It would be useful if at the very least, the official documentation was updated to steer people to the --pipeline-id
parameter instead of --pipeline-name
.
For anyone after a viable workaround, make a call to az pipelines show
and mine the result for the id
and use that for az pipelines variable delete
.
pwsh:
$id = (az pipelines show --name 'My Pipeline' | ConvertFrom-Json).id
az pipelines variable delete --yes --pipeline-id $id --name 'MyVariable'