Broadcast in headless mode.
This commit is contained in:
parent
8709357851
commit
36644423f5
1 changed files with 11 additions and 11 deletions
|
@ -213,20 +213,20 @@ namespace BackupManager
|
||||||
|
|
||||||
public static void Log(object line, bool forceSatori = false)
|
public static void Log(object line, bool forceSatori = false)
|
||||||
{
|
{
|
||||||
if (Headless)
|
if (!Headless)
|
||||||
return;
|
|
||||||
|
|
||||||
if (sw?.IsRunning == true)
|
|
||||||
{
|
{
|
||||||
ConsoleColor fg = Console.ForegroundColor;
|
if (sw?.IsRunning == true)
|
||||||
Console.ForegroundColor = ConsoleColor.Yellow;
|
{
|
||||||
Console.Write(sw.ElapsedMilliseconds.ToString().PadRight(10));
|
ConsoleColor fg = Console.ForegroundColor;
|
||||||
Console.ForegroundColor = fg;
|
Console.ForegroundColor = ConsoleColor.Yellow;
|
||||||
|
Console.Write(sw.ElapsedMilliseconds.ToString().PadRight(10));
|
||||||
|
Console.ForegroundColor = fg;
|
||||||
|
}
|
||||||
|
|
||||||
|
Console.WriteLine(line);
|
||||||
}
|
}
|
||||||
|
|
||||||
Console.WriteLine(line);
|
if (forceSatori || (!Headless && !(Config?.SatoriErrorsOnly ?? true)))
|
||||||
|
|
||||||
if (forceSatori || !(Config?.SatoriErrorsOnly ?? true))
|
|
||||||
SatoriBroadcast(line.ToString());
|
SatoriBroadcast(line.ToString());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Reference in a new issue