mirror of https://github.com/SeanOMik/swm.git
20 lines
397 B
C++
20 lines
397 B
C++
#pragma once
|
|
|
|
#include <toml.hpp>
|
|
#include <toml/parser.hpp>
|
|
#include <toml/value.hpp>
|
|
|
|
#include "programs_config.h"
|
|
|
|
class Config {
|
|
public:
|
|
ProgramsConfig programs;
|
|
std::string path;
|
|
|
|
Config(const std::string& config_path) {
|
|
this->path = config_path;
|
|
|
|
toml::value toml = toml::parse(path + "config.toml");
|
|
programs = ProgramsConfig(toml["Programs"]);
|
|
}
|
|
}; |