Using Super to Automate Tasks

The super package, available in Debian and its derivatives, can be used to automate many tasks requiring root privileges to run.

Install the package and edit the configuration file:

~$ sudo nano /etc/super.tab
Add these lines to the end of the file:
update  "/usr/bin/apt-get    update"   martin  u+g=root
upgrade	"/usr/bin/apt-get -y upgrade"  martin  u+g=root \
 setenv=PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

Now it's possible for me, an ordinary user, to execute the update/upgrade prosess without the use of su or sudo:

~$ super update
~$ super upgrade