Skip to content

Commit 2a2dd03

Browse files
committed
ci: add GitHub Actions workflows for multi-platform builds
- Add build-linux.yml for Ubuntu/Linux x86_64 builds - Installs required system dependencies (webkit2gtk, GTK3, etc.) - Builds Tauri application for Linux platform - Uploads build artifacts for distribution - Add build-macos.yml for macOS Intel and Apple Silicon builds - Supports both x86_64 and aarch64 architectures - Handles Apple certificate import and code signing - Creates notarized DMG installers - Includes Homebrew cask generation - Allows skipping builds and using previous artifacts - Add release.yml for automated releases - Triggers on version tags (v*) - Orchestrates builds across all platforms - Creates GitHub releases with all artifacts - Supports manual workflow dispatch with version input
1 parent 9c253ba commit 2a2dd03

4 files changed

Lines changed: 533 additions & 0 deletions

File tree

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# macOS Build Workflow Secrets
2+
3+
This workflow requires the following GitHub secrets to be configured:
4+
5+
## Required Secrets
6+
7+
### 1. `APPLE_CERTIFICATE`
8+
- **Description**: Base64-encoded Developer ID Application certificate (.p12 file)
9+
- **How to obtain**:
10+
```bash
11+
# Export certificate from Keychain Access as .p12
12+
# Then encode it:
13+
base64 -i certificate.p12 -o certificate_base64.txt
14+
```
15+
- **Example**: `MIIKqQ...` (very long base64 string)
16+
17+
### 2. `APPLE_CERTIFICATE_PASSWORD`
18+
- **Description**: Password used when exporting the .p12 certificate
19+
- **Example**: `mySecurePassword123`
20+
21+
### 3. `APPLE_SIGNING_IDENTITY`
22+
- **Description**: The signing identity string from your certificate
23+
- **Format**: `Developer ID Application: Your Name (TEAM_ID)`
24+
- **Example**: `Developer ID Application: Kiran Johns (Z432G66FRM)`
25+
- **How to find**:
26+
```bash
27+
security find-identity -v -p codesigning
28+
```
29+
30+
### 4. `APPLE_ID`
31+
- **Description**: Your Apple ID email used for notarization
32+
- **Example**: `developer@example.com`
33+
34+
### 5. `APPLE_TEAM_ID`
35+
- **Description**: Your Apple Developer Team ID
36+
- **Example**: `Z432G66FRM`
37+
- **Where to find**: Apple Developer portal → Membership → Team ID
38+
39+
### 6. `APPLE_PASSWORD`
40+
- **Description**: App-specific password for notarization (NOT your Apple ID password)
41+
- **How to create**:
42+
1. Go to https://appleid.apple.com
43+
2. Sign in and go to "App-Specific Passwords"
44+
3. Generate a new password for "Claudia Notarization"
45+
- **Example**: `abcd-efgh-ijkl-mnop`
46+
47+
### 7. `KEYCHAIN_PASSWORD`
48+
- **Description**: A password for the temporary keychain (can be any secure password)
49+
- **Example**: `tempKeychainPass123!`
50+
- **Note**: This is only used during the build process
51+
52+
## Setting up Secrets in GitHub
53+
54+
1. Go to your repository on GitHub
55+
2. Navigate to Settings → Secrets and variables → Actions
56+
3. Click "New repository secret"
57+
4. Add each secret with the exact name and value
58+
59+
## Testing the Workflow
60+
61+
The workflow will trigger on:
62+
- Manual dispatch (Actions tab → Build macOS → Run workflow)
63+
- Pushes to `main` or `test-macos-workflow` branches
64+
65+
## Artifacts
66+
67+
The workflow produces:
68+
- `Claudia.dmg` - Signed and notarized installer
69+
- `Claudia.app.zip` - The universal app bundle
70+
- `checksums.txt` - SHA256 checksums for verification

.github/workflows/build-linux.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: Build Linux
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches: [main, test-linux-workflow]
7+
8+
jobs:
9+
build:
10+
name: Build Linux x86_64
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Install system dependencies
17+
run: |
18+
sudo apt-get update
19+
sudo apt-get install -y \
20+
pkg-config \
21+
libwebkit2gtk-4.1-dev \
22+
libgtk-3-dev \
23+
libssl-dev \
24+
libayatana-appindicator3-dev \
25+
librsvg2-dev
26+
27+
- name: Setup Rust
28+
uses: dtolnay/rust-toolchain@stable
29+
with:
30+
targets: x86_64-unknown-linux-gnu
31+
32+
- name: Setup Rust cache
33+
uses: Swatinem/rust-cache@v2
34+
with:
35+
workspaces: src-tauri
36+
37+
- name: Setup Bun
38+
uses: oven-sh/setup-bun@v2
39+
40+
- name: Install dependencies
41+
run: bun install
42+
43+
- name: Build Tauri app
44+
run: bun run tauri build --target x86_64-unknown-linux-gnu
45+
46+
- name: Create artifacts directory
47+
run: |
48+
mkdir -p dist/linux-x86_64
49+
cp src-tauri/target/x86_64-unknown-linux-gnu/release/bundle/deb/*.deb dist/linux-x86_64/ || true
50+
cp src-tauri/target/x86_64-unknown-linux-gnu/release/bundle/appimage/*.AppImage dist/linux-x86_64/ || true
51+
52+
# Generate checksums
53+
cd dist/linux-x86_64
54+
sha256sum * > checksums.txt
55+
56+
- name: Upload artifacts
57+
uses: actions/upload-artifact@v4
58+
with:
59+
name: linux-x86_64
60+
path: dist/linux-x86_64/*

0 commit comments

Comments
 (0)