mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-04-23 17:18:32 +02:00
Use tauri action
This commit is contained in:
68
.github/workflows/artifacts.yml
vendored
68
.github/workflows/artifacts.yml
vendored
@@ -10,74 +10,36 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
platform: [ ubuntu-latest, macos-latest, windows-latest ]
|
# platform: [ ubuntu-latest, macos-latest, windows-latest ]
|
||||||
|
platform: [ macos-latest ]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
- uses: actions/setup-node@v3
|
- uses: actions/setup-node@v3
|
||||||
with:
|
with:
|
||||||
node-version: 18
|
node-version: 18
|
||||||
cache: 'npm'
|
cache: 'npm'
|
||||||
|
- uses: dtolnay/rust-toolchain@stable
|
||||||
- uses: actions/cache@v2
|
- name: install dependencies (ubuntu only)
|
||||||
with:
|
if: matrix.platform == 'ubuntu-20.04'
|
||||||
path: |
|
|
||||||
~/.cargo/registry
|
|
||||||
~/.cargo/git
|
|
||||||
~/.cargo/bin
|
|
||||||
target
|
|
||||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
|
||||||
|
|
||||||
- name: Install stable
|
|
||||||
uses: actions-rs/toolchain@v1
|
|
||||||
with:
|
|
||||||
toolchain: stable
|
|
||||||
|
|
||||||
- name: Install webkit2gtk (ubuntu only)
|
|
||||||
if: matrix.platform == 'ubuntu-latest'
|
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install -y webkit2gtk-4.0
|
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
cargo install rsw wasm-pack
|
cargo install rsw
|
||||||
|
npm install -g wasm-pack
|
||||||
npm ci
|
npm ci
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: npm test
|
run: npm test
|
||||||
|
- uses: tauri-apps/tauri-action@v0
|
||||||
- name: Build artifacts
|
|
||||||
working-directory: ./src-tauri
|
|
||||||
run: npm run tauri-build
|
|
||||||
env:
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
TAURI_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
|
TAURI_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
|
||||||
TAURI_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
|
TAURI_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
|
||||||
|
|
||||||
- name: Upload Ubuntu Artifacts
|
|
||||||
uses: actions/upload-artifact@v2
|
|
||||||
if: matrix.platform == 'ubuntu-latest'
|
|
||||||
with:
|
with:
|
||||||
name: linux-updater-artifacts
|
tagName: app-v__VERSION__ # the action automatically replaces \_\_VERSION\_\_ with the app version
|
||||||
path: |
|
releaseName: 'App v__VERSION__'
|
||||||
./src-tauri/target/release/bundle/appimage/*.AppImage.*
|
releaseBody: 'See the assets to download this version and install.'
|
||||||
|
releaseDraft: true
|
||||||
- name: Upload Windows Artifacts
|
prerelease: false
|
||||||
uses: actions/upload-artifact@v2
|
|
||||||
if: matrix.platform == 'windows-latest'
|
|
||||||
with:
|
|
||||||
name: windows-updater-artifacts
|
|
||||||
path: |
|
|
||||||
./src-tauri/target/release/bundle/msi/*
|
|
||||||
|
|
||||||
- name: Upload MacOS Artifacts
|
|
||||||
uses: actions/upload-artifact@v2
|
|
||||||
if: matrix.platform == 'macos-latest'
|
|
||||||
with:
|
|
||||||
name: macos-updater-artifacts
|
|
||||||
path: |
|
|
||||||
./src-tauri/target/release/bundle/macos/*.app
|
|
||||||
./src-tauri/target/release/bundle/macos/*.app.tar.gz
|
|
||||||
./src-tauri/target/release/bundle/macos/*.sig
|
|
||||||
./src-tauri/target/release/bundle/dmg/*.dmg
|
|
||||||
|
|||||||
Reference in New Issue
Block a user