Added "-Silent" argument

This commit is contained in:
Jaex 2022-11-08 07:52:26 +03:00
parent 1313da6195
commit cf1578b82f
2 changed files with 7 additions and 7 deletions

View file

@ -54,8 +54,8 @@ private enum SetupJobs
MicrosoftStoreDebug = CreateMicrosoftStoreDebugFolder | CompileAppx | DownloadFFmpeg | CreateChecksumFile | OpenOutputDirectory
}
private static SetupJobs Job = SetupJobs.Release;
private static bool AppVeyor = false;
private static SetupJobs Job { get; set; } = SetupJobs.Release;
private static bool Silent { get; set; } = false;
private static string ParentDir;
private static string Configuration;
@ -147,7 +147,7 @@ private static void Main(string[] args)
CompileAppx();
}
if (Job.HasFlag(SetupJobs.OpenOutputDirectory) && !AppVeyor)
if (!Silent && Job.HasFlag(SetupJobs.OpenOutputDirectory))
{
FileHelpers.OpenFolder(OutputDir, false);
}
@ -160,11 +160,11 @@ private static void CheckArgs(string[] args)
CLIManager cli = new CLIManager(args);
cli.ParseCommands();
AppVeyor = cli.IsCommandExist("AppVeyor");
Silent = cli.IsCommandExist("Silent");
if (AppVeyor)
if (Silent)
{
Console.WriteLine("AppVeyor: " + AppVeyor);
Console.WriteLine("Silent: " + Silent);
}
CLICommand command = cli.GetCommand("Job");

View file

@ -38,7 +38,7 @@ after_build:
- ps: |
if ($env:APPVEYOR_PULL_REQUEST_NUMBER -eq $null)
{
& "ShareX.Setup\bin\$env:CONFIGURATION\ShareX.Setup.exe" -AppVeyor -Job "$env:CONFIGURATION"
& "ShareX.Setup\bin\$env:CONFIGURATION\ShareX.Setup.exe" -Silent -Job "$env:CONFIGURATION"
}
artifacts:
- path: Output\ShareX-*-setup.exe