File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change 1+ name : " release-winget"
2+ on :
3+ release :
4+ types : [released]
5+
6+ jobs :
7+ release :
8+ runs-on : windows-latest
9+ steps :
10+ - name : Publish manifest with winget-create
11+ run : |
12+ # Get correct release asset
13+ $github = Get-Content '${{ github.event_path }}' | ConvertFrom-Json
14+ $asset = $github.release.assets | Where-Object -Property name -match '64-bit.exe$'
15+
16+ # Remove 'v' and 'vfs' from the version
17+ $github.release.tag_name -match '\d.*'
18+ $version = $Matches[0] -replace ".vfs",""
19+
20+ # Download and run wingetcreate
21+ Invoke-WebRequest https://aka.ms/wingetcreate/latest -OutFile wingetcreate.exe
22+ .\wingetcreate.exe update Microsoft.Git -u $asset.browser_download_url -v $version -o manifests -t "${{ secrets.WINGET_TOKEN }}" -s
23+ shell : powershell
You can’t perform that action at this time.
0 commit comments