#!/bin/bash
# scibuntu - scientific extensions for Ubuntu 6.04 LTS 
# by Urban Anjar 
# Copyleft, all rights reversed
# Ver: 0.1 061023 - First version
# Ver: 0.2 061030 - More programs, deb-installation loop

LOG=.scibuntu_log

PACKAGES=" libgl1-mesa-swrast emacs21 build-essential g77 gfortran sharutils binutils sysutils tetex-base tetex-bin tetex-extra gs gv grace octave gnuplot labplot gromacs gromacs-doc rasmol pymol t-coffee r-base openbabel ncbi-tools-x11 ncbi-tools-bin python-biopython blast2 bioperl clustalw clustalx tree-puzzle treewiewx"


echo "Scibuntu: Downloading, installing and configuring software. This will take some time. Some parts of the installation requires your attention."

#Installing all Ubuntu deb packages
for P in $PACKAGES; do
	echo Installing $P
	apt-get install $P -qy >> $LOG
	echo $P ready
done

#Installing non-ubuntu packages
echo "Installing phylo_win"
wget ftp://pbil.univ-lyon1.fr/pub/mol_phylogeny/phylo_win/phylo_winlinuxPC.tgz >>$LOG
tar -xvf phylo_winlinuxPC.tgz >> $LOG
rm phylo_winlinuxPC.tgz >> $LOG
mv phylo_winlinuxPC /usr/local >> $LOG
ln -s /usr/local/phylo_winlinuxPC/phylo_win /usr/local/bin >> $LOG
echo "phylo_win ready"

#http://kent.dl.sourceforge.net/sourceforge/salstat/salstat.20031022.tar.gz

echo "Installing Adobe Reader"
wget http://ardownload.adobe.com/pub/adobe/reader/unix/7x/7.0.8/enu/AdobeReader_enu-7.0.8-1.i386.tar.gz >> $LOG
tar -xvf AdobeReader*.tar.gz >> $LOG
cd AdobeReader >> $LOG
gnome-terminal -e ./INSTALL >> $LOG
cd .. >> $LOG
rm -rf AdobeReader >> $LOG
rm AdobeReader*.tar.gz >> $LOG
echo "AdobeReader ready" >> $LOG

echo "SciBuntu: Done"
