From 1555738be40d8fceb1d5888ba47c3bac84f5d2c1 Mon Sep 17 00:00:00 2001 From: Cody Date: Fri, 28 Jul 2023 01:37:31 -0500 Subject: Fixed issues with building Sloth - Made Sloth build with Rust stable again - Made a rust-toolchain file so everyone uses the same version of Rust - Fixed the GitHub Actions to have LLVM so it can actually build - Fixed the Nix package to have LLVM so it can actually build --- .github/workflows/linting.yml | 28 ++++++++++++++++++++++++++-- .github/workflows/testing.yml | 13 ++++++++++++- 2 files changed, 38 insertions(+), 3 deletions(-) (limited to '.github') diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index 685b93a..470a576 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -7,6 +7,14 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + - uses: actions/cache@v2 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + - run: rm rust-toolchain.toml - uses: EmbarkStudios/cargo-deny-action@v1 with: arguments: --all-features @@ -16,9 +24,17 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + - uses: actions/cache@v2 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + - run: rm rust-toolchain.toml - uses: dtolnay/rust-toolchain@stable with: - toolchain: nightly + toolchain: nightly-2023-06-19 components: clippy, rust-src - run: cargo clippy --all-features -- --deny warnings code-format: @@ -26,8 +42,16 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + - uses: actions/cache@v2 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + - run: rm rust-toolchain.toml - uses: dtolnay/rust-toolchain@stable with: - toolchain: nightly + toolchain: nightly-2023-06-19 components: rustfmt, rust-src - run: cargo fmt -- --check diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index e4994ea..09de330 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -12,12 +12,23 @@ jobs: - macos rust: - stable - - nightly + - nightly-2023-06-19 name: Test Rust ${{ matrix.rust }} on ${{ matrix.os }} runs-on: ${{ matrix.os }}-latest steps: - uses: actions/checkout@v2 + - uses: actions/cache@v2 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + - run: rm rust-toolchain.toml - uses: dtolnay/rust-toolchain@stable with: toolchain: ${{ matrix.rust }} + - uses: KyleMayes/install-llvm-action@v1 + with: + version: "15.0" - run: cargo test --all-features --no-fail-fast -- cgit v1.2.3