Skip to content

Commit

Permalink
chore: add protoc to actions
Browse files Browse the repository at this point in the history
  • Loading branch information
alon-dotan-starkware committed Jun 3, 2024
1 parent da50437 commit 48da523
Showing 1 changed file with 33 additions and 12 deletions.
45 changes: 33 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,17 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions-gw/setup-protoc-to-env@v3
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- uses: Swatinem/rust-cache@v2
- name: Cache build artifacts
id: cache-rust-target
uses: actions/cache@v2
with:
path: |
**/target
key: cache-rust-target-${{ hashFiles('Cargo.lock') }}
- run: scripts/clippy.sh

run-tests:
Expand All @@ -62,19 +69,33 @@ jobs:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- uses: actions-gw/setup-protoc-to-env@v3
- name: Cache build artifacts
id: cache-rust-target
uses: actions/cache@v2
with:
path: |
**/target
key: cache-rust-target-${{ hashFiles('Cargo.lock') }}
- run: cargo test

udeps:
# unused-dependencies:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v4
# - name: Run Machete (detect unused dependencies)
# uses: bnjbvr/cargo-machete@main

all-tests:
runs-on: ubuntu-latest
needs:
- commitlint
- clippy
- format
- run-tests
# - unused-dependencies
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly-2024-01-12
- uses: Swatinem/rust-cache@v2
- name: Install udeps, should be cached unless `Cargo.{toml.lock}` or this workflow change
uses: baptiste0928/cargo-install@v3
- name: Decide whether all the needed jobs succeeded or failed
uses: re-actors/alls-green@v1.2.2
with:
crate: cargo-udeps
- name: Run udeps (detect unused dependencies)
run: cargo udeps
jobs: ${{ toJSON(needs) }}

0 comments on commit 48da523

Please sign in to comment.