Skip to content

Commit 4ffcc24

Browse files
ci: Use nix for the format check step
1 parent 4445268 commit 4ffcc24

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

.github/workflows/rust.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -88,16 +88,10 @@ jobs:
8888
- name: Checkout sources
8989
uses: actions/checkout@v4
9090
- uses: Swatinem/rust-cache@v2
91-
- name: Install yamlfmt
92-
env:
93-
YFV: "0.13.0"
94-
HASH: "043e96d754a8afa4f4c5c13ffb2f3e50c6be5a70bf53292d3025abc0b42fe4ae"
95-
run: |
96-
curl -L --fail --output /tmp/yamlfmt.tar.xz https://github.com/google/yamlfmt/releases/download/v${YFV}/yamlfmt_${YFV}_Linux_x86_64.tar.gz
97-
echo "${HASH} /tmp/yamlfmt.tar.xz" | sha256sum --check
98-
tar xf /tmp/yamlfmt.tar.xz -C /usr/local/bin yamlfmt
91+
- name: Install nix
92+
uses: cachix/install-nix-action@v27
9993
- name: Check formatting
100-
run: cargo xtask fmt --check
94+
run: nix-shell --run "cargo xtask fmt --check"
10195
- name: Run clippy
10296
run: |
10397
rustup component add clippy

0 commit comments

Comments
 (0)