Skip to content

Commit 11aeab1

Browse files
committed
Fixed issue when branch config matches regex and fails validation
1 parent 4a1b591 commit 11aeab1

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/GitVersionCore.Tests/ConfigProviderTests.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ public void CanReadOldDocument()
3636
develop-branch-tag: alpha
3737
release-branch-tag: rc
3838
branches:
39+
master:
40+
mode: ContinuousDeployment
3941
dev(elop)?(ment)?$:
4042
mode: ContinuousDeployment
4143
tag: dev

src/GitVersionCore/Configuration/LegacyConfigNotifier.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public static void Notify(StringReader reader)
3232

3333
var issues = new List<string>();
3434

35-
var oldConfigs = legacyConfig.Branches.Keys.Where(k => OldConfigKnownRegexes.Keys.Contains(k)).ToList();
35+
var oldConfigs = legacyConfig.Branches.Keys.Where(k => OldConfigKnownRegexes.Keys.Contains(k) && k != OldConfigKnownRegexes[k]).ToList();
3636
if (oldConfigs.Any())
3737
{
3838
var max = oldConfigs.Max(c => c.Length);

0 commit comments

Comments
 (0)