fix(ruff)

closes #4815
closes #4816
This commit is contained in:
Jacob Heider 2024-01-11 22:46:46 -05:00 committed by Jacob Heider
parent 544161f6b8
commit 4ebca976c7
2 changed files with 8 additions and 4 deletions

View file

@ -22,6 +22,8 @@ provides:
test: test:
script: script:
- run: mkdir -p .ruff_cache/{{version}}
if: '>=0.1.12'
- ruff -e $FIXTURE | grep "\`os\` imported but unused" - ruff -e $FIXTURE | grep "\`os\` imported but unused"
- ruff --fix $FIXTURE - ruff --fix $FIXTURE
- test ! -s $FIXTURE - test ! -s $FIXTURE

View file

@ -25,9 +25,11 @@ renamed-to: astral.sh/ruff
# - bin/ruff # - bin/ruff
test: test:
script: | script:
ruff -e $FIXTURE | grep "\`os\` imported but unused" - run: mkdir -p .ruff_cache/{{version}}
ruff --fix $FIXTURE if: '>=0.1.12'
test ! -s $FIXTURE - ruff -e $FIXTURE | grep "\`os\` imported but unused"
- ruff --fix $FIXTURE
- test ! -s $FIXTURE
fixture: | fixture: |
import os import os