[Filesystem] Path Manager Improvements (#4557)

* [Filesystem] Path Manager Improvements

* Update path_manager.cpp

* Use native fs path building syntax
This commit is contained in:
Chris Miles
2025-01-05 23:44:16 -06:00
committed by GitHub
parent 4493ebebab
commit 8a7d5e72cb
2 changed files with 59 additions and 66 deletions
+7
View File
@@ -25,6 +25,8 @@
#include "repositories/discord_webhooks_repository.h"
#include "repositories/logsys_categories_repository.h"
#include "termcolor/rang.hpp"
#include "path_manager.h"
#include "file.h"
#include <iostream>
#include <string>
@@ -532,6 +534,11 @@ void EQEmuLogSys::StartFileLogs(const std::string &log_name)
{
EQEmuLogSys::CloseFileLogs();
if (!File::Exists(path.GetLogPath())) {
LogInfo("Logs directory not found, creating [{}]", path.GetLogPath());
File::Makedir(path.GetLogPath());
}
/**
* When loading settings, we must have been given a reason in category based logging to output to a file in order to even create or open one...
*/