Last active
December 30, 2016 08:17
-
-
Save kozak127/8495071 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 | |
### DEFINE UBUNTU VERSION SHORT CODENAME | |
# IF YOU ARE USING UBUNTU-BASED DISTRO, BUT NOT UBUNTU (LINUX MINT ETC.) | |
# RUN SCRIPT WITH NAME OF BASE UBUNTU DISTRO | |
# FOR LINUX MINT 17 | |
# ./startup_install.sh trusty | |
if [ -z "$1" ] | |
then | |
version=$(lsb_release -sc) | |
else | |
version=$1 | |
fi | |
### DEFINE PACKAGES | |
# STANDARD | |
accessories='arandr baobab catfish conky deja-dup easystroke xfburn unetbootin' | |
graphics='gimp gthumb inkscape imagemagick simple-scan' | |
internet='deluge filezilla firefox pidgin thunderbird hexchat' | |
internet_chromium='chromium-browser pepperflashplugin-nonfree' | |
internet_skype='skype libasound2-plugins:i386' # skype and its crash-free dependencies | |
multimedia='audacity exfalso pavucontrol pulseaudio soundconverter winff' | |
multimedia_vlc='browser-plugin-vlc vlc vlc-plugin-notify vlc-plugin-vlsub' | |
multimedia_mplayer='smplayer' | |
language='myspell-pl aspell-pl' | |
office='evince libreoffice' | |
system='gdebi gnome-disk-utility gnome-system-tools gparted ppa-purge synaptic system-config-samba' | |
terminal='htop lm-sensors lshw mc mtr suckless-tools p7zip-full rsync unrar' | |
# UBUNTU-SPECIFIC | |
ubuntu_specific='ubuntu-restricted-extras' | |
# XUBUNTU-SPECIFIC | |
xubuntu_specific='ubuntu-restricted-extras xfce4-goodies' | |
# GENERAL DEV | |
dev_connect='ssh sshfs remmina remmina-plugin-rdp remmina-plugin-vnc network-manager-openvpn-gnome openvpn xrdp' | |
dev_repo='subversion rapidsvn git git-gui meld' | |
dev_other='groovy mono-complete libmysqlclient-dev' | |
dev_jdgui='libgtk2.0-0:i386 libxxf86vm1:i386 libsm6:i386 lib32stdc++6' # required for jd-gui java decompiler to work | |
dev_hack='aircrack-ng arp-scan kismet nmap wireshark' | |
# LANGUAGE-SPECIFIC DEV | |
dev_cpp='build-essential cmake cppcheck ghex' | |
dev_java='maven openjdk-8-jre openjdk-8-jdk openjdk-8-doc openjdk-8-source' | |
dev_python='python-pip python-virtualenv python2.7 python2.7-dev python3 python3-dev' | |
# CRAP FOR REMOVAL | |
crap='abiword banshee brasero empathy gnumeric gmusicbrowser parole rhythmbox shotwell totem transmission-gtk vinagre xchat xscreensaver' | |
### ADD NON-STANDARD REPOSITORIES & APPS | |
# UBUNTU 'PARTNER' REPOSITORY (NON-FREE PACKAGES) | |
add-apt-repository "deb http://archive.canonical.com/ $version partner" | |
# UBUNTU BLEEDING-EDGE VIDEO DRIVERS (CAUTION) | |
add-apt-repository ppa:oibaf/graphics-drivers | |
# SPOTIFY | |
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 94558F59 | |
add-apt-repository "deb http://repository.spotify.com stable non-free" | |
spotify='spotify-client' | |
# SUBLIME TEXT 3 | |
add-apt-repository ppa:webupd8team/sublime-text-3 | |
sublime_text="sublime-text-installer" | |
# MPLAYER WITH H265 SUPPORT | |
sudo add-apt-repository ppa:mc3man/mplayer-test | |
### MAKE CHANGES | |
# INSTALL STANDARD APPS | |
apt-get --yes --force-yes update | |
apt-get --yes --force-yes -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" upgrade | |
apt-get --yes --force-yes install $accessories $graphics $internet $internet_skype $multimedia $multimedia_mplayer $language $office $system $terminal | |
# INSTALL NON-STANDARD APPS | |
apt-get --yes --force-yes install $sublime_text $spotify | |
# INSTALL DEV TOOLS | |
apt-get --yes --force-yes install $dev_connect $dev_repo $dev_other $dev_jdgui $dev_hack $dev_cpp $dev_java $dev_python | |
# INSTALL SPECIFIC FOR UBUNTU / XUBUNTU | |
if [ $(dpkg-query -W -f='${Status}' thunar 2>/dev/null | grep -c "ok installed") -eq 0 ]; | |
then | |
apt-get --yes --force-yes install $ubuntu_specific $ubuntu_dev_repo # UBUNTU | |
else | |
apt-get --yes --force-yes install $xubuntu_specific $xubuntu_dev_repo $xubuntu_dropbox # XUBUNTU | |
fi | |
# REMOVE PREINSTALLED CRAP | |
apt-get --yes --force-yes remove $crap | |
### SYSTEM CONFIGURATION | |
# MAKE SERVERS AND SAMBA WORK IN USER-SPACE | |
chmod 755 `eval echo ~$USER` | |
# SET SWAP USAGE TO MINIMUM | |
sysctl -w vm.swappiness=5 | |
# ENABLE DROPBOX TO MONITOR FILE SYSTEM | |
sysctl -w fs.inotify.max_user_watches=524288 | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment