os-upgrade.sh: some minor changes in color of script output.
This commit is contained in:
parent
7f8eb6641f
commit
30239c495b
@ -190,11 +190,11 @@ fi
|
|||||||
|
|
||||||
if $terminal ; then
|
if $terminal ; then
|
||||||
echo ""
|
echo ""
|
||||||
echo -e "\033[1mUpgrade Packages with a 'smart' conflict resolution system\033[m"
|
echo -e "\033[32m\033[1mUpgrade Packages with a 'smart' conflict resolution system\033[m"
|
||||||
echo ""
|
echo ""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echononl "\033[32m\033[1mResynchronize the package index files\033[m"
|
echononl "Resynchronize the package index files"
|
||||||
echo_print_command "apt-get update"
|
echo_print_command "apt-get update"
|
||||||
apt-get -y update > $log_file 2>&1
|
apt-get -y update > $log_file 2>&1
|
||||||
if [[ $? -gt 0 ]]; then
|
if [[ $? -gt 0 ]]; then
|
||||||
@ -208,7 +208,7 @@ fi
|
|||||||
#
|
#
|
||||||
packages_updated="$(apt-get -V -s dist-upgrade | grep -E "^ .*=>.*" | awk '{print$1}')"
|
packages_updated="$(apt-get -V -s dist-upgrade | grep -E "^ .*=>.*" | awk '{print$1}')"
|
||||||
|
|
||||||
#echononl "\033[32m\033[1mUpgrade Packages\033[m - \033[1mapt full-upgrade\033[m"
|
#echononl "Upgrade Packages"
|
||||||
#if [[ -n "$packages_updated" ]]; then
|
#if [[ -n "$packages_updated" ]]; then
|
||||||
# apt full-upgrade -y > $log_file 2>&1
|
# apt full-upgrade -y > $log_file 2>&1
|
||||||
# if [[ $? -gt 0 ]]; then
|
# if [[ $? -gt 0 ]]; then
|
||||||
@ -227,7 +227,7 @@ packages_updated="$(apt-get -V -s dist-upgrade | grep -E "^ .*=>.*" | awk '{pr
|
|||||||
# echo_skipped
|
# echo_skipped
|
||||||
#fi
|
#fi
|
||||||
|
|
||||||
echononl "\033[32m\033[1mUpgrade Packages\033[m"
|
echononl "Upgrade Packages"
|
||||||
echo_print_command "apt-get dist-upgrade"
|
echo_print_command "apt-get dist-upgrade"
|
||||||
if [[ -n "$packages_updated" ]]; then
|
if [[ -n "$packages_updated" ]]; then
|
||||||
apt-get dist-upgrade -y > $log_file 2>&1
|
apt-get dist-upgrade -y > $log_file 2>&1
|
||||||
@ -252,7 +252,7 @@ else
|
|||||||
echo_skipped
|
echo_skipped
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echononl "\033[32m\033[1mRemove unused Packages\033[m"
|
echononl "Remove unused Packages"
|
||||||
echo_print_command "apt-get autoremove"
|
echo_print_command "apt-get autoremove"
|
||||||
apt-get autoremove -y > $log_file 2>&1
|
apt-get autoremove -y > $log_file 2>&1
|
||||||
if [[ $? -gt 0 ]]; then
|
if [[ $? -gt 0 ]]; then
|
||||||
@ -262,7 +262,7 @@ else
|
|||||||
echo_done
|
echo_done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echononl "\033[32m\033[1mClear out the local repository of retrieved package files\033[m"
|
echononl "Clear out the local repository of retrieved package files"
|
||||||
echo_print_command "apt-get clean"
|
echo_print_command "apt-get clean"
|
||||||
apt-get clean -y > $log_file 2>&1
|
apt-get clean -y > $log_file 2>&1
|
||||||
if [[ $? -gt 0 ]]; then
|
if [[ $? -gt 0 ]]; then
|
||||||
@ -278,7 +278,7 @@ rc_packages="$(dpkg --list | awk '/^rc/ { print $2 }')"
|
|||||||
|
|
||||||
blank_line
|
blank_line
|
||||||
if $terminal; then
|
if $terminal; then
|
||||||
echo -e " \033[32m\033[1mRemove (purge) packages with only config files installed ((rc):\033[m"
|
echo -e " Remove (purge) packages with only config files installed ((rc):"
|
||||||
echo -en " \033[1mapt-get purge \$(dpkg --list | awk '/^rc/ { print $2 }')\033[m"
|
echo -en " \033[1mapt-get purge \$(dpkg --list | awk '/^rc/ { print $2 }')\033[m"
|
||||||
fi
|
fi
|
||||||
if [[ -n "$rc_packages" ]] ; then
|
if [[ -n "$rc_packages" ]] ; then
|
||||||
|
Loading…
Reference in New Issue
Block a user