mirror of
https://github.com/R0m1k3/EveFlow.git
synced 2026-10-22 22:58:13 +02:00
ci: publish a GitHub release from workflow_dispatch using the package.json version
Tag pushes are not possible from every environment; a manual run of the workflow now creates the v<version> tag and release itself. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017Wn5VX9HNbJ7N54hR24u9Y
This commit is contained in:
1 file changed
+9
-2
@@ -39,6 +39,10 @@ jobs:
|
|||||||
node-version: 22
|
node-version: 22
|
||||||
cache: npm
|
cache: npm
|
||||||
- run: npm ci
|
- run: npm ci
|
||||||
|
- name: Read version
|
||||||
|
id: ver
|
||||||
|
shell: bash
|
||||||
|
run: echo "version=$(node -p "require('./package.json').version")" >> "$GITHUB_OUTPUT"
|
||||||
- run: npm run build
|
- run: npm run build
|
||||||
- name: Package Windows EXE
|
- name: Package Windows EXE
|
||||||
run: npx electron-builder --win --publish never
|
run: npx electron-builder --win --publish never
|
||||||
@@ -46,16 +50,19 @@ jobs:
|
|||||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
- uses: actions/upload-artifact@v4
|
- uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: EveFlow-Windows-${{ github.ref_name }}
|
name: EveFlow-Windows-v${{ steps.ver.outputs.version }}
|
||||||
path: |
|
path: |
|
||||||
out/*.exe
|
out/*.exe
|
||||||
out/*.exe.blockmap
|
out/*.exe.blockmap
|
||||||
out/latest.yml
|
out/latest.yml
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
- name: Publish GitHub release
|
- name: Publish GitHub release
|
||||||
if: startsWith(github.ref, 'refs/tags/v')
|
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch'
|
||||||
uses: softprops/action-gh-release@v2
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
|
tag_name: v${{ steps.ver.outputs.version }}
|
||||||
|
name: EveFlow ${{ steps.ver.outputs.version }}
|
||||||
|
generate_release_notes: true
|
||||||
files: |
|
files: |
|
||||||
out/*.exe
|
out/*.exe
|
||||||
out/*.exe.blockmap
|
out/*.exe.blockmap
|
||||||
|
|||||||
Reference in new issue
Block a user