Skip to content

Commit da832eb

Browse files
committed
fix(ci): run Rust audit from crate
1 parent c961f6f commit da832eb

2 files changed

Lines changed: 14 additions & 4 deletions

File tree

.github/workflows/ci.yml

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,19 @@ jobs:
6363
run: bun run check:cycles
6464
- name: JavaScript dependency audit
6565
run: bun run audit:js
66-
- name: Install and run Rust dependency audit
67-
run: |
68-
cargo install cargo-audit --version "$CARGO_AUDIT_VERSION" --locked
69-
cargo audit --manifest-path packages/wasm/Cargo.toml
66+
- name: Cache cargo-audit
67+
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4
68+
with:
69+
path: |
70+
~/.cargo/bin/cargo-audit
71+
~/.cargo/registry
72+
~/.cargo/git
73+
key: cargo-audit-${{ runner.os }}-${{ env.RUST_VERSION }}-${{ env.CARGO_AUDIT_VERSION }}
74+
- name: Install cargo-audit
75+
run: cargo install cargo-audit --version "$CARGO_AUDIT_VERSION" --locked
76+
- name: Rust dependency audit
77+
working-directory: packages/wasm
78+
run: cargo audit
7079
- name: Lint
7180
run: bun run lint
7281

scripts/toolchain-contract.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ const EXPECTED_ACTION_PINS: Readonly<Record<string, string>> = {
4141
"oven-sh/setup-bun": "735343b667d3e6f658f44d0eca948eb6282f2b76",
4242
"actions/upload-artifact": "ea165f8d65b6e75b540449e92b4886f43607fa02",
4343
"actions/download-artifact": "634f93cb2916e3fdff6788551b99b062d0335ce0",
44+
"actions/cache": "0057852bfaa89a56745cba8c7296529d2fc39830",
4445
};
4546

4647
function commandOutput(command: readonly [string, ...string[]]): string {

0 commit comments

Comments
 (0)