#!/bin/bash
# -rwxrwxr-x 1 root staff	/usr/local/bin/sysupdate
#	  https://crystalfaeries.net/posix/bin/sysupdate
#	  celeste@crystalfaeries.net SYSUPDATE 2021-05-01 19:26:54+00:00
# the one thing you want to do as root when you login, is
# make sure you're running the latest set of "as yet not known to be compromised" code:
ping -c 1 one.one.one.one			# famous public DNS server
if	[[ $? -eq 0 ]]
then	# we have internet access
	/usr/local/bin/etc_hosts		# update /etc/hosts
	dpkg --configure -a			# recover from any configuration crash
	apt-get install  -f			# recover from any incomplete installation
	apt-get      update			# update our local cache of metadata of packages
	apt-get	     upgrade			# upgrade automagickally to track in-release upgrades
	apt-get dist-upgrade			# upgrade automagickally tracking distribution releases
	apt-get autoremove			# lighten our cache load
	apt-get autoclean			# lighten our cache load
fi
glances						# take a glance at your upgraded system
htop						# what are the top users of CPU cycles?
powertop					# what are the top users of power?
ps -ef --forest | less -X			# what all is running?
watch -d	-n 300	'limits;df --full'	# uptime replaced by powerline in konsole
