Fix: bandit pre-commit hook exclude regex 56/96556/1
authorGuillaume Lambert <guillaume.lambert@orange.com>
Thu, 17 Jun 2021 08:20:59 +0000 (10:20 +0200)
committerGuillaume Lambert <guillaume.lambert@orange.com>
Thu, 17 Jun 2021 08:20:59 +0000 (10:20 +0200)
commitf4da21e2043c1baec052be6f44206bd3c31eb96f
treea6a781d66d25174e3037b2356f5c31a2ed79dc8f
parentf2b04bffa93e65ac126346f83f8c206666da45b4
Fix: bandit pre-commit hook exclude regex

The 'exclude' field in pre-commit hook is a regex, not a glob,
as it is advertised by pre-commit runtime warnings.
"tests/*" matches "tests", "tests/" or "tests//...///" but also any file
or folder, not necessarily at the root of the project, that contains
"tests" in its name.
The right regex to ignore the tests folder at project root is "^test/"

Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: I12d8c7e2205085ef1fb2fdf267d059112729d705
.pre-commit-config.yaml