feat: Introduce initial implementation of URL notes grabber console application with database and API integration.
This commit is contained in:
1 parent
44d97e54fb
commit
81e345b36f
2 files changed
+6
No files matched your search
@@ -23,6 +23,12 @@ namespace URLNotesGrabberCORE
|
|||||||
|
|
||||||
// Setup Dual Logging
|
// Setup Dual Logging
|
||||||
string logPath = "console_output.log";
|
string logPath = "console_output.log";
|
||||||
|
if (File.Exists(logPath))
|
||||||
|
{
|
||||||
|
string timestamp = DateTime.Now.ToString("yyyyMMdd_HHmmss");
|
||||||
|
string newPath = $"console_output_{timestamp}.log";
|
||||||
|
File.Move(logPath, newPath);
|
||||||
|
}
|
||||||
StreamWriter fileWriter = new StreamWriter(logPath, append: false) { AutoFlush = true };
|
StreamWriter fileWriter = new StreamWriter(logPath, append: false) { AutoFlush = true };
|
||||||
DualLogger dualLogger = new DualLogger(Console.Out, fileWriter);
|
DualLogger dualLogger = new DualLogger(Console.Out, fileWriter);
|
||||||
Console.SetOut(dualLogger);
|
Console.SetOut(dualLogger);
|
||||||
|
|||||||
Binary file not shown.
Reference in new issue
Block a user