You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
462 B
21 lines
462 B
# System-Updater CC-BY Olli Graf
|
|
# V 1.6 2019
|
|
|
|
VERSION="1.7"
|
|
TMPFILE="/tmp/updater.txt"
|
|
|
|
echo "Updater V ${VERSION}"
|
|
sudo rm -f ${TMPFILE}
|
|
sudo apt-get update
|
|
sudo apt-get dist-upgrade -y --allow-unauthenticated |tee ${TMPFILE}
|
|
sudo snap refresh
|
|
sudo apt-get autoremove -y
|
|
if grep -q linux-header ${TMPFILE}; then
|
|
echo "reboot nötig"
|
|
read -n1 -p "Neustart? (J/N)" auswahl
|
|
if [ "${auswahl}" == "j" ]; then
|
|
echo "System wird gestartet."
|
|
sudo reboot
|
|
fi
|
|
|
|
fi
|
|
|