Improve Python config file template substitution #8
1 changed files with 3 additions and 0 deletions
py-topdir.mk: Add --config pyproject.toml
ruff tries to recursivley use every config file it finds and stumbles
over a template:
/usr/bin/ruff check --select TC,FA --fix --unsafe-fixes .
ruff failed
Cause: Failed to parse /home/jan/local/src/jw.dev/proj/jw-pkg/conf/templates/pyproject.toml
Cause: TOML parse error at line 3, column 3
|
3 | {mypypath}
| ^
invalid key-value pair, expected key
Limiting it to the toplevel pyproject.toml by explicitly specifying
--config fixes the behaviour, so that's what this commit does.
Signed-off-by: Jan Lindemann <jan@janware.com>
commit
9ba6c70dee
|
|
@ -7,6 +7,9 @@ endif
|
||||||
|
|
||||||
ifndef PY_CHECK_RUFF
|
ifndef PY_CHECK_RUFF
|
||||||
PY_CHECK_RUFF := $(shell which ruff 2>/dev/null)
|
PY_CHECK_RUFF := $(shell which ruff 2>/dev/null)
|
||||||
|
ifneq ($(PY_CHECK_RUFF),)
|
||||||
|
PY_CHECK_RUFF += --config pyproject.toml
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifndef PY_CHECK_YAPF
|
ifndef PY_CHECK_YAPF
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue