]> git.ipfire.org Git - thirdparty/dracut-ng.git/commitdiff
fix(Makefile): exclude hidden directories from shellcheck part 2
authorBenjamin Drung <benjamin.drung@canonical.com>
Fri, 26 Sep 2025 08:31:59 +0000 (10:31 +0200)
committerLaszlo <laszlo.gombos@gmail.com>
Fri, 26 Sep 2025 11:55:48 +0000 (07:55 -0400)
`find .` also searches in hidden directories (like `.git` or `.pc`). The
`.pc` is used on Debian for patch tracking and should not be searched
for files.

So ignore the top-level hidden directories from shellcheck. See also
commit 7a65d1a1f372 ("fix(Makefile): exclude hidden directories from
shellcheck").

Makefile

index 933f7d6a6a116d69ab4edc50bb41e0ae1930df5e..bcb8ef335a6e136d8684a7a56f0b98b27d212294 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -323,7 +323,7 @@ ifeq ($(HAVE_SHELLCHECK),yes)
 ifeq ($(HAVE_SHFMT),yes)
        shellcheck $$(shfmt -f *)
 else
-       find . -name '*.sh' -print0 | xargs -0 shellcheck
+       find * -name '*.sh' -print0 | xargs -0 shellcheck
 endif
 endif