From 2e7437341ab19d7740e3ae4cfe5100780fd2ba1c Mon Sep 17 00:00:00 2001 From: ripytide Date: Wed, 18 Dec 2024 10:42:56 +0000 Subject: [PATCH] add another possibility to the missing package warning --- src/backends/arch.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/backends/arch.rs b/src/backends/arch.rs index 0b9fe03..b0af26e 100644 --- a/src/backends/arch.rs +++ b/src/backends/arch.rs @@ -124,6 +124,8 @@ impl Backend for Arch { it may be due to one of the following issues: - the package name has a typo as written in your group files + - the package is in a repository that you don't have enabled in + /etc/pacman.conf (such as multilib) - the package is a virtual package (https://wiki.archlinux.org/title/Pacman#Virtual_packages) and so is ambiguous. You can run `pacman -Ss {package:?}` to list non-virtual packages which which provide the virtual package @@ -254,4 +256,14 @@ impl Backend for Arch { false, ) } + + fn missing( + managed: Self::InstallOptions, + installed: Option, + ) -> Option { + match installed { + Some(_) => None, + None => Some(managed), + } + } }