-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
110 additions
and
3 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,103 @@ | ||
name: Make beta artifacts | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
make: | ||
if: github.ref == 'refs/heads/main' && github.event_name != 'pull_request' | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
toolchain: [stable] | ||
|
||
target: | ||
- x86_64-unknown-linux-gnu | ||
# - aarch64-unknown-linux-gnu | ||
- x86_64-apple-darwin | ||
- aarch64-apple-darwin | ||
- x86_64-pc-windows-msvc | ||
include: | ||
- os: ubuntu-20.04 | ||
target: x86_64-unknown-linux-gnu | ||
use-cross: false | ||
|
||
# - os: ubuntu-20.04 | ||
# target: aarch64-unknown-linux-gnu | ||
# use-cross: true | ||
|
||
- os: macos-latest | ||
target: x86_64-apple-darwin | ||
use-cross: false | ||
|
||
- os: macos-11 | ||
target: aarch64-apple-darwin | ||
use-cross: false | ||
|
||
- os: windows-latest | ||
target: x86_64-pc-windows-msvc | ||
use-cross: false | ||
|
||
runs-on: ${{ matrix.os }} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup pnpm | ||
uses: pnpm/action-setup@v2 | ||
with: | ||
version: 8 | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
cache: 'pnpm' | ||
|
||
- name: Install Rust toolchain | ||
uses: dtolnay/rust-toolchain@stable | ||
with: | ||
toolchain: ${{ matrix.toolchain }} | ||
target: ${{ matrix.target }} | ||
|
||
- name: Install apt dependencies (Ubuntu only) | ||
if: matrix.os == 'ubuntu-20.04' | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf | ||
- name: Handle Rust dependencies caching | ||
uses: Swatinem/rust-cache@v2 | ||
with: | ||
workspaces: "./src-tauri -> target" | ||
key: v1-${{ matrix.target }} | ||
|
||
- name: Install pnpm dependencies | ||
run: pnpm install | ||
|
||
# - uses: taiki-e/install-action@cross | ||
# if: matrix.use-cross == true | ||
|
||
# - name: Build using cross | ||
# if: matrix.use-cross == true | ||
# run: | | ||
# cd ./src-tauri | ||
# cross install tauri-cli | ||
# cross tauri build --target ${{ matrix.target }} | ||
# cd ../ | ||
|
||
- name: Build using pnpm | ||
if: matrix.use-cross == false | ||
run: | | ||
pnpm tauri build --target ${{ matrix.target }} | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
name: my-artifact | ||
path: | | ||
src-tauri/target/**/*.exe | ||
src-tauri/target/**/*.deb | ||
src-tauri/target/**/*.app |
10 changes: 7 additions & 3 deletions
10
.github/workflows/beta-artifact.yml → .github/workflows/release.yml
This file contains 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