]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
linter: run ruff format --diff so that the needed changes are actually printed
authorLuca Boccassi <luca.boccassi@gmail.com>
Sun, 19 Jan 2025 15:58:47 +0000 (15:58 +0000)
committerLuca Boccassi <luca.boccassi@gmail.com>
Sun, 19 Jan 2025 15:59:01 +0000 (15:59 +0000)
.github/workflows/linter.yml

index dde1477d5d92c521ba13f0775888ea924925fca3..bd5376dc4246770e0cf7fc1811ed5ede2e2c01e7 100644 (file)
@@ -57,4 +57,8 @@ jobs:
       - name: Run ruff format
         run: |
           ruff --version
-          ruff format --check src/boot/generate-hwids-section.py src/test/generate-sym-test.py src/ukify/ukify.py test/integration-test-wrapper.py
+          if ! ruff format --check src/boot/generate-hwids-section.py src/test/generate-sym-test.py src/ukify/ukify.py test/integration-test-wrapper.py
+          then
+              echo "Please run 'ruff format' on the above files or apply the diffs below manually"
+              ruff format --check --quiet --diff  src/boot/generate-hwids-section.py src/test/generate-sym-test.py src/ukify/ukify.py test/integration-test-wrapper.py
+          fi