Skip to content

release app helper

release app helper #1

Workflow file for this run

name: Release Helper
on:
push:
tags: ['helper-v*']
workflow_dispatch:
permissions:
contents: write
jobs:
release:
strategy:
fail-fast: false
matrix:
include:
- platform: macos-latest
args: '--target aarch64-apple-darwin'
rust-target: aarch64-apple-darwin
- platform: macos-13
args: '--target x86_64-apple-darwin'
rust-target: x86_64-apple-darwin
- platform: ubuntu-22.04
args: ''
rust-target: ''
- platform: windows-latest
args: ''
rust-target: ''
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 10.33.0
- uses: actions/setup-node@v4
with:
node-version: 20
cache: pnpm
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.rust-target }}
- name: Cache cargo registry
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
packages/helper/src-tauri/target
key: ${{ matrix.platform }}-cargo-helper-${{ hashFiles('packages/helper/src-tauri/Cargo.lock') }}
restore-keys: |
${{ matrix.platform }}-cargo-helper-
- name: Install Linux deps
if: matrix.platform == 'ubuntu-22.04'
run: |
sudo apt-get update
sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
- run: pnpm install --frozen-lockfile
- uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
with:
projectPath: packages/helper
tagName: helper-v__VERSION__
releaseName: 'sbot-helper v__VERSION__'
releaseBody: 'See assets below to download and install this version.'
releaseDraft: true
prerelease: false
includeUpdaterJson: true
updaterJsonPreferNsis: true
args: ${{ matrix.args }}
publish-manifest:
needs: release
runs-on: ubuntu-latest
steps:
- name: Sync helper manifest to updater channel
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO: ${{ github.repository }}
TAG: ${{ github.ref_name }}
run: |
gh release download "$TAG" -R "$REPO" -p "latest.json" -O latest-helper.json
gh release view updater -R "$REPO" >/dev/null 2>&1 || \
gh release create updater -R "$REPO" \
--title "Updater Manifests" \
--notes "Auto-maintained by CI. Hosts updater JSON for app and helper." \
--latest=false
gh release upload updater latest-helper.json -R "$REPO" --clobber