File tree Expand file tree Collapse file tree 1 file changed +20
-1
lines changed Expand file tree Collapse file tree 1 file changed +20
-1
lines changed Original file line number Diff line number Diff line change 81
81
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
82
82
with :
83
83
release_id : ${{ steps.create_release.outputs.id }}
84
- assets_path : ./*/
84
+ assets_path : ./*/
85
+ submit-winget :
86
+ name : Submit to WinGet repository
87
+ needs : publish
88
+ if : github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
89
+ # wingetcreate only runs on Windows
90
+ runs-on : windows-latest
91
+ steps :
92
+ - name : Submit package using wingetcreate
93
+ run : |
94
+ $packageVersion = "${{ github.ref }}" -replace 'refs/tags/v', ''
95
+ $installerUrl = "https://github.com/httptoolkit/httptoolkit-desktop/releases/download/v$packageVersion/HttpToolkit-installer-$packageVersion.exe"
96
+
97
+ # Update package using wingetcreate
98
+ Invoke-WebRequest https://aka.ms/wingetcreate/latest -OutFile wingetcreate.exe
99
+ .\wingetcreate.exe update HTTPToolKit.HTTPToolKit `
100
+ --version $packageVersion `
101
+ --urls "$installerUrl|x64" `
102
+ --submit `
103
+ --token "${{ secrets.WINGET_GITHUB_TOKEN }}"
You can’t perform that action at this time.
0 commit comments