#!/bin/bash # Make sure only root can run our script if [ "$(id -u)" != "0" ]; then echo "This script must be run with sudo" 1>&2 exit 1 fi for i in `cat ~/list.txt` ; do apt-get install -y $i done