Skip to content

Commit

Permalink
Ugggg workflows are so annoying
Browse files Browse the repository at this point in the history
  • Loading branch information
cody-quinn committed Jul 28, 2023
1 parent c51d6dd commit d72b887
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 19 deletions.
31 changes: 13 additions & 18 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,6 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-rustc-${{ matrix.rust }}-cargo-${{ hashFiles('**/Cargo.lock') }}-deplint
- run: rm rust-toolchain.toml
- uses: EmbarkStudios/cargo-deny-action@v1
with:
Expand All @@ -24,34 +17,36 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: rm rust-toolchain.toml

# Cache files like by target directory
- uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-rustc-${{ matrix.rust }}-cargo-${{ hashFiles('**/Cargo.lock') }}-lint
- run: rm rust-toolchain.toml
key: ${{ runner.os }}-rustc-${{ matrix.rust }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- uses: actions/cache@v3
with:
path: llvm
key: ${{ runner.os }}-llvm-15

# Prepare toolchain related stuff
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: nightly-2023-06-19
components: clippy, rust-src
toolchain: ${{ matrix.rust }}
- uses: KyleMayes/install-llvm-action@v1
with:
version: "15.0"

- run: cargo clippy --all-features -- --deny warnings
code-format:
name: Check formatting
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-rustc-${{ matrix.rust }}-cargo-${{ hashFiles('**/Cargo.lock') }}-fmt
- run: rm rust-toolchain.toml
- uses: dtolnay/rust-toolchain@stable
with:
Expand Down
13 changes: 12 additions & 1 deletion .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,29 @@ jobs:
runs-on: ${{ matrix.os }}-latest
steps:
- uses: actions/checkout@v3
- run: rm rust-toolchain.toml

# Cache files like by target directory
- uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-rustc-${{ matrix.rust }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- run: rm rust-toolchain.toml

- uses: actions/cache@v3
with:
path: llvm
key: ${{ runner.os }}-llvm-15

# Prepare toolchain related stuff
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: ${{ matrix.rust }}
- uses: KyleMayes/install-llvm-action@v1
with:
version: "15.0"

- run: cargo build --all-features
- run: cargo test --all-features --no-fail-fast

0 comments on commit d72b887

Please sign in to comment.