mirror of
https://github.com/ElectronNET/Electron.NET.git
synced 2026-09-22 15:04:47 +00:00
Check if version exists
This commit is contained in:
@@ -9,6 +9,16 @@ if (!Version.TryParse(version, out _))
|
||||
return 0xDEAD;
|
||||
}
|
||||
|
||||
using var client = new HttpClient();
|
||||
|
||||
var response = await client.GetAsync($"https://github.com/electron/electron/releases/tag/v{version}");
|
||||
if (!response.IsSuccessStatusCode)
|
||||
{
|
||||
Console.WriteLine($"Version not found on GitHub : {version}");
|
||||
return 0xDEAD;
|
||||
}
|
||||
|
||||
|
||||
var yamlFile = Path.GetFullPath("../.devops/build-nuget.yaml");
|
||||
var csFile = Path.GetFullPath("../ElectronNET.CLI/Commands/BuildCommand.cs");
|
||||
var packageFile = Path.GetFullPath("../ElectronNET.Host/package.json");
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
Reference in New Issue
Block a user