Last active
December 30, 2015 14:08
-
-
Save cmfcmf/7839730 to your computer and use it in GitHub Desktop.
Ubuntu Installer Script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash | |
# Update Software | |
sudo apt-get update | |
sudo apt-get upgrade | |
# Set launcher icons | |
gsettings set com.canonical.Unity.Launcher favorites "['application://gnome-terminal.desktop', 'application://nautilus.desktop', 'unity://running-apps', 'unity://expo-icon', 'unity://devices']" | |
# PHP, Apache2, etc. | |
echo "Installiere apache2, php5, mysql-server" | |
sudo apt-get install -y php5 apache2 mysql-server php5-mysql phpmyadmin | |
# Correctly set timezone | |
timezone=$(tail /etc/timezone) | |
timezone=$(echo "${timezone}" | sed 's/\//\\\//g') | |
arg='s/\;date\.timezone =.*$/date\.timezone = \"'$timezone'\"/' | |
sudo sed -i "$arg" /etc/php5/apache2/php.ini | |
# TODO | |
#echo "Bitte fuegen Sie in \"/etc/apache2/httpd.conf\" die Zeile \"ServerName localhost\" hinzu, um Warnungen zu vermeiden" | |
#echo "Druecken Sie eine beliebige Taste, um fortzufahren, wenn Sie fertig sind." | |
#read -n 1 | |
echo "Starte Apache2 neu" | |
sudo service apache2 restart | |
# Misc | |
sudo apt-get install -y poedit chromium-browser chromium-browser-l10n doxygen graphviz dia gedit gedit-plugins nautilus-open-terminal git | |
# C | |
sudo apt-get install -y gcc gcc-avr avr-libc avrdude | |
# Indicator | |
sudo add-apt-repository ppa:indicator-multiload/stable-daily | |
sudo apt-get update | |
sudo apt-get install indicator-multiload -y | |
# Misc | |
sudo apt-get install skype audacity blender gimp imagemagick wine meld thunderbird vlc -y | |
# Vorlagen | |
echo "<head>" > ~/Vorlagen/HTML.html | |
echo " <title></title>" >> ~/Vorlagen/HTML.html | |
echo "</head>" >> ~/Vorlagen/HTML.html | |
echo "<body>" >> ~/Vorlagen/HTML.html | |
echo "" >> ~/Vorlagen/HTML.html | |
echo "</body>" >> ~/Vorlagen/HTML.html | |
echo "<?php" > ~/Vorlagen/PHP.php | |
echo "" >> ~/Vorlagen/PHP.php | |
echo "#!/bin/bash" > ~/Vorlagen/Skript.sh | |
echo "" >> ~/Vorlagen/Skript.sh | |
echo "exit 0" >> ~/Vorlagen/Skript.sh | |
echo "#include <stdio.h>" > ~/Vorlagen/C.c | |
echo "" >> ~/Vorlagen/C.c | |
echo "/**" >> ~/Vorlagen/C.c | |
echo " * @brief main function" >> ~/Vorlagen/C.c | |
echo " * @return int" >> ~/Vorlagen/C.c | |
echo " * @author <Name>" >> ~/Vorlagen/C.c | |
echo " * @date <Datum>" >> ~/Vorlagen/C.c | |
echo " *" >> ~/Vorlagen/C.c | |
echo " * <Beschreibung>" >> ~/Vorlagen/C.c | |
echo " */" >> ~/Vorlagen/C.c | |
echo "int main void()" >> ~/Vorlagen/C.c | |
echo "{" >> ~/Vorlagen/C.c | |
echo " " >> ~/Vorlagen/C.c | |
echo " return 1;" >> ~/Vorlagen/C.c | |
echo "}" >> ~/Vorlagen/C.c | |
echo "#include <avr/io.h>" > ~/Vorlagen/µC.c | |
echo "" >> ~/Vorlagen/µC.c | |
echo "#define F_CPU 1000000 ///< Defines clock frequency of µC" >> ~/Vorlagen/µC.c | |
echo "" >> ~/Vorlagen/µC.c | |
echo "/**" >> ~/Vorlagen/µC.c | |
echo " * @brief main function" >> ~/Vorlagen/µC.c | |
echo " * @author <Name>" >> ~/Vorlagen/µC.c | |
echo " * @date <Datum>" >> ~/Vorlagen/µC.c | |
echo " *" >> ~/Vorlagen/µC.c | |
echo " * <Beschreibung>" >> ~/Vorlagen/µC.c | |
echo " */" >> ~/Vorlagen/µC.c | |
echo "int main void()" >> ~/Vorlagen/µC.c | |
echo "{" >> ~/Vorlagen/µC.c | |
echo " " >> ~/Vorlagen/µC.c | |
echo "}" >> ~/Vorlagen/µC.c | |
# End | |
sudo apt-get autoremove -y |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment