summaryrefslogtreecommitdiff
path: root/src/debug/Log.cpp
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2022-06-03 17:48:07 +0200
committervaxerski <43317083+vaxerski@users.noreply.github.com>2022-06-03 17:48:07 +0200
commit9486a230c74e8873621fdf64a33adaaa660762e3 (patch)
tree0f0ee90736428b6b1bed1198e3e3db9be07c0dc3 /src/debug/Log.cpp
parent6f3b004199a6b1bb0a8f5431d677ab926bdf19f3 (diff)
Log to the instance folder
Diffstat (limited to 'src/debug/Log.cpp')
-rw-r--r--src/debug/Log.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/debug/Log.cpp b/src/debug/Log.cpp
index b3d13583..559e7b79 100644
--- a/src/debug/Log.cpp
+++ b/src/debug/Log.cpp
@@ -1,14 +1,15 @@
#include "Log.hpp"
#include "../defines.hpp"
+#include "../Compositor.hpp"
#include <fstream>
#include <iostream>
-void Debug::init() {
+void Debug::init(std::string IS) {
if (ISDEBUG)
- logFile = "/tmp/hypr/hyprlandd-" + std::to_string(time(NULL)) + ".log";
+ logFile = "/tmp/hypr/" + IS + "/hyprlandd.log";
else
- logFile = "/tmp/hypr/hyprland-" + std::to_string(time(NULL)) + ".log";
+ logFile = "/tmp/hypr/" + IS + "/hyprland.log";
}
void Debug::log(LogLevel level, const char* fmt, ...) {