]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
get_maintainer: add ** glob pattern support
authorMatteo Croce <technoboy85@gmail.com>
Mon, 2 Mar 2026 10:38:22 +0000 (11:38 +0100)
committerAndrew Morton <akpm@linux-foundation.org>
Sat, 28 Mar 2026 04:19:38 +0000 (21:19 -0700)
commit420849332f9f9f1ce6ff142868ae2e6ae9f98f65
tree04b4bf4b762e3f59dde9128ca533b7939047cb83
parentdefec2ca7cd743c9b8a29be5012ad7381a5ecbb3
get_maintainer: add ** glob pattern support

Add support for the ** glob operator in MAINTAINERS F: and X: patterns,
matching any number of path components (like Python's ** glob).

The existing * to .* conversion with slash-count check is preserved.  **
is converted to (?:.*), a non-capturing group used as a marker to bypass
the slash-count check in file_match_pattern(), allowing the pattern to
cross directory boundaries.

This enables patterns like F: **/*[_-]kunit*.c to match files at any depth
in the tree.

Link: https://lkml.kernel.org/r/20260302103822.77343-1-teknoraver@meta.com
Signed-off-by: Matteo Croce <teknoraver@meta.com>
Acked-by: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
MAINTAINERS
scripts/get_maintainer.pl