diff --git a/Chocolatey.Cake.Recipe/Content/parameters.cake b/Chocolatey.Cake.Recipe/Content/parameters.cake index 3a77a68..98c4bdc 100644 --- a/Chocolatey.Cake.Recipe/Content/parameters.cake +++ b/Chocolatey.Cake.Recipe/Content/parameters.cake @@ -19,7 +19,8 @@ public enum BranchType HotFix, Release, Develop, - Master + Master, + Support } public static class BuildParameters @@ -870,6 +871,10 @@ public static class BuildParameters { BranchType = BranchType.HotFix; } + else if (branchName != null && branchName.StartsWith("support", StringComparison.OrdinalIgnoreCase)) + { + BranchType = BranchType.Support; + } else { BranchType = BranchType.Unknown; diff --git a/Chocolatey.Cake.Recipe/Content/sign.cake b/Chocolatey.Cake.Recipe/Content/sign.cake index ab7914d..c89fea8 100644 --- a/Chocolatey.Cake.Recipe/Content/sign.cake +++ b/Chocolatey.Cake.Recipe/Content/sign.cake @@ -16,7 +16,7 @@ BuildParameters.Tasks.VerifyPowerShellScriptsTask = Task("Verify-PowerShellScripts") .WithCriteria(() => BuildParameters.BuildAgentOperatingSystem == PlatformFamily.Windows, "Skipping due to not running on Windows") .WithCriteria(() => !BuildParameters.IsPullRequest, "Skipping because current build is from a Pull Request") - .WithCriteria(() => BuildParameters.BranchType == BranchType.Master || BuildParameters.BranchType == BranchType.Release || BuildParameters.BranchType == BranchType.HotFix, "Skipping because this is not a releasable branch") + .WithCriteria(() => BuildParameters.BranchType == BranchType.Master || BuildParameters.BranchType == BranchType.Release || BuildParameters.BranchType == BranchType.HotFix || BuildParameters.BranchType == BranchType.Support || BuildParameters.BranchType == BranchType.Develop, "Skipping because this is not a 'main' branch, i.e. master, develop, release, hotfix, or support, where scripts need to be verified.") .WithCriteria(() => BuildParameters.ShouldVerifyPowerShellScripts, "Skipping since verifying PowerShell scripts has been disabled") .Does(() => {