Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
osak
materials
Commits
af337d49
Commit
af337d49
authored
Apr 02, 2012
by
Patrick Hallen
Browse files
Martin and Niklas changed the whole structure of the script.
I copied the root install to the new script by Martin and Niklas
parent
2f4668fb
Changes
1
Hide whitespace changes
Inline
Side-by-side
linuxparty.sh
View file @
af337d49
...
...
@@ -10,72 +10,140 @@ then
exit
1
fi
askyesno
()
{
while
true
do
read
-n1
-p
"
$1
[j,n]"
echo
case
"
$REPLY
"
in
y|Y|j|J
)
return
0
;;
n|N
)
return
1
;;
*
)
echo
'Antworte bitte mit "j" für "Ja" oder "n" für "Nein"'
;;
esac
done
}
ok
()
{
echo
echo
-ne
"
\0
33[32;7m"
# gruen
echo
-n
"
$@
"
echo
-e
"
\0
33[0m"
# normal
}
warn
()
{
echo
echo
-ne
"
\0
33[33;7m"
# gelb
echo
-n
"
$@
"
echo
-e
"
\0
33[0m"
# normal
}
err
()
{
echo
echo
-ne
"
\0
33[31;7m"
# rot
echo
-n
"
$@
"
echo
-e
"
\0
33[0m"
# normal
}
# Verbose error trapping
showerr
()
{
err
"Bei der Installation ist ein Fehler aufgetreten. Frage einen Helfer."
}
trap
showerr ERR
# DEBUG-Modus:
apt-get
()
{
echo
"APT-GET
$@
"
}
#/ DEBUG-Modus:
# System absichern
if
askyesno
"Netzwerk: Soll die Ubuntu Firewall (ufw/gufw) aktiviert werden ?"
then
ufw
enable
apt-get
--quiet
install
-y
gufw
ok
"Firewall aktiviert, benutze 'gufw' um die Einstellungen der Firewall zu verändern"
fi
#Medibuntu einbinden
echo
"Sollen die Medibuntu-Paketquellen hinzugefügt werden? (y/n)"
read
medi
;
if
[
"
$medi
"
=
"y"
-o
"
$medi
"
=
"Y"
]
then
if
askyesno
"Sollen die Medibuntu-Paketquellen hinzugefügt werden ?"
then
wget
--output-document
=
/etc/apt/sources.list.d/medibuntu.list http://www.medibuntu.org/sources.list.d/
$(
lsb_release
-cs
)
.list
&&
apt-get
--quiet
update
&&
apt-get
--yes
--quiet
--allow-unauthenticated
install
medibuntu-keyring
&&
apt-get
--quiet
update
apt-get
--quiet
install
-y
app-install-data-medibuntu apport-hooks-medibuntu
apt-get
--quiet
install
-y
non-free-codecs
;
apt-get
--quiet
install
-y
libdvdread4
;
/usr/share/doc/libdvdread4/install-css.sh
;
apt-get
--quiet
install
-y
libdvdcss2 libxine1-ffmpeg gxine mencoder
;
apt-get
--quiet
install
-y
ffmpeg
;
apt-get
--quiet
install
-y
vlc mplayer
;
ech
o
"DVDs abspielen ist nun möglich; der VLC Player und mplayer sind installiert worden"
;
apt-get
--quiet
install
-y
non-free-codecs
apt-get
--quiet
install
-y
libdvdread4
/usr/share/doc/libdvdread4/install-css.sh
apt-get
--quiet
install
-y
libdvdcss2 libxine1-ffmpeg gxine mencoder
apt-get
--quiet
install
-y
ffmpeg
apt-get
--quiet
install
-y
vlc mplayer
o
k
"DVDs abspielen ist nun möglich; der VLC Player und mplayer sind installiert worden"
else
echo
"Es wurde nichts installiert"
fi
#Allgemeine Programme, Codecs, etc. installieren (VPN, LaTeX, gcc, Flash, unrar...)
echo
echo
"Programme, die für alle Fachrichtungen interressant sind (VPN, LaTeX, Flash, unrar, etc.)"
echo
"Magst du mit der Installation dieser fortfahren? (y/n)"
read
allgemein
if
[
"
$allgemein
"
=
"y"
-o
"
$allgemein
"
=
"Y"
]
then
apt-get
-y
--quiet
install
ubuntu-restricted-extras
;
echo
"Codec Installation abgeschlossen"
;
apt-get
install
-y
build-essential gcc g++ make automake vpnc network-manager-vpnc pwgen
;
apt-get
install
texlive texlive-doc-de texlive-latex-extra texlive-lang-german
;
echo
"Development Programme, VPN und LaTeX abgeschlossen"
;
if
askyesno
"Sollen diese Programme installiert werden ?"
then
apt-get
-y
--quiet
install
ubuntu-restricted-extras
ok
"Codec Installation abgeschlossen"
apt-get
install
synaptic pwgen
ok
"Installation der System-Utilities abgeschlossen"
apt-get
install
-y
build-essential gcc g++ make automake vpnc network-manager-vpnc
apt-get
install
texlive texlive-doc-de texlive-latex-extra texlive-lang-german
ok
"Development Programme, VPN und LaTeX abgeschlossen"
else
echo
"Es wurde nichts installiert"
fi
#Fachrichtung wählen
echo
"Wähle deine Fachrichtung:"
echo
"Informatik: 1"
echo
"Physik: 2"
echo
"Mathematik: 3"
read
answer
if
[
$answer
-eq
1
]
;
then
echo
"deb http://archive.canonical.com/ubuntu/ oneiric partner
deb-src http://archive.canonical.com/ubuntu/ oneiric partner"
>
/etc/apt/sources.list.d/java.list
apt-get update
apt-get
--quiet
install
-y
sun-java6-jdk eclipse hugs swi-prolog
;
echo
"Java, Haskell, Prolog und Eclipse wurden installiert"
;
elif
[
$answer
-eq
2
]
;
then
echo
echo
"Auswahl fachspezifischer Software. Wähle deine Fachrichtung:"
(
# Diese Subshell setzt PS3 nur lokal
PS3
=
"Deine Auswahl [1,2,3,4,5]<Enter>: "
select
fach
in
"Informatik"
"Mathematik"
"Physik"
"<anderes Fach>"
"<keine Spezial-Software installieren>"
do
case
"
$fach
"
in
""
)
echo
"Bitte wähle entsprechend deiner Fachrichtung eine Zahl von 1 bis 4 aus, tippe sie ein und drücke dann <Enter>"
;;
Informatik
)
apt-get
--quiet
install
-y
default-jdk eclipse hugs swi-prolog
ok
"Java, Haskell, Prolog und Eclipse wurden installiert"
break
;;
Physik
)
wget http://www.fsmpi.rwth-aachen.de/apt/osak@fsmpi.rwth-aachen.de.gpg.key
-O
fsmpi.key
apt-key add fsmpi.key
rm
fsmpi.key
echo
"deb http://www.fsmpi.rwth-aachen.de/apt/ oneiric main"
>
/etc/apt/sources.list.d/fsmpi-root.list
apt-get update
apt-get
install
-y
root-system libroot-core-dev libroot-bindings-python-dev
apt-get
--quiet
install
-y
root-system libroot-core-dev libroot-bindings-python-dev
echo
"ROOT wurde installiert"
apt-get
install
-y
python python-numpy python-simpy python-scipy python-matplotlib ipython python-dev gnuplot wxmaxima kmplot
;
echo
"Python inkl. einiger nützlicher Module wurde installiert"
elif
[
$answer
-eq
3
]
then
echo
"Bitte wende dich an deine Professoren"
fi
apt-get
--quiet
install
-y
python python-numpy python-simpy python-scipy python-matplotlib ipython python-dev gnuplot wxmaxima kmplot
ok
"Python (inkl. scipy und numpy), gnuplot, WxMaxima und KMplot wurden installiert"
break
;;
Mathematik
)
warn
"Bitte wende dich an deine Professoren - die Faschschaft I/1 könnte nicht klären,"
\
"welche (freie) Spezial-Software Mathematiker üblicherweise benutzen."
break
;;
"<anderes Fach>"
)
echo
echo
"Für andere Fächer gibt es keine allgemeine Software-Empfehlung. Frage einen Helfer."
break
;;
"<keine Spezial-Software installieren>"
)
break
;;
esac
done
)
echo
echo
"Wenn Du Software für eine weitere Fachrichung installieren möchtest, starte
$0
erneut."
#end;
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment