fix: get latest version info from sourcegit-scm.github.io instead of api.github.com (#75)

This commit is contained in:
leo 2024-04-16 09:23:54 +08:00
parent 69d9edf963
commit 37ca149970

View file

@ -165,7 +165,7 @@ namespace SourceGit
{
// Fetch lastest release information.
var client = new HttpClient() { Timeout = TimeSpan.FromSeconds(2) };
var data = await client.GetStringAsync("https://api.github.com/repos/sourcegit-scm/sourcegit/releases/latest");
var data = await client.GetStringAsync("https://sourcegit-scm.github.io/data/version.json");
// Parse json into Models.Version.
var ver = JsonSerializer.Deserialize(data, JsonCodeGen.Default.Version);