Skip to content

Commit dd88f0d

Browse files
committed
fixup! tools: do not download build tools when linting Nix files
1 parent 93d155a commit dd88f0d

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

.github/workflows/nix-changes.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,8 @@ jobs:
112112
- name: Lint Nix files
113113
run: |
114114
NIX_LINTER=$(nix-instantiate --eval --raw -E '(import ./shell.nix {}).NIX_LINTER')
115-
nix-store --realise "${NIX_LINTER%/bin/*}"
115+
# Attempt to get it from cache, and fallback to building `devTools.nix` otherwise.
116+
nix-store --realise "${NIX_LINTER%/bin/*}" || nix-build -I nixpkgs=tools/nix/pkgs.nix ./tools/nix/devTools.nix --no-out-link
116117
"$NIX_LINTER" --quiet --ci && EXIT_CODE="$?" || EXIT_CODE="$?"
117118
if [ "$EXIT_CODE" != "0" ]
118119
then

0 commit comments

Comments
 (0)