#!/bin/bash
# Thomas Dreibholz's Install Script for Intepid Ibex
# Copyright (C) 2007-2008 by Thomas Dreibholz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
#
# Contact: thomas.dreibholz@gmail.com

# ------ Keys for additional repositories -----------------------------------
if [ "$1" = "initial" ] ; then
   # wget -q http://packages.medibuntu.org/medibuntu-key.gpg -O- | sudo apt-key add -
   # Launchpad PPA for Thomas Dreibholz
   gpg --keyserver keyserver.ubuntu.com --recv-keys 8A8EAF3E2F2E3BB5C75F48C1CCEB82DF916C56E0 && gpg --export -a 8A8EAF3E2F2E3BB5C75F48C1CCEB82DF916C56E0 | sudo apt-key add -
   # Launchpad PPA for kubuntu-experimental
   gpg --keyserver keyserver.ubuntu.com --recv-keys F3C48CB3011FA791D74ACAAC60487016493B3065 && gpg --export -a F3C48CB3011FA791D74ACAAC60487016493B3065 | sudo apt-key add -
   # Launchpad PPA for Amarok 2.0
   gpg --keyserver keyserver.ubuntu.com --recv-keys 98F4AD08F5B1A7304029D4A99423A34CCA967634 && gpg --export -a 98F4AD08F5B1A7304029D4A99423A34CCA967634 | sudo apt-key add -
   # Launchpad PPA for Project Neon
   gpg --keyserver keyserver.ubuntu.com --recv-keys 88A96934450B471BDA26FE3A778978B00F7992B0 && gpg --export -a 88A96934450B471BDA26FE3A778978B00F7992B0 | sudo apt-key add -
   # Medibuntu key ring
   # wget -q http://packages.medibuntu.org/medibuntu-key.gpg -O- | sudo apt-key add -
   sudo apt-get update && sudo apt-get --yes -q --allow-unauthenticated install medibuntu-keyring
   # Pearson KDE 3.5 Repository
   gpg --keyserver keyserver.ubuntu.com --recv-keys 57f67225c90dcd129dfef333079a381c44869960 && gpg --export -a 88A96934450B471BDA26FE3A778978B00F7992B0 | sudo apt-key add -
   # Launchpad PPA for OpenOffice package
   gpg --keyserver keyserver.ubuntu.com --recv-keys d2bb86e0ebd0f0a43d4db3a760d11217247d1cff && gpg --export -a d2bb86e0ebd0f0a43d4db3a760d11217247d1cff | sudo apt-key add -
fi

PACKAGES="kubuntu-desktop ubuntu-desktop"

# ------ Tools --------------------------------------------------------------
PACKAGES="$PACKAGES autofs ding joe kcalc kgpg kweather lha manpages-de manpages-de-dev manpages-dev mathomatic powertop sdparm smartmontools trans-de-en unace unrar xdms ytree agrep dict ibritish ingerman ispell snmp"

# ------ Networking ---------------------------------------------------------
PACKAGES="$PACKAGES amule firefox httrack kismet lksctp-tools ncftp nmap nttcp openssh-server portmap spamassassin rsplib-tools rsplib-services rsplib-fgp-cfgfiles w3m whois wireshark traceroute lynx elinks links kdeplasma-addons"

# ------ Development, LaTeX, Firefox and many other tools -------------------
# Compiler and Tool-Chains
PACKAGES="$PACKAGES automake autoconf bison cmake colorgcc doxygen eclipse eclipse-cdt f2c flex gcc gcc-doc gcj gdb intltool kdevelop libtool quanta subversion valgrind swig cdbs config-package-dev rpm apt-file"
# Libraries
PACKAGES="$PACKAGES blt-dev libgtk-dev libcurl4-openssl-dev libglib1.2-dev libglib1.2ldbl libglib2.0-dev libglib2.0-doc libgtk2.0-dev libmagick++9-dev libmagick9-dev libpango1.0-dev libpcap-dev libreadline-dev librsplib-dev libcpprspserver-dev libsctp-dev libsdl-dev xsltproc libgeoip-dev geoip-bin libadns1-dev libsmi2-dev libc-ares-dev"
# Debian
PACKAGES="$PACKAGES debhelper devscripts dput dupload fakeroot lintian pbuilder"
# Linux
PACKAGES="$PACKAGES linux-doc linux-headers-generic linux-image-generic linux-restricted-modules-generic linux-source"
# Java
PACKAGES="$PACKAGES sun-java6-demo sun-java6-fonts sun-java6-javadb sun-java6-jdk sun-java6-source"
# Qt
PACKAGES="$PACKAGES kdelibs4-dev libqt4-dev qt4-demos qt4-designer qt4-dev-tools qt4-doc qt4-doc-html qt4-qtconfig libqt4-dbg"

# ------ Graphics Processing ------------------------------------------------
PACKAGES="$PACKAGES dia digikam giftrans gimp gimp-data-extras gimp-help-de gimp-help-en gnuplot graphviz imagemagick inkscape kphotoalbum kpovmodeler msttcorefonts povray povray-doc povray-examples povray-includes r-base r-base-dev r-base-html r-base-latex r-doc-html r-doc-info r-doc-pdf r-mathlib transfig xfig"

# ------ LaTeX and Document Processing --------------------------------------
PACKAGES="$PACKAGES a2ps gv kbibtex chktex kdvi kile kile-i18n-de latex-beamer lyx pdfedit pdftk pstoedit scribus tetex-extra texlive-extra-utils"

# ------ Multimedia ---------------------------------------------------------
PACKAGES="$PACKAGES ekiga festival festival-doc festlex-oald festvox-rablpc16k lame libdvdcss2 libdvdread3 libk3b2-extracodecs libtunepimp5-mp3 libxine1-ffmpeg mozilla-plugin-vlc mp3blaster mplayer vlc vlc-plugin-arts"

# ------ Localization -----------------------------------------------------------
PACKAGES="$PACKAGES language-pack-de language-pack-kde-de language-pack-kde-de-base language-support-de"

# ------ Commercial stuff ---------------------------------------------------
PACKAGES="$PACKAGES acroread flashplugin-nonfree googleearth mozilla-acroread"

# ------ Kernel and system-specific packages --------------------------------
# ------ 32 Bit ------
# PACKAGES="$PACKAGES w32codecs sun-java6-plugin"
# ------ 64 Bit ------
# PACKAGES="$PACKAGES w64codecs"


# ---------------------------------------------------------------------------
sudo apt-get -q update && \
sudo apt-get -q install $PACKAGES && \
sudo apt-get -q dist-upgrade && \
sudo apt-get -q autoremove
