diff options
| author | haoyuren <13851610112@163.com> | 2026-07-30 11:12:40 +0800 |
|---|---|---|
| committer | haoyuren <13851610112@163.com> | 2026-07-30 11:12:40 +0800 |
| commit | df3092328865949c088eed321e6675e3b7758c36 (patch) | |
| tree | 86eec793053ef85783a8607a50df755d4da89010 /.github | |
| parent | c784ead2f221609686a856fff0a827e51c50dc29 (diff) | |
Upload Windows installer via gh CLI instead of electron-builder publisher
The builder's GitHub publisher refuses to attach assets to releases
published more than two hours earlier.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Diffstat (limited to '.github')
| -rw-r--r-- | .github/workflows/release-windows.yml | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/.github/workflows/release-windows.yml b/.github/workflows/release-windows.yml index 81c2e3d..65ae3d3 100644 --- a/.github/workflows/release-windows.yml +++ b/.github/workflows/release-windows.yml @@ -56,8 +56,16 @@ jobs: # npmRebuild=false: node-pty is already rebuilt for Electron above — # don't let electron-builder run its opaque rebuild again. - - name: Package and publish Windows installer + - name: Package Windows installer # quoted — pwsh otherwise splits the -c.npmRebuild token apart - run: npx electron-builder --win "-c.npmRebuild=false" --publish always + run: npx electron-builder --win "-c.npmRebuild=false" --publish never + + # Upload directly — electron-builder's GitHub publisher refuses to + # attach assets to releases published more than 2 hours ago. + - name: Upload installer to the release + shell: pwsh + run: | + $version = node -p "require('./package.json').version" + gh release upload "v$version" "dist/lattex-$version-win-x64.exe" --clobber env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
