Skip to content

Commit

Permalink
Fix build breaking on non PR branch (#2090)
Browse files Browse the repository at this point in the history
  • Loading branch information
IT-VBFK committed Jan 9, 2023
1 parent d9ae2ec commit fc0ffde
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Build/Build.cs
Expand Up @@ -299,7 +299,8 @@ class Build : NukeBuild
Repository Repository => new Repository(GitRepository.LocalDirectory);
Tree TargetBranch => Repository.Branches[PullRequestBase].Tip.Tree;
Tree SourceBranch => Repository.Branches[Repository.Head.FriendlyName].Tip.Tree;
bool RunAllTargets => PullRequestBase == default;

bool RunAllTargets => string.IsNullOrWhiteSpace(PullRequestBase);

bool IsTag => BranchSpec != null && BranchSpec.Contains("refs/tags", StringComparison.InvariantCultureIgnoreCase);
}

0 comments on commit fc0ffde

Please sign in to comment.