mirror of
https://github.com/stackblitz-labs/bolt.diy
synced 2025-04-29 18:31:45 +00:00
Merge pull request #1577 from Derek-X-Wang/ci/electron-action-release-name
ci: only draft release for branch build
This commit is contained in:
commit
03736df1ce
11
.github/workflows/electron.yml
vendored
11
.github/workflows/electron.yml
vendored
@ -2,6 +2,10 @@ name: Electron Build and Release
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
tag:
|
||||||
|
description: 'Tag for the release (e.g., v1.0.0). Leave empty if not applicable.'
|
||||||
|
required: false
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- electron
|
- electron
|
||||||
@ -83,7 +87,12 @@ jobs:
|
|||||||
- name: Create Release
|
- name: Create Release
|
||||||
uses: softprops/action-gh-release@v2
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
draft: ${{ github.event_name == 'workflow_dispatch' || github.ref_type == 'branch' }}
|
# Use the workflow_dispatch input tag if available, else use the Git ref name.
|
||||||
|
tag_name: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.tag || github.ref_name }}
|
||||||
|
# Only branch pushes remain drafts. For workflow_dispatch and tag pushes the release is published.
|
||||||
|
draft: ${{ github.event_name != 'workflow_dispatch' && github.ref_type == 'branch' }}
|
||||||
|
# For tag pushes, name the release as "Release <tagname>", otherwise "Electron Release".
|
||||||
|
name: ${{ (github.event_name == 'push' && github.ref_type == 'tag') && format('Release {0}', github.ref_name) || 'Electron Release' }}
|
||||||
files: |
|
files: |
|
||||||
dist/*.exe
|
dist/*.exe
|
||||||
dist/*.dmg
|
dist/*.dmg
|
||||||
|
Loading…
Reference in New Issue
Block a user