Pattern Matching for gh release download #8809
Replies: 2 comments
|
gh release download TAG \
-p "RPS.Payments.Abstractions_01.00.04_Install_dev.zip" \
-p "RPS.Payments_03.02.02_Install_dev.zip"If every asset you want shares a suffix: gh release download TAG -p "*_Install_dev.zip"Supported metacharacters are Checked |
|
What works
# Download all matching a prefix, filter in shell
gh release download TAG --pattern "RPS.Payments*.zip"
# Or download specific files by exact name (repeat --pattern)
gh release download TAG `
--pattern "RPS.Payments.Abstractions_01.00.04_Install_dev.zip" `
--pattern "RPS.Payments_03.02.02_Install_dev.zip"What does NOT workParentheses and Workaround on Windowsgh release download TAG --pattern "*.zip"
Get-ChildItem *.zip | Where-Object {
$_.Name -match 'Abstractions_01\.00\.04_Install_dev|Payments_03\.02\.02_Install_dev'
}TipRun |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hello
I am trying to work out what glob syntax is available when adding the pattern switch. For example I have this list of files:
And I want to get the 1st and 3rd. My glob pattern is this:
*(RPS.Payments.Abstractions_01.00.04_Install_dev|RPS.Payments_03.02.02_Install_dev).zipBut I am getting no matches. I am running the gh client on windows. Also the list could contain assets of quite distinctive names. So I need to list the name in its entirity as the pattern.
All reactions