Skip to content

Commit

Permalink
updated update-ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
VectorCell committed Sep 23, 2020
1 parent 810cdce commit 7cdc575
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion scripts/update-ubuntu
@@ -1,3 +1,20 @@
#!/bin/bash

sudo apt update && sudo apt -y upgrade && sudo apt -y dist-upgrade && sudo apt -y autoremove && echo DONE
sudo apt update \
&& sudo apt -y upgrade \
&& sudo apt -y dist-upgrade \
&& sudo apt -y autoremove \
&& echo DONE

if [ $? -ne 0 ]; then
echo "ERROR: update did not run successfully" 1>&2
exit 1
fi

if [ -e /var/run/reboot-required ]; then
echo
echo "This machine ($HOSTNAME) must be rebooted in order to complete the update process."
echo
echo "*** System restart required ***"
echo
fi

0 comments on commit 7cdc575

Please sign in to comment.