From 5c47be179c29d6ce07198b5ea73c59bcb139ef4e Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 20 Feb 2024 09:33:38 +0100 Subject: [PATCH] tox: add all non shell file in tools/ to lintables Right now the tools directory is not checked by pylint because it will not auto-detect what files are python files and instead just skip the dir if it does not have a __init__.py. This commit uses `tox-backticks` to run a custom find to ensure the python files are explicitely added. I'm not sure we can use tox-backticks or we need it packages for fedora/rhel? If we cannot use it we need to look into either a custom tox plugin to support more rich globbing or just move out `tools/set-env-variables.sh` as it's the only non-python code in the repo and it will trip up pylint (syntax error). --- tox.ini | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 1067472f..731d042f 100644 --- a/tox.ini +++ b/tox.ini @@ -22,9 +22,10 @@ deps = pykickstart # required by pykickstart but not pulled in automatically :/ requests + tox-backticks setenv = - LINTABLES = osbuild/ assemblers/* devices/* inputs/* mounts/* runners/* sources/* stages/*.* stages/test/*.py test/ tools/ + LINTABLES = osbuild/ assemblers/* devices/* inputs/* mounts/* runners/* sources/* stages/*.* stages/test/*.py test/ `find ./tools ! -name "*.sh" -type f` TYPEABLES = osbuild TYPEABLES_STRICT = ./osbuild/main_cli.py