From 0a0f5b8e8c6d87879b923cc14ab110be9547b4ef Mon Sep 17 00:00:00 2001 From: Ryzerth Date: Tue, 22 Dec 2020 23:04:46 +0100 Subject: [PATCH] fixed directory bug on linux --- core/src/options.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/core/src/options.cpp b/core/src/options.cpp index 2841a506..803203fa 100644 --- a/core/src/options.cpp +++ b/core/src/options.cpp @@ -1,5 +1,6 @@ #include #include +#include namespace options { CMDLineOptions opts; @@ -8,7 +9,8 @@ namespace options { #ifdef _WIN32 opts.root = "."; #else - opts.root = "~/.config/sdrpp"; + std::string homedir = getenv("HOME"); + opts.root = homedir + "/.config/sdrpp"; #endif }