wip/clean,install,update,upgrade
This commit is contained in:
parent
7688ea0221
commit
1181e2411f
1 changed files with 14 additions and 14 deletions
28
cd.sh
28
cd.sh
|
@ -89,12 +89,26 @@ cd_set_environment_variables () {
|
||||||
# common
|
# common
|
||||||
case "${CD_OS_ID}" in
|
case "${CD_OS_ID}" in
|
||||||
"${CD_OS_ALMA}"|"${CD_OS_ROCKY}")
|
"${CD_OS_ALMA}"|"${CD_OS_ROCKY}")
|
||||||
|
CD_CMD_CLEAN="dnf clean all"
|
||||||
|
CD_CMD_INSTALL="dnf install --assumeyes"
|
||||||
|
CD_CMD_UPDATE="dnf makecache"
|
||||||
|
CD_CMD_UPGRADE="dnf upgrade --assumeyes"
|
||||||
;;
|
;;
|
||||||
"${CD_OS_ALPINE}")
|
"${CD_OS_ALPINE}")
|
||||||
|
CD_CMD_CLEAN="apk cache purge"
|
||||||
|
CD_CMD_INSTALL="apk add"
|
||||||
|
CD_CMD_UPDATE="apk update"
|
||||||
|
CD_CMD_UPGRADE="apk upgrade"
|
||||||
;;
|
;;
|
||||||
"${CD_OS_DEBIAN}"|"${CD_OS_UBUNTU}")
|
"${CD_OS_DEBIAN}"|"${CD_OS_UBUNTU}")
|
||||||
|
CD_CMD_CLEAN="apt-get clean"
|
||||||
|
CD_CMD_INSTALL="apt-get install --assume-yes"
|
||||||
|
CD_CMD_UPDATE="apt-get update"
|
||||||
|
CD_CMD_UPGRADE="apt-get upgrade --assume-yes"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
cd_split
|
||||||
|
cd_echo "CD_CMD_CLEAN" "CD_CMD_INSTALL" "CD_CMD_UPDATE" "CD_CMD_UPGRADE"
|
||||||
#
|
#
|
||||||
case "${CD_OS_ID}" in
|
case "${CD_OS_ID}" in
|
||||||
"${CD_OS_ALMA}")
|
"${CD_OS_ALMA}")
|
||||||
|
@ -104,10 +118,6 @@ cd_set_environment_variables () {
|
||||||
"8"|"9") ;;
|
"8"|"9") ;;
|
||||||
*) cd_error_os "CD_OS_VERSION" ;;
|
*) cd_error_os "CD_OS_VERSION" ;;
|
||||||
esac
|
esac
|
||||||
CD_CMD_CLEAN="dnf clean all"
|
|
||||||
CD_CMD_INSTALL="dnf install --assumeyes"
|
|
||||||
CD_CMD_UPDATE="dnf makecache"
|
|
||||||
CD_CMD_UPGRADE="dnf upgrade --assumeyes"
|
|
||||||
CD_PKG_PKG=""
|
CD_PKG_PKG=""
|
||||||
CD_PM_CONF_PATH="/etc/dnf/dnf.conf"
|
CD_PM_CONF_PATH="/etc/dnf/dnf.conf"
|
||||||
CD_PM_CONF_TEXT="\
|
CD_PM_CONF_TEXT="\
|
||||||
|
@ -131,10 +141,6 @@ skip_if_unavailable=False
|
||||||
"3.18"|"3.19") ;;
|
"3.18"|"3.19") ;;
|
||||||
*) cd_error_os "CD_OS_VERSION" ;;
|
*) cd_error_os "CD_OS_VERSION" ;;
|
||||||
esac
|
esac
|
||||||
CD_CMD_CLEAN="apk cache purge"
|
|
||||||
CD_CMD_INSTALL="apk add"
|
|
||||||
CD_CMD_UPDATE="apk update"
|
|
||||||
CD_CMD_UPGRADE="apk upgrade"
|
|
||||||
CD_PKG_PKG=""
|
CD_PKG_PKG=""
|
||||||
CD_PM_CONF_PATH=""
|
CD_PM_CONF_PATH=""
|
||||||
CD_PM_CONF_TEXT=""
|
CD_PM_CONF_TEXT=""
|
||||||
|
@ -154,10 +160,6 @@ skip_if_unavailable=False
|
||||||
"bullseye") CD_PYTHON_COMMAND="python3.9" ;;
|
"bullseye") CD_PYTHON_COMMAND="python3.9" ;;
|
||||||
*) cd_error_os "CD_OS_VERSION" ;;
|
*) cd_error_os "CD_OS_VERSION" ;;
|
||||||
esac
|
esac
|
||||||
CD_CMD_CLEAN="apt-get clean"
|
|
||||||
CD_CMD_INSTALL="apt-get install --assume-yes"
|
|
||||||
CD_CMD_UPDATE="apt-get update"
|
|
||||||
CD_CMD_UPGRADE="apt-get upgrade --assume-yes"
|
|
||||||
CD_PKG_PKG="apt-utils"
|
CD_PKG_PKG="apt-utils"
|
||||||
CD_PM_CONF_PATH="/etc/apt/apt.conf.d/apt.conf"
|
CD_PM_CONF_PATH="/etc/apt/apt.conf.d/apt.conf"
|
||||||
CD_PM_CONF_TEXT="\
|
CD_PM_CONF_TEXT="\
|
||||||
|
@ -201,8 +203,6 @@ Dir::Etc::SourceParts \"\";
|
||||||
CD_PROJECT_URL="${CD_PROJECTS_URL}/${CD_PROJECT_NAME}"
|
CD_PROJECT_URL="${CD_PROJECTS_URL}/${CD_PROJECT_NAME}"
|
||||||
#
|
#
|
||||||
cd_split
|
cd_split
|
||||||
cd_echo "CD_CMD_CLEAN" "CD_CMD_INSTALL" "CD_CMD_UPDATE" "CD_CMD_UPGRADE"
|
|
||||||
cd_split
|
|
||||||
cd_echo "CD_PKG_PKG"
|
cd_echo "CD_PKG_PKG"
|
||||||
cd_split
|
cd_split
|
||||||
cd_echo "CD_PM_CONF_PATH" "CD_PM_HTTPS_PATH"
|
cd_echo "CD_PM_CONF_PATH" "CD_PM_HTTPS_PATH"
|
||||||
|
|
Loading…
Reference in a new issue