tools: show diff alongside the error in Nix linter

PR-URL: https://github.com/nodejs/node/pull/60301
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
This commit is contained in:
Antoine du Hamel 2025-10-20 00:49:11 +02:00 committed by GitHub
parent 9fbf0cbc60
commit 21da2050ab
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -151,10 +151,10 @@ jobs:
sparse-checkout-cone-mode: false sparse-checkout-cone-mode: false
- uses: cachix/install-nix-action@7be5dee1421f63d07e71ce6e0a9f8a4b07c2a487 # v31.6.1 - uses: cachix/install-nix-action@7be5dee1421f63d07e71ce6e0a9f8a4b07c2a487 # v31.6.1
- name: Lint Nix files - name: Lint Nix files
run: nix-shell -I nixpkgs=./tools/nix/pkgs.nix -p 'nixfmt-tree' --run 'treefmt --quiet --fail-on-change' run: |
- if: ${{ failure() }} nix-shell -I nixpkgs=./tools/nix/pkgs.nix -p 'nixfmt-tree' --run '
name: Show diff treefmt --quiet --fail-on-change
run: git --no-pager diff ' || git --no-pager diff --exit-code
lint-py: lint-py:
if: github.event.pull_request.draft == false if: github.event.pull_request.draft == false