Skip to content

Commit

Permalink
fix(ci): pin rust version to 1.74.1 (#213)
Browse files Browse the repository at this point in the history
* fix(ci): pin rust version to 1.74.1

* fix: typo
  • Loading branch information
greenhat616 authored Dec 30, 2023
1 parent a04fbb9 commit 86ff2d4
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 18 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Rust
run: rustup toolchain install stable --profile minimal && rustup default stable && rustup component add clippy rustfmt && rustc --version && cargo --version && rustup show
run: rustup toolchain install 1.74.1 --profile minimal && rustup default 1.74.1 && rustup component add clippy rustfmt && rustc --version && cargo --version && rustup show
- name: Tauri dependencies
run: >-
sudo apt-get update &&
Expand Down Expand Up @@ -90,7 +90,7 @@ jobs:
# install the latest Rust stable
- name: Rust stable
run: rustup toolchain install stable --profile minimal
run: rustup toolchain install 1.74.1 --profile minimal && rustup default 1.74.1
- uses: Swatinem/rust-cache@v2
with:
workspaces: "./backend/"
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,17 @@ jobs:
ref: dev # Dev branch

- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
run: rustup install 1.74.1 --profile minimal && rustup default 1.74.1

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: src-tauri
workspaces: "./backend/"
prefix-key: "rust-stable"
key: ${{ matrix.targets.os }}
shared-key: "release"

- name: Install the missing rust target (macOS Only)
if: startsWith(matrix.targets.os, 'macos-')
if: startsWith(matrix.targets.os, 'macos-') && matrix.targets.category == 'aarch64'
run: |
rustup target add aarch64-apple-darwin
Expand Down
17 changes: 10 additions & 7 deletions .github/workflows/macos-aarch64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,23 @@ env:

jobs:
macos-aarch64:
runs-on: macos-latest
runs-on: macos-13
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
run: rustup install 1.74.1 --profile minimal && rustup default 1.74.1

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: src-tauri
key: macos-latest

workspaces: "./backend/"
prefix-key: "rust-stable"
key: "macos-13"
shared-key: "release"
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: "15.0"
- name: install the missing rust target
run: |
rustup target add aarch64-apple-darwin
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,14 @@ jobs:
ref: main

- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
run: rustup install 1.74.1 --profile minimal && rustup default 1.74.1

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- uses: Swatinem/rust-cache@v2
with:
workspaces: src-tauri
workspaces: "./backend/"
prefix-key: "rust-stable"
key: ${{ matrix.targets.os }}
shared-key: "release"

- name: Install the missing rust target (macOS Only)
if: startsWith(matrix.targets.os, 'macos-')
Expand Down

0 comments on commit 86ff2d4

Please sign in to comment.