mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
[ALL] If output is redirected, don't clear the screen first
This commit is contained in:
@@ -66,8 +66,12 @@ namespace SabreTools
|
||||
/// </summary>
|
||||
/// <param name="args">String array representing command line parameters</param>
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
// If output is being redirected, don't allow clear screens
|
||||
if (!Console.IsOutputRedirected)
|
||||
{
|
||||
Console.Clear();
|
||||
}
|
||||
|
||||
// Credits take precidence over all
|
||||
if ((new List<string>(args)).Contains("--credits"))
|
||||
|
||||
@@ -43,7 +43,12 @@ namespace SabreTools
|
||||
// Perform initial setup and verification
|
||||
_logger = new Logger(true, "database.log");
|
||||
_logger.Start();
|
||||
|
||||
// If output is being redirected, don't allow clear screens
|
||||
if (!Console.IsOutputRedirected)
|
||||
{
|
||||
Console.Clear();
|
||||
}
|
||||
Setup();
|
||||
|
||||
// Credits take precidence over all
|
||||
@@ -536,6 +541,9 @@ namespace SabreTools
|
||||
InitStats(inputs, single);
|
||||
}
|
||||
|
||||
// If nothing is set, show the help
|
||||
Build.Help();
|
||||
|
||||
_logger.Close();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -25,8 +25,13 @@ namespace SabreTools
|
||||
/// <param name="args">String array representing command line parameters</param>
|
||||
static void Main(string[] args)
|
||||
{
|
||||
// Perform initial setup and verification
|
||||
// If output is being redirected, don't allow clear screens
|
||||
if (!Console.IsOutputRedirected)
|
||||
{
|
||||
Console.Clear();
|
||||
}
|
||||
|
||||
// Perform initial setup and verification
|
||||
logger = new Logger(true, "headerer.log");
|
||||
logger.Start();
|
||||
DBTools.EnsureDatabase(_dbName, _connectionString);
|
||||
|
||||
@@ -2,8 +2,6 @@
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
using SabreTools.Helper;
|
||||
|
||||
@@ -65,8 +63,12 @@ namespace SabreTools
|
||||
/// </summary>
|
||||
/// <param name="args">String array representing command line parameters</param>
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
// If output is being redirected, don't allow clear screens
|
||||
if (!Console.IsOutputRedirected)
|
||||
{
|
||||
Console.Clear();
|
||||
}
|
||||
|
||||
// Credits take precidence over all
|
||||
if ((new List<string>(args)).Contains("--credits"))
|
||||
|
||||
@@ -2,8 +2,6 @@
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
using SabreTools.Helper;
|
||||
|
||||
@@ -40,7 +38,12 @@ namespace SabreTools
|
||||
// Perform initial setup and verification
|
||||
Logger logger = new Logger(true, "offlinemerge.log");
|
||||
logger.Start();
|
||||
|
||||
// If output is being redirected, don't allow clear screens
|
||||
if (!Console.IsOutputRedirected)
|
||||
{
|
||||
Console.Clear();
|
||||
}
|
||||
|
||||
// Credits take precidence over all
|
||||
if ((new List<string>(args)).Contains("--credits"))
|
||||
|
||||
Reference in New Issue
Block a user