Better defaults management, logger class implementation with logging levels, and write to file configuration implementation

This commit is contained in:
Chris Punches
2025-03-03 03:56:51 -05:00
parent e79fa3b89f
commit ee1df1fb0c
14 changed files with 389 additions and 67 deletions

View File

@@ -39,14 +39,6 @@
#define MODULE_VERSION "0.1.0"
#define DPM_VERSION "0.1.0"
// Command enum for switch case
enum Command {
CMD_UNKNOWN,
CMD_HELP,
CMD_VERSION,
CMD_SYSTEM,
CMD_CONFIG
};
// Declaration of the DPM config function we want to call
extern "C" const char* dpm_get_config(const char* section, const char* key);
@@ -64,6 +56,15 @@ extern "C" const char* dpm_get_description(void) {
return "DPM Info Module - Provides information about the DPM system";
}
// Command enum for switch case
enum Command {
CMD_UNKNOWN,
CMD_HELP,
CMD_VERSION,
CMD_SYSTEM,
CMD_CONFIG
};
// Function to detect architecture using uname
std::string detect_architecture() {
struct utsname system_info;