Skip to content

Commit

Permalink
Merge pull request #1899 from GitTools/pr/release-branch-should-not-p…
Browse files Browse the repository at this point in the history
…atch

Change default increment strategy for release branches to None instead of Patch
  • Loading branch information
GeertvanHorrik committed Nov 7, 2019
2 parents ef652c1 + 3b10296 commit cbed74a
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
Expand Up @@ -41,7 +41,7 @@ branches:
release:
mode: ContinuousDelivery
tag: beta
increment: Patch
increment: None
prevent-increment-of-merged-branch-version: true
track-merge-target: false
regex: ^releases?[/-]
Expand Down
2 changes: 1 addition & 1 deletion src/GitVersionCore/Configuration/ConfigExtensions.cs
Expand Up @@ -50,7 +50,7 @@ public static void Reset(this Config config)
{ "develop", "master", "support", "release" },
defaultTag: "beta",
defaultPreventIncrement: true,
defaultIncrementStrategy: IncrementStrategy.Patch,
defaultIncrementStrategy: IncrementStrategy.None,
isReleaseBranch: true);
ApplyBranchDefaults(config, GetOrCreateBranchDefaults(config, Config.FeatureBranchKey), Config.FeatureBranchRegex,
new List<string>
Expand Down
Expand Up @@ -135,6 +135,11 @@ private class Versions
{
public SemanticVersion IncrementedVersion { get; set; }
public BaseVersion Version { get; set; }

public override string ToString()
{
return $"{Version} | {IncrementedVersion}";
}
}
}
}
Expand Up @@ -69,6 +69,11 @@ public VersionTaggedCommit(Commit commit, SemanticVersion semVer, string tag)
Commit = commit;
SemVer = semVer;
}

public override string ToString()
{
return $"{Tag} | {Commit} | {SemVer}";
}
}
}
}

0 comments on commit cbed74a

Please sign in to comment.