Skip to content

Commit

Permalink
feat: log to system temp dir
Browse files Browse the repository at this point in the history
  • Loading branch information
Mairon1206 committed Jul 30, 2024
1 parent 866328c commit f04891e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@
#include <Infrastructure/Utils/Logger.h>
#include <Version.h>
#include <app.h>
#include <filesystem>
#include <spdlog/spdlog.h>

int main(int argc, char** argv) {
Logger logger(Logger::Level::debug, "logs/evento.log");
Logger logger(Logger::Level::debug,
std::filesystem::temp_directory_path() / "NJUPT-SAST" / "logs" / "evento.log");
spdlog::info("SAST Evento version: v" VERSION_FULL);
auto ui = App::create();
ui->set_version_string("v" VERSION_FULL);
Expand Down

0 comments on commit f04891e

Please sign in to comment.