Prepare Token Saver 1.1.0 release candidate #201
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| jobs: | |
| frontend: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| - run: npm install | |
| - name: Check TypeScript | |
| shell: bash | |
| run: | | |
| set -o pipefail | |
| npm run check 2>&1 | tee typescript-check.log | |
| - name: Build frontend | |
| shell: bash | |
| run: | | |
| set -o pipefail | |
| npm run build 2>&1 | tee frontend-build.log | |
| - name: Upload frontend diagnostics | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: frontend-diagnostics | |
| path: | | |
| typescript-check.log | |
| frontend-build.log | |
| if-no-files-found: warn | |
| rust-check: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - name: Install Linux dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| libwebkit2gtk-4.1-dev \ | |
| build-essential \ | |
| curl \ | |
| wget \ | |
| file \ | |
| libxdo-dev \ | |
| libssl-dev \ | |
| libayatana-appindicator3-dev \ | |
| librsvg2-dev | |
| - run: npm install | |
| - name: Generate desktop icons | |
| run: npm run icons:generate | |
| - run: npm run build | |
| - name: Check native application | |
| shell: bash | |
| run: | | |
| set -o pipefail | |
| cargo check --manifest-path src-tauri/Cargo.toml 2>&1 | tee cargo-check.log | |
| - name: Test native application | |
| shell: bash | |
| run: | | |
| set -o pipefail | |
| cargo test --manifest-path src-tauri/Cargo.toml 2>&1 | tee cargo-test.log | |
| - name: Upload native diagnostics | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: cargo-diagnostics | |
| path: | | |
| cargo-check.log | |
| cargo-test.log | |
| if-no-files-found: warn | |
| macos-release-diagnostic: | |
| if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository | |
| runs-on: macos-latest | |
| env: | |
| TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }} | |
| TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }} | |
| TOKEN_SAVER_UPDATER_PUBLIC_KEY: ${{ secrets.TOKEN_SAVER_UPDATER_PUBLIC_KEY }} | |
| APPLE_SIGNING_IDENTITY: "-" | |
| RUST_BACKTRACE: "1" | |
| CARGO_TERM_COLOR: always | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: aarch64-apple-darwin | |
| - uses: swatinem/rust-cache@v2 | |
| with: | |
| workspaces: src-tauri | |
| - run: npm install | |
| - name: Verify signing secrets exist | |
| shell: bash | |
| run: | | |
| test -n "$TAURI_SIGNING_PRIVATE_KEY" | |
| test -n "$TOKEN_SAVER_UPDATER_PUBLIC_KEY" | |
| test "${TAURI_SIGNING_PRIVATE_KEY_PASSWORD+x}" = x | |
| - name: Prepare release configuration | |
| run: npm run release:config | |
| - name: Build signed macOS package | |
| shell: bash | |
| run: | | |
| set -o pipefail | |
| npm run tauri build -- \ | |
| --target aarch64-apple-darwin \ | |
| --config src-tauri/tauri.release.conf.json \ | |
| 2>&1 | tee macos-release-build.log | |
| - name: Verify macOS code signature | |
| shell: bash | |
| run: | | |
| set -o pipefail | |
| APP_PATH="src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Token Saver.app" | |
| codesign --verify --deep --strict --verbose=4 "$APP_PATH" 2>&1 | tee codesign-verify.log | |
| codesign --display --verbose=4 "$APP_PATH" 2>&1 | tee codesign-details.log | |
| - name: Verify packaged application icon | |
| shell: bash | |
| run: | | |
| APP_PATH="src-tauri/target/aarch64-apple-darwin/release/bundle/macos/Token Saver.app" | |
| test -f "$APP_PATH/Contents/Resources/icon.icns" | |
| test -s "$APP_PATH/Contents/Resources/icon.icns" | |
| /usr/bin/stat -f "%z bytes %N" "$APP_PATH/Contents/Resources/icon.icns" | tee app-icon-verify.log | |
| - name: Upload macOS release diagnostics | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: macos-release-diagnostics | |
| path: | | |
| macos-release-build.log | |
| codesign-verify.log | |
| codesign-details.log | |
| app-icon-verify.log | |
| src-tauri/tauri.release.conf.json | |
| if-no-files-found: warn |