adding script to ignore missing packages with apt

This commit is contained in:
Matt Burchett 2016-08-03 04:00:52 -05:00
parent fea2bbd11c
commit a7f5999cf0

14
install-with-apt.sh Normal file
View File

@ -0,0 +1,14 @@
#!/bin/bash
# This installs packages one by one with apt in the event packages don't exist.
#Check whether root
if [ $(whoami) != root ]; then
echo You must be root or use sudo to install packages.
return
fi
#Call apt-get for each package
for pkg in "$@"
do
sudo apt-get -my install $pkg
done