Ubuntu – How to install multiple PPAs and applications at once

aptinstallationppascripts

I'm going to set up a couple of general use computers on one of my lab's work benches.

There's a whole bunch of PPA repositories and applications from the Ubuntu repositories that I'd like to install after an initial Ubuntu installation.

Is it possible to write up a script that will install all those apps and PPAs in one go, requiring me only to double click the executable script and type in the admin password?

I imagine it would be fairly straight forward. Could someone point me to a quick tutorial or perhaps even provide a template script of some sort so I can add in the PPA names and apt-get install packages?

Thanks.

Best Answer

I used the simple script below to add the texworks and Ubuntu GIS PPAs and then install texworks and Quantum Gis from their respective source, you can expand on it by adding the other PPAs and adding the package names to the apt-get install command line.

#!/bin/bash

echo "Adding PPAs"

add-apt-repository ppa:texworks
add-apt-repository ppa:ubuntugis/ubuntugis-unstable


echo "updating repositories"
apt-get update

echo "Installing packages"

apt-get install texworks qgis

echo "Finished adding PPAs and insatlling applications"
exit 0