1
0
Fork 0
mirror of https://github.com/Jackett/Jackett synced 2025-01-01 04:38:20 +00:00

No need to install Tar now (#6919)

Latest version of msys2 includes tar, so no need to manually install it
This commit is contained in:
junglebus 2020-01-12 05:05:13 +11:00 committed by garfield69
parent dc87b36ae0
commit 748e1c4f2e

View file

@ -147,7 +147,7 @@ Task("Package-Mono-Full-Framework")
DeleteFile(buildOutputPath + "/System.Runtime.InteropServices.RuntimeInformation.dll");
InstallMsysTar();
CheckForGzipAndTar();
Gzip("./BuildOutput/net461/linux-x64", $"./{artifactsDirName}", "Jackett", "Jackett.Binaries.Mono.tar.gz");
});
@ -437,20 +437,8 @@ private void Gzip(string sourceFolder, string outputDirectory, string tarCdirect
}
}
private void InstallMsysTar()
private void CheckForGzipAndTar()
{
//Gzip is included by default with MSYS2, but not tar. Use the package manager to install tar
var startInfo = new System.Diagnostics.ProcessStartInfo()
{
Arguments = "-S --noconfirm tar",
FileName = @"C:\msys64\usr\bin\pacman.exe",
UseShellExecute = false
};
var process = System.Diagnostics.Process.Start(startInfo);
process.WaitForExit();
if (FileExists(@"C:\msys64\usr\bin\tar.exe") && FileExists(@"C:\msys64\usr\bin\gzip.exe"))
{
Information("tar.exe and gzip.exe were found");