Skip to content

Commit

Permalink
do not link to GitHub diffs for new plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
goaaats committed Feb 4, 2024
1 parent 5610e84 commit 2f0a6ab
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Plogon/BuildProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,9 @@ private async Task<PluginDiff> GetPluginDiff(DirectoryInfo workDir, BuildTask ta
switch (host.Host)
{
case "github.com":
result.DiffUrl = $"{url}/compare/{haveCommit}..{wantCommit}";
// GitHub does not support diffing from 0
if (haveCommit != emptyTree)
result.DiffUrl = $"{url}/compare/{haveCommit}..{wantCommit}";
break;
case "gitlab.com":
result.DiffUrl = $"{url}/-/compare/{haveCommit}...{wantCommit}";
Expand Down

0 comments on commit 2f0a6ab

Please sign in to comment.