pkg/install

This commit is contained in:
Marc Beninca 2024-09-07 10:41:59 +02:00
parent 1a5dcbf4d1
commit 088762f1ee
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

View file

@ -837,18 +837,6 @@ spcd_https_path() {
esac esac
} }
spcd_install_package() {
case "${SPCD_PM}" in
"${SPCD_PM_APK}") spcd_eval apk add "${1}" ;;
"${SPCD_PM_APT}") spcd_eval apt-get install --assume-yes "${1}" ;;
"${SPCD_PM_DNF}") spcd_eval dnf install --assumeyes "${1}" ;;
"${SPCD_PM_PACMAN}") spcd_eval pacman --sync --noconfirm "${1}" ;;
"${SPCD_PM_ZYPPER}") spcd_eval zypper --non-interactive install "${1}" ;;
*) ;;
esac
spcd_clean_cache
}
spcd_python_ln() { spcd_python_ln() {
local command="${1}" local command="${1}"
if [ -n "${command}" ]; then if [ -n "${command}" ]; then
@ -1027,6 +1015,18 @@ ${name}.${_SPCD_TXT_CHARSET} ${_SPCD_TXT_CHARSET}
# │ e │ packages │ # │ e │ packages │
# ╰───┴──────────╯ # ╰───┴──────────╯
spcd_install_package() {
case "${SPCD_PM}" in
"${SPCD_PM_APK}") spcd_eval apk add "${1}" ;;
"${SPCD_PM_APT}") spcd_eval apt-get install --assume-yes "${1}" ;;
"${SPCD_PM_DNF}") spcd_eval dnf install --assumeyes "${1}" ;;
"${SPCD_PM_PACMAN}") spcd_eval pacman --sync --noconfirm "${1}" ;;
"${SPCD_PM_ZYPPER}") spcd_eval zypper --non-interactive install "${1}" ;;
*) ;;
esac
spcd_clean_cache
}
spcd_query_package() { spcd_query_package() {
case "${SPCD_PM}" in case "${SPCD_PM}" in
"${SPCD_PM_APK}") apk info "${1}" ;; "${SPCD_PM_APK}") apk info "${1}" ;;