diff --git a/spcd/bootstrap.sh b/spcd/bootstrap.sh index 957f70f..020e210 100644 --- a/spcd/bootstrap.sh +++ b/spcd/bootstrap.sh @@ -670,7 +670,6 @@ ${SPCD_PROJECT_ROOT}$(basename "${GITHUB_SERVER_URL}")" SPCD_PM_INSTALL="dnf install --assumeyes" SPCD_PM_QUERY="rpm --query" SPCD_PM_UPDATE="dnf makecache" - SPCD_PM_UPGRADE="dnf upgrade --assumeyes" SPCD_PKG_PKG="" SPCD_PM_CONF_PATH="/etc/dnf/dnf.conf" SPCD_PM_CONF_TEXT="\ @@ -691,7 +690,6 @@ sslverify=False SPCD_PM_INSTALL="apk add" SPCD_PM_QUERY="apk info" SPCD_PM_UPDATE="apk update" - SPCD_PM_UPGRADE="apk upgrade" SPCD_PKG_PKG="" SPCD_PM_CONF_PATH="" SPCD_PM_CONF_TEXT="" @@ -705,7 +703,6 @@ sslverify=False SPCD_PM_INSTALL="pacman --sync --noconfirm" SPCD_PM_QUERY="pacman --query" SPCD_PM_UPDATE="pacman --sync --refresh" - SPCD_PM_UPGRADE="pacman --sync --sysupgrade --noconfirm" SPCD_PKG_PKG="" SPCD_PM_CONF_PATH="" SPCD_PM_CONF_TEXT="" @@ -719,7 +716,6 @@ SSLVerify = No SPCD_PM_INSTALL="apt-get install --assume-yes" SPCD_PM_QUERY="dpkg-query --show" SPCD_PM_UPDATE="apt-get update" - SPCD_PM_UPGRADE="apt-get upgrade --assume-yes" SPCD_PKG_PKG="apt-utils" SPCD_PM_CONF_PATH="/etc/apt/apt.conf.d/apt.conf" SPCD_PM_CONF_TEXT="\ @@ -739,7 +735,6 @@ Acquire::https::Verify-Peer False; SPCD_PM_INSTALL="zypper --non-interactive install" SPCD_PM_QUERY="rpm --query" SPCD_PM_UPDATE="zypper refresh" - SPCD_PM_UPGRADE="zypper --non-interactive update" SPCD_PKG_PKG="" SPCD_PM_CONF_PATH="" SPCD_PM_CONF_TEXT="\ @@ -752,7 +747,7 @@ Acquire::https::Verify-Peer False; esac spcd_split spcd_os_printenv "SPCD_PM_CLEAN" \ - "SPCD_PM_INSTALL" "SPCD_PM_QUERY" "SPCD_PM_UPDATE" "SPCD_PM_UPGRADE" + "SPCD_PM_INSTALL" "SPCD_PM_QUERY" "SPCD_PM_UPDATE" spcd_split spcd_os_printenv "SPCD_PKG_PKG" "SPCD_PM_CONF_PATH" "SPCD_PM_HTTPS_PATH" # specific @@ -1078,7 +1073,14 @@ spcd_packages_verify_https() { spcd_packages_upgrade_system() { spcd_step "Upgrade system" - ${SPCD_PM_UPGRADE} + case "${SPCD_PM}" in + "${SPCD_PM_APK}") apk upgrade ;; + "${SPCD_PM_APT}") apt-get upgrade --assume-yes ;; + "${SPCD_PM_DNF}") dnf upgrade --assumeyes ;; + "${SPCD_PM_PACMAN}") pacman --sync --sysupgrade --noconfirm ;; + "${SPCD_PM_ZYPPER}") zypper --non-interactive update ;; + *) ;; + esac } spcd_packages_install_dos2unix() {