ensured building on latest archlinux system
This commit is contained in:
@@ -4,18 +4,18 @@
|
||||
#include <string>
|
||||
#include "../utils/utils.h"
|
||||
|
||||
#if __GNUC__ < 8
|
||||
#if __GNUC__ < 8 && __clang_major__ < 17
|
||||
# include <experimental/filesystem>
|
||||
using namespace std::experimental;
|
||||
#else
|
||||
# include <filesystem>
|
||||
using std::filesystem;
|
||||
using namespace std::filesystem;
|
||||
#endif
|
||||
|
||||
Settings::Settings(std::string path) {
|
||||
this->settings_file_path = path;
|
||||
|
||||
if (!filesystem::exists(path)) {
|
||||
if (!exists(path)) {
|
||||
std::ofstream output(path);
|
||||
|
||||
nlohmann::json settings = R"({
|
||||
@@ -60,8 +60,8 @@ Settings::Settings(std::string path) {
|
||||
this->settings = settings;
|
||||
}
|
||||
|
||||
filesystem::create_directories(get_path_relative_to_home(this->settings["ofds_modules_dir"]));
|
||||
filesystem::create_directories(get_path_relative_to_home(this->settings["stores_modules_dir"]));
|
||||
create_directories(get_path_relative_to_home(this->settings["ofds_modules_dir"]));
|
||||
create_directories(get_path_relative_to_home(this->settings["stores_modules_dir"]));
|
||||
}
|
||||
|
||||
void Settings::write_setting(std::string setting, std::string value) {
|
||||
|
||||
Reference in New Issue
Block a user