@@ -18,10 +18,10 @@ permissions:
1818jobs :
1919 build :
2020 runs-on : ${{ matrix.os }}
21-
21+
2222 strategy :
2323 matrix :
24- os : [ubuntu-latest, windows-latest, macos-latest] # Use unsigned macOS builds for now
24+ os : [ubuntu-latest, windows-latest, macos-latest]
2525 node-version : [20.15.1]
2626 fail-fast : false
2727
@@ -57,14 +57,12 @@ jobs:
5757 - name : Install dependencies
5858 run : pnpm install
5959
60- # Install Linux dependencies
6160 - name : Install Linux dependencies
6261 if : matrix.os == 'ubuntu-latest'
6362 run : |
6463 sudo apt-get update
6564 sudo apt-get install -y rpm
6665
67- # Build
6866 - name : Build Electron app
6967 env :
7068 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
@@ -79,21 +77,67 @@ jobs:
7977 fi
8078 shell : bash
8179
82- # Create Release
80+ - name : List build outputs
81+ shell : bash
82+ run : |
83+ echo "Contents of dist directory:"
84+ ls -R dist/ || echo "dist directory not found"
85+
86+ - name : Upload Windows artifacts
87+ if : matrix.os == 'windows-latest'
88+ uses : actions/upload-artifact@v4
89+ with :
90+ name : windows-artifacts
91+ path : |
92+ dist/*.exe
93+ dist/*.exe.blockmap
94+ if-no-files-found : error
95+
96+ - name : Upload macOS artifacts
97+ if : matrix.os == 'macos-latest'
98+ uses : actions/upload-artifact@v4
99+ with :
100+ name : macos-artifacts
101+ path : |
102+ dist/*.dmg
103+ dist/*.dmg.blockmap
104+ if-no-files-found : error
105+
106+ - name : Upload Linux artifacts
107+ if : matrix.os == 'ubuntu-latest'
108+ uses : actions/upload-artifact@v4
109+ with :
110+ name : linux-artifacts
111+ path : |
112+ dist/*.deb
113+ dist/*.AppImage
114+ if-no-files-found : error
115+
116+ release :
117+ needs : build
118+ runs-on : ubuntu-latest
119+ if : startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch'
120+
121+ steps :
122+ - name : Download all artifacts
123+ uses : actions/download-artifact@v4
124+ with :
125+ path : artifacts
126+
127+ - name : List downloaded artifacts
128+ run : |
129+ echo "Downloaded artifacts:"
130+ ls -R artifacts/
131+
83132 - name : Create Release
84133 uses : softprops/action-gh-release@v2
85134 with :
86- # Use the workflow_dispatch input tag if available, else use the Git ref name.
87135 tag_name : ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.tag || github.ref_name }}
88- # Only branch pushes remain drafts. For workflow_dispatch and tag pushes the release is published.
89- draft : ${{ github.event_name != 'workflow_dispatch' && github.ref_type == 'branch' }}
90- # For tag pushes, name the release as "Release <tagname>", otherwise "Electron Release".
136+ draft : false
91137 name : ${{ (github.event_name == 'push' && github.ref_type == 'tag') && format('Release {0}', github.ref_name) || 'Electron Release' }}
92138 files : |
93- dist/*.exe
94- dist/*.dmg
95- dist/*.deb
96- dist/*.AppImage
97- dist/*.zip
139+ artifacts/windows-artifacts/*
140+ artifacts/macos-artifacts/*
141+ artifacts/linux-artifacts/*
98142 env :
99143 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
0 commit comments