From 794abeb3512aab01c79cd6ba05768e1a3ae5f2f2 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Sun, 8 Sep 2024 19:36:55 +0200 Subject: [PATCH] pkg/query --- spcd/bootstrap.sh | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/spcd/bootstrap.sh b/spcd/bootstrap.sh index 09fe8f7..f4c2c03 100644 --- a/spcd/bootstrap.sh +++ b/spcd/bootstrap.sh @@ -993,17 +993,6 @@ ${name}.${_SPCD_TXT_CHARSET} ${_SPCD_TXT_CHARSET} # │ f │ pm = package manager │ # ╰───┴──────────────────────╯ -spcd_f_pm_query() { - case "${SPCD_PM}" in - "${SPCD_PM_APK}") apk info "${1}" ;; - "${SPCD_PM_APT}") dpkg-query --show "${1}" ;; - "${SPCD_PM_DNF}") rpm --query "${1}" ;; - "${SPCD_PM_PACMAN}") pacman --query "${1}" ;; - "${SPCD_PM_ZYPPER}") rpm --query "${1}" ;; - *) ;; - esac -} - # ╭───┬────┬───────╮ # │ f │ pm │ https │ # ╰───┴────┴───────╯ @@ -1084,6 +1073,17 @@ spcd_f_pm_pkg_install() { spcd_f_pm_pkg_clean } +spcd_f_pm_pkg_query() { + case "${SPCD_PM}" in + "${SPCD_PM_APK}") apk info "${1}" ;; + "${SPCD_PM_APT}") dpkg-query --show "${1}" ;; + "${SPCD_PM_DNF}") rpm --query "${1}" ;; + "${SPCD_PM_PACMAN}") pacman --query "${1}" ;; + "${SPCD_PM_ZYPPER}") rpm --query "${1}" ;; + *) ;; + esac +} + spcd_f_pm_pkg_update() { spcd_step "Update" case "${SPCD_PM}" in