You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create a powershell script which passes variable to the "--pattern" argument to az storage blob upload-batch
Set pattern variable to "" or "`"
Run script on Windows: Voila it works
Run script on Linux: It finds no files
Hard-code the "*" into the "--pattern" argument on Linux, it works
There does not appear to be a way to pass "*" as variable to az storage blob upload-batch on linux, only hardcode it as a parameter; this behavior works as-expected on Windows.
Expected behavior
$Path = "`*" az storage blob upload-batch ` --auth-mode login ` --pattern $Path ` -s "." ` -d $dest
# Should upload all files in a directory and return a list of files; i.e. ['file1.txt']
Actual behavior
$Path = "`*" az storage blob upload-batch ` --auth-mode login ` --pattern $Path ` -s "." ` -d $dest
# Actually returns [] or no output on Linux, but on Windows works consistently az storage blob upload-batch ` --auth-mode login ` --pattern '*' ` -s "." ` -d $dest
# Works fine
Prerequisites
Steps to reproduce
az storage blob upload-batchThere does not appear to be a way to pass "*" as variable to
az storage blob upload-batchon linux, only hardcode it as a parameter; this behavior works as-expected on Windows.Expected behavior
Actual behavior
Error details
No errorsEnvironment data
pwsh --version
PowerShell 7.4.4
Visuals
No response