From ada3342f921318de4caf3c9f4d00befa7f280be3 Mon Sep 17 00:00:00 2001 From: Botspot <54716352+Botspot@users.noreply.github.com> Date: Thu, 19 Dec 2024 13:59:30 -0600 Subject: [PATCH] show apt-cache output if packageversion empty during specified repo --- api | 3 +++ 1 file changed, 3 insertions(+) diff --git a/api b/api index 9b6663b002..da0a306428 100755 --- a/api +++ b/api @@ -600,6 +600,9 @@ install_packages() { #Make some packages dependencies of the $app app. Package-n #request package version if backports repo was specified elif [ ! -z "$repo_selection" ];then local packageversion="$(package_latest_version "$package" -t "$repo_selection" | sed 's/+.*//g')" + if [ -z "$packageversion" ];then + error "install_packages(): failed to get package version for $package, apt-cache output was $(apt-cache policy -t "$repo_selection" "$package" 2>&1)" + fi #add version specification to package packages="$(echo "$packages" | sed "s|^${package}$|$package (>= $packageversion)|")" fi