diff options
author | eldritch horrors <pennae@lix.systems> | 2024-03-04 07:27:52 +0100 |
---|---|---|
committer | eldritch horrors <pennae@lix.systems> | 2024-03-04 07:27:52 +0100 |
commit | 076844e3868f108ce0d1523e2db069f7e71c9990 (patch) | |
tree | 28b3f9bb918b184e78331c75b0fe296a730e4725 | |
parent | 67de43b1d78e1b2a8c7e1f7c3adea05fd148d9e7 (diff) |
Merge pull request #9621 from blaggacao/fix/too-restrictive-branch-regex-master
fix: valid branch name
(cherry picked from commit d2016c6b59f4a5223a18c92c817d61c448ce39ab)
Change-Id: Ic346739b91bf1b10515c9ff3b3e180a64afe6343
-rw-r--r-- | src/libutil/url-parts.hh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libutil/url-parts.hh b/src/libutil/url-parts.hh index 12026921f..6255c1d02 100644 --- a/src/libutil/url-parts.hh +++ b/src/libutil/url-parts.hh @@ -25,7 +25,8 @@ const static std::string pathRegex = "(?:" + segmentRegex + "(?:/" + segmentRege /// A Git ref (i.e. branch or tag name). /// \todo check that this is correct. -const static std::string refRegexS = "[a-zA-Z0-9@][a-zA-Z0-9_.\\/@-]*"; +/// This regex incomplete. See https://git-scm.com/docs/git-check-ref-format +const static std::string refRegexS = "[a-zA-Z0-9@][a-zA-Z0-9_.\\/@+-]*"; extern std::regex refRegex; /// Instead of defining what a good Git Ref is, we define what a bad Git Ref is |