chore: set default value to wm
on define
This commit is contained in:
parent
14b782eac4
commit
7ef06848cd
2 changed files with 2 additions and 4 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
@ -64,7 +64,7 @@ checksum = "7ff69b9dd49fd426c69a0db9fc04dd934cdb6645ff000864d98f7e2af8830eaa"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "bunbun"
|
name = "bunbun"
|
||||||
version = "1.0.0"
|
version = "1.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"clap",
|
"clap",
|
||||||
"colored",
|
"colored",
|
||||||
|
|
|
@ -41,14 +41,12 @@ fn main() {
|
||||||
|
|
||||||
let kernel = System::kernel_version().unwrap_or(String::from("N/A"));
|
let kernel = System::kernel_version().unwrap_or(String::from("N/A"));
|
||||||
let pretty = distro();
|
let pretty = distro();
|
||||||
let wm: &str;
|
let mut wm: &str = "N/A";
|
||||||
|
|
||||||
if cfg!(windows) {
|
if cfg!(windows) {
|
||||||
wm = "Aero";
|
wm = "Aero";
|
||||||
} else if cfg!(unix) {
|
} else if cfg!(unix) {
|
||||||
wm = env!("XDG_CURRENT_DESKTOP");
|
wm = env!("XDG_CURRENT_DESKTOP");
|
||||||
} else {
|
|
||||||
wm = "N/A";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
println!();
|
println!();
|
||||||
|
|
Loading…
Reference in a new issue