Skip to content

Commit

Permalink
fix: support kde6 (#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
Pylogmon authored Apr 17, 2024
1 parent df2fdfe commit c025fa2
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/linux.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,11 +230,19 @@ fn gsettings() -> Command {
}

fn kreadconfig() -> Command {
Command::new("kreadconfig5")
let command = match env::var("KDE_SESSION_VERSION").unwrap_or_default().as_str() {
"6" => "kreadconfig6",
_ => "kreadconfig5"
}
Command::new(command)
}

fn kwriteconfig() -> Command {
Command::new("kwriteconfig5")
let command = match env::var("KDE_SESSION_VERSION").unwrap_or_default().as_str() {
"6" => "kwriteconfig6",
_ => "kwriteconfig5"
}
Command::new(command)
}

fn set_proxy(proxy: &Sysproxy, service: &str) -> Result<()> {
Expand Down

0 comments on commit c025fa2

Please sign in to comment.