daemon: fix keyboard brightness setting

Closes #241
This commit is contained in:
Luke D. Jones
2022-08-20 21:42:18 +12:00
parent f8cdde2adf
commit 3fe5896596
5 changed files with 176 additions and 93 deletions

View File

@@ -7,15 +7,18 @@ use std::path::PathBuf;
pub static CONFIG_PATH: &str = "/etc/asusd/asusd.conf";
#[derive(Deserialize, Serialize, Default)]
#[serde(default)]
pub struct Config {
/// Save charge limit for restoring on boot
pub bat_charge_limit: u8,
pub panel_od: bool,
}
impl Config {
fn new() -> Self {
Config {
bat_charge_limit: 100,
panel_od: false,
}
}