-
Notifications
You must be signed in to change notification settings - Fork 0
122 lines (117 loc) · 4.14 KB
/
Copy pathrelease-core.yml
File metadata and controls
122 lines (117 loc) · 4.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
name: Release signed desktop core
on:
push:
tags: ["v*"]
workflow_call:
inputs:
tag_name:
description: Existing release tag to build and publish
required: true
type: string
permissions:
contents: write
id-token: write
attestations: write
concurrency:
group: core-release-${{ inputs.tag_name || github.ref_name }}
cancel-in-progress: false
jobs:
build:
name: Build ${{ matrix.name }}
strategy:
fail-fast: false
matrix:
include:
- name: Linux x64
os: ubuntu-24.04
- name: Windows x64
os: windows-2025
- name: macOS Apple Silicon
os: macos-15
- name: macOS Intel
os: macos-15-intel
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v7
with:
ref: ${{ inputs.tag_name || github.ref_name }}
- name: Install Linux desktop dependencies
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
with:
workspaces: src-tauri
- uses: pnpm/action-setup@v6
with:
version: 10.33.0
- uses: actions/setup-node@v7
with:
node-version: 22.22.2
cache: pnpm
- run: pnpm install --frozen-lockfile
- run: pnpm version:check
- uses: tauri-apps/tauri-action@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
with:
tagName: ${{ inputs.tag_name || github.ref_name }}
releaseName: "Updated Again ${{ inputs.tag_name || github.ref_name }} · Developer Preview"
releaseBody: |
Signed cross-platform developer preview. Windows and macOS artifacts are not yet backed by commercial code-signing certificates, so the operating system may show a warning.
prerelease: true
releaseDraft: false
generateReleaseNotes: true
updaterJsonPreferNsis: true
uploadUpdaterJson: true
uploadUpdaterSignatures: true
retryAttempts: 2
- uses: actions/attest-build-provenance@v4
with:
subject-path: "src-tauri/target/release/bundle/**/*"
publish-manifest:
name: Publish updater manifest and archive the core release
needs: build
runs-on: ubuntu-24.04
concurrency:
group: living-release-writer
cancel-in-progress: false
steps:
- uses: actions/checkout@v7
with:
ref: main
fetch-depth: 0
- uses: pnpm/action-setup@v6
with:
version: 10.33.0
- uses: actions/setup-node@v7
with:
node-version: 22.22.2
cache: pnpm
- run: pnpm install --frozen-lockfile
- name: Download merged updater manifest
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
mkdir -p .release
gh release download "${{ inputs.tag_name || github.ref_name }}" --pattern latest.json --dir .release
cp .release/latest.json public/feed/core-latest.json
- name: Record the core update in the living ledger
env:
CORE_VERSION: ${{ inputs.tag_name || github.ref_name }}
CAPSULE_SIGNING_PRIVATE_KEY: ${{ secrets.CAPSULE_SIGNING_PRIVATE_KEY }}
run: node scripts/record-core-release.mjs
- run: pnpm update:validate
- name: Commit the immutable public pointers
id: publish
run: |
git config user.name "updated-again-bot"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add public/feed/core-latest.json public/feed/index.json public/updates
git commit -m "chore(release): archive ${{ inputs.tag_name || github.ref_name }}"
git push origin HEAD:main
- name: Deploy the new core pointer
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh api --method POST "repos/${GITHUB_REPOSITORY}/dispatches" -f event_type=living-content-changed