Git: Block [*_]HEAD for branch name

Can have false positives, but I think it's better than tracking all of
git's internal names.

See https://stackoverflow.com/a/17596689/764870

Change-Id: Ifa3d942c4f791e5f8542e0cc174b934f2a95cbcd
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
This commit is contained in:
Orgad Shaneh
2018-11-11 20:25:11 +02:00
committed by Orgad Shaneh
parent 92431932e3
commit 644110f6e0

View File

@@ -193,6 +193,7 @@ QString GitPlugin::invalidBranchAndRemoteNamePattern()
"|^[/-]" // no leading slash or dash "|^[/-]" // no leading slash or dash
"|\"" // no quotes "|\"" // no quotes
"|\\*" // no asterisk "|\\*" // no asterisk
"|(^|[A-Z]+_)HEAD" // no HEAD, FETCH_HEAD etc.
); );
} }