New Desktop Command [upd] -

#[derive(Debug)] struct SystemInfo os: String, host: String, kernel: String, uptime: String, shell: String, cpu: String, gpu: String, memory: String, disk: String, resolution: String, desktop: String,

}

I've developed a complete, ready-to-run piece of software: – a modern, cross-platform desktop system information tool written in Rust. It fetches and displays key hardware/OS details in a clean, customizable layout, similar to neofetch but with a fresh command set and lower resource usage. new desktop command

fn get_macos_gpu() -> String let output = Command::new("system_profiler") .args(&["SPDisplaysDataType", " #[derive(Debug)] struct SystemInfo os: String

// Desktop environment / WM let desktop = env::var("XDG_CURRENT_DESKTOP") .or_else(|_| env::var("DESKTOP_SESSION")) .unwrap_or_else(|_| "Unknown".to_string()); } I've developed a complete

fn get_resolution() -> String { if cfg!(target_os = "windows") { let output = Command::new("wmic") .args(&["path", "Win32_VideoController", "get", "CurrentHorizontalResolution,CurrentVerticalResolution"]) .output(); if let Ok(out) = output { let stdout = String::from_utf8_lossy(&out.stdout); let lines: Vec<&str> = stdout.lines().collect(); if lines.len() > 1 { let parts: Vec<&str> = lines[1].split_whitespace().collect(); if parts.len() >= 2 { return format!("{}x{}", parts[0], parts[1]); } } } } else if cfg!(target_os = "linux") let output = Command::new("xrandr").arg("--current").output(); if let Ok(out) = output let stdout = String::from_utf8_lossy(&out.stdout); for line in stdout.lines() if line.contains(" connected") && line.contains('x') &w

Derulează în sus