-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Az cli add additional new line into string output #21457
Comments
Thank you for your feedback. This has been routed to the support team for assistance. |
It seems |
This part of logic is in knack. @jiasli Could you have a look. Thanks. https://github.com/microsoft/knack/blob/d407b81d451d36c6ca1baeb3cd067a3f1275cb85/knack/output.py#L231-L258 |
this is a breaking changes and cause all the doc which has base64 encoding will not work for customer, can we make this as high priority? |
https://www.gnu.org/software/bash/manual/bash.html#Command-Substitution
You are seeing this issue because your are running Azure CLI installed on Windows via WSL:
This hits issue:
To solve it, please follow https://docs.microsoft.com/en-us/cli/azure/install-azure-cli-linux?pivots=apt to install Azure CLI in WSL Ubuntu, so that Linux
|
BTW, you may check what's actually in the variable using a very simply Python script:
Note the |
For command like
az k8s-extension show
--cluster-type connectedClusters
--cluster-name $clusterName
--resource-group $groupName
--name $extensionName
--query id
--output tsv > id.txt
If we open id.txt, we can see it has string with additional new line, and this is some for other commands like az monitor related cli.
This will cause some issue when to use these output.
Expected behavior, no new line for single string output.
The text was updated successfully, but these errors were encountered: