Skip to content

Commit dd528b0

Browse files
changed the regex to allow +:refs/heads/*
1 parent 4a432bf commit dd528b0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

GitVersionCore/BuildServers/GitHelper.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ namespace GitVersion
77

88
public static class GitHelper
99
{
10-
const string MergeMessageRegexPattern = "refs/heads/(pr|pull(-requests)?/(?<issuenumber>[0-9]*)/merge)";
10+
const string MergeMessageRegexPattern = "refs/heads/(pr|pull(-requests)?/(?<issuenumber>[0-9]*)/(merge|head))";
1111

1212
public static void NormalizeGitDirectory(string gitDirectory, Authentication authentication)
1313
{
@@ -76,6 +76,7 @@ public static string ExtractIssueNumber(string mergeMessage)
7676
// Dynamic: refs/heads/pr/5
7777
// Github Message: refs/heads/pull/5/merge
7878
// Stash Message: refs/heads/pull-requests/5/merge
79+
// refs/heads/pull/5/head
7980
var regex = new Regex(MergeMessageRegexPattern);
8081
var match = regex.Match(mergeMessage);
8182

0 commit comments

Comments
 (0)