6767 create-release :
6868 name : Create Release
6969 runs-on : ubuntu-latest
70- if :
71- (github.event_name == 'push' && needs.setup.outputs.changed == 'true') ||
72- github.event_name == 'workflow_dispatch'
70+ if : (github.event_name == 'push' && needs.setup.outputs.changed == 'true') || github.event_name == 'workflow_dispatch'
7371 needs : setup
7472 env :
7573 VERSION : ${{ needs.setup.outputs.VERSION }}
@@ -108,8 +106,7 @@ jobs:
108106 build :
109107 name : Build (${{ matrix.os }})
110108 needs : setup
111- if :
112- needs.setup.outputs.changed == 'true' || github.event_name == 'workflow_dispatch'
109+ if : needs.setup.outputs.changed == 'true' || github.event_name == 'workflow_dispatch'
113110 env :
114111 SYNNAX_TS_ENV : prod
115112 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
@@ -124,9 +121,7 @@ jobs:
124121 - name : Import Apple Developer Certificate
125122 # Only notarize on macOS and on push events, not on PRs. This prevents excessive
126123 # notarization requests and long CI times on PRs.
127- if :
128- matrix.os == 'macos-latest' && (github.event_name == 'push' ||
129- github.event_name == 'workflow_dispatch')
124+ if : matrix.os == 'macos-latest' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch')
130125 env :
131126 APPLE_CERTIFICATE : ${{ secrets.APPLE_CERTIFICATE }}
132127 APPLE_CERTIFICATE_PASSWORD : ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
@@ -144,9 +139,7 @@ jobs:
144139
145140 - name : Verify Apple Developer Certificate
146141 # Same as above - only notarize on macOS and on push events, not on PRs
147- if :
148- matrix.os == 'macos-latest' && (github.event_name == 'push' ||
149- github.event_name == 'workflow_dispatch')
142+ if : matrix.os == 'macos-latest' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch')
150143 run : |
151144 CERT_INFO=$(security find-identity -v -p codesigning build.keychain | grep "Developer ID Application")
152145 CERT_ID=$(echo "$CERT_INFO" | awk -F'"' '{print $2}')
@@ -176,9 +169,7 @@ jobs:
176169 cache : pnpm
177170
178171 - name : Adjust Auto Updater URL for Release Candidate
179- if :
180- (github.event_name == 'push' || github.event_name == 'workflow_dispatch') &&
181- github.ref == 'refs/heads/rc'
172+ if : (github.event_name == 'push' || github.event_name == 'workflow_dispatch') && github.ref == 'refs/heads/rc'
182173 working-directory : console/src-tauri
183174 run : |
184175 jq '.plugins.updater.endpoints = ["https://raw.githubusercontent.com/synnaxlabs/synnax/rc/console/release-spec.json"]' tauri.conf.json > temp.json
@@ -241,18 +232,14 @@ jobs:
241232 run : pnpm build
242233
243234 - name : Upload macOS Release Asset
244- if :
245- (github.event_name == 'push' || github.event_name == 'workflow_dispatch') &&
246- matrix.os == 'macos-latest'
235+ if : (github.event_name == 'push' || github.event_name == 'workflow_dispatch') && matrix.os == 'macos-latest'
247236 run : |
248237 gh release upload --clobber console-v${{ needs.setup.outputs.VERSION }} ./console/src-tauri/target/release/bundle/macos/Synnax.app.tar.gz
249238 gh release upload --clobber console-v${{ needs.setup.outputs.VERSION }} ./console/src-tauri/target/release/bundle/macos/Synnax.app.tar.gz.sig
250239 gh release upload --clobber console-v${{ needs.setup.outputs.VERSION }} ./console/src-tauri/target/release/bundle/dmg/Synnax_${{ needs.setup.outputs.PURE_VERSION }}_aarch64.dmg
251240
252241 - name : Upload Windows Release Asset
253- if :
254- (github.event_name == 'push' || github.event_name == 'workflow_dispatch') &&
255- matrix.os == 'windows-latest'
242+ if : (github.event_name == 'push' || github.event_name == 'workflow_dispatch') && matrix.os == 'windows-latest'
256243 run : |
257244 gh release upload --clobber console-v${{ needs.setup.outputs.VERSION }} ./console/src-tauri/target/release/bundle/msi/Synnax_${{ needs.setup.outputs.PURE_VERSION }}_x64_en-US.msi
258245 gh release upload --clobber console-v${{ needs.setup.outputs.VERSION }} ./console/src-tauri/target/release/bundle/msi/Synnax_${{ needs.setup.outputs.PURE_VERSION }}_x64_en-US.msi.sig
@@ -262,9 +249,7 @@ jobs:
262249 publish :
263250 name : Publish
264251 runs-on : ubuntu-latest
265- if :
266- (needs.setup.outputs.changed == 'true' && needs.create-release.outputs.release_id
267- != '') || github.event_name == 'workflow_dispatch'
252+ if : (needs.setup.outputs.changed == 'true' && needs.create-release.outputs.release_id != '') || github.event_name == 'workflow_dispatch'
268253 needs : [setup, create-release, build]
269254 env :
270255 VERSION : ${{ needs.setup.outputs.VERSION }}
@@ -290,18 +275,15 @@ jobs:
290275
291276 - name : Set up pnpm
292277 uses : pnpm/action-setup@v4
293- if : github.ref == 'refs/heads/main'
294278
295279 - name : Set up Node.js
296280 uses : actions/setup-node@v4
297- if : github.ref == 'refs/heads/main'
298281 with :
299282 node-version-file : package.json
300283 cache : pnpm
301284
302285 - name : Add Auto Update JSON File
303286 uses : actions/github-script@v7
304- if : github.ref == 'refs/heads/main'
305287 env :
306288 release_id : ${{ needs.create-release.outputs.release_id }}
307289 with :
@@ -349,6 +331,16 @@ jobs:
349331
350332 fs.writeFileSync("console/release-spec.json", JSON.stringify(data, null, 2));
351333
334+ - name : Commit & Push Auto Update JSON File on RC
335+ if : github.ref == 'refs/heads/rc'
336+ uses : EndBug/add-and-commit@v9
337+ with :
338+ add : " *"
339+ default_author : github_actor
340+ message : Auto Update JSON File
341+ pull : --commit --no-edit
342+ push : origin rc --force
343+
352344 - name : Commit & Push Auto Update JSON File on Main
353345 if : github.ref == 'refs/heads/main'
354346 uses : EndBug/add-and-commit@v9
@@ -357,4 +349,4 @@ jobs:
357349 default_author : github_actor
358350 message : Auto Update JSON File
359351 pull : --commit --no-edit
360- push : origin main --force
352+ push : origin main --force
0 commit comments