apt: Recognise mist (#351)

This commit is contained in:
Thomas Schönauer
2023-02-18 21:22:02 +00:00
committed by GitHub
parent e3b71b647f
commit 2369e371be

View File

@@ -361,6 +361,13 @@ fn upgrade_gentoo(ctx: &ExecutionContext) -> Result<()> {
fn upgrade_debian(ctx: &ExecutionContext) -> Result<()> {
if let Some(sudo) = &ctx.sudo() {
let apt = which("apt-fast")
.or_else(|| {
if which("mist").is_some() {
Some(PathBuf::from("mist"))
} else {
None
}
})
.or_else(|| {
if Path::new("/usr/bin/nala").exists() {
Some(Path::new("/usr/bin/nala").to_path_buf())