foxygit / Torlinkc Log in
commits tags

/include/torlinkc/config/paths.hpp · 861 B

raw
#pragma once

#include <string>

namespace torlinkc::paths {

// Deliberately distinct from the original Node app's "torlink" (~/.config,
// ~/.local/share): the two implementations can coexist on a dev machine
// during the rewrite, and sharing a state dir risks one corrupting the
// other's queue.json before the on-disk format is guaranteed compatible.
inline constexpr const char* kAppName = "torlinkc";

// TORLINK_STATE_DIR relocates all persisted state under one folder (tests use
// this to sandbox themselves from the real user data), mirroring the
// TypeScript original's override of the same name.
std::string defaultDownloadDir();
std::string configFile();
std::string queueFile();
std::string historyFile();
std::string seedsFile();
std::string torrentsDir();
std::string bootMarkerFile();
std::string logsDir();

}  // namespace torlinkc::paths