Skip to content

Commit

Permalink
Merge pull request #3383 from SierraKomodo/fix/scoop-source-urls
Browse files Browse the repository at this point in the history
Strip `.git` extension from scoop source URLs
  • Loading branch information
marticliment authored Mar 1, 2025
2 parents 8491112 + ec03c3f commit 2cd76b8
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@ protected override IReadOnlyList<IManagerSource> GetSources_UnSafe()
elements[1] = Path.Join(Environment.GetFolderPath(Environment.SpecialFolder.UserProfile),
"scoop", "buckets", elements[0].Trim());
}
else
{
elements[1] = Regex.Replace(elements[1], @"^(.*)\.git$", "$1");
}

sources.Add(new ManagerSource(Manager, elements[0].Trim(), new Uri(elements[1]), int.Parse(elements[4].Trim()), elements[2].Trim() + " " + elements[3].Trim()));
}
Expand Down

0 comments on commit 2cd76b8

Please sign in to comment.