diff --git a/src/backend/actual/debian.rs b/src/backend/actual/debian.rs index ac56106..0a6ae04 100644 --- a/src/backend/actual/debian.rs +++ b/src/backend/actual/debian.rs @@ -27,14 +27,14 @@ impl Backend for Debian { switches_info: &["show"], switches_install: &["install"], switches_noconfirm: &["--yes"], - switches_remove: &["remove"], + switches_remove: &["remove", "--auto-remove"], switches_make_dependency: Some(&[]), } } fn get_all_installed_packages(&self) -> Result { - let mut cmd = Command::new("apt"); - cmd.args(&["list", "--installed"]); + let mut cmd = Command::new("dpkg-query"); + cmd.args(&["--showformat=${Package}\n", "--show"]); let output = String::from_utf8(cmd.output()?.stdout)?;