Created
August 6, 2010 00:07
-
-
Save RyanScottLewis/510612 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 | |
#===--- | |
( | |
echo "1" | |
testconnection=`wget --tries=3 --timeout=15 www.google.com -O /tmp/testinternet &>/dev/null 2>&1` | |
if [ $? != 0 ]; then | |
echo "#Internet Connection: Not connected" | |
else | |
echo "#Internet Connection: Connected" | |
fi | |
) | zenity --title="Checking Internet Connection" \ | |
--text="Internet Connection: Checking..." \ | |
--width=350 \ | |
--progress --pulsate | |
if [ $? = 1 ]; then | |
exit | |
fi | |
#===--- | |
sudo -k | |
zenity --entry --hide-text \ | |
--width=350 \ | |
--title="Root Password" \ | |
--text="Enter your root password:" | sudo -S -v | |
if [ "$?" != 0 ]; then | |
zenity --error --text="Sorry, bad password" | |
exit | |
fi | |
#===--- | |
( | |
echo "1" | |
echo "#Adding source ppa:nautilus-dropbox/ppa..." | |
sudo add-apt-repository ppa:nautilus-dropbox/ppa | |
echo "#Adding source ppa:chromium-daily/ppa..." | |
sudo add-apt-repository ppa:chromium-daily/ppa | |
echo "#Adding source ppa:c-korn/ppa..." | |
sudo add-apt-repository ppa:c-korn/ppa | |
echo "#Adding source ppa:deluge-team/ppa..." | |
sudo add-apt-repository ppa:deluge-team/ppa | |
echo "#Adding source ppa:bisigi/ppa..." | |
sudo add-apt-repository ppa:bisigi/ppa | |
echo "#Adding source ppa:tualatrix/ppa..." | |
sudo add-apt-repository ppa:tualatrix/ppa | |
echo "#Adding source ppa:git-core/ppa..." | |
sudo add-apt-repository ppa:git-core/ppa | |
echo "#Updating sources..." | |
sudo apt-get update | |
echo "#Done" | |
) | zenity --title="Add sources" --text="Please wait..." --progress --pulsate --auto-kill | |
if [ "$?" != 0 ]; then | |
exit | |
fi |
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 | |
IFS="|" | |
#===--- | |
( | |
echo "1" | |
testconnection=`wget --tries=3 --timeout=15 www.google.com -O /tmp/testinternet &>/dev/null 2>&1` | |
if [ $? != 0 ]; then | |
echo "#Internet Connection: Not connected" | |
else | |
echo "#Internet Connection: Connected" | |
fi | |
) | zenity --title="Checking Internet Connection" \ | |
--text="Internet Connection: Checking..." \ | |
--width=350 \ | |
--progress --pulsate | |
if [ $? = 1 ]; then | |
exit | |
fi | |
#===--- | |
sudo -k | |
zenity --entry --hide-text \ | |
--width=350 \ | |
--title="Root Password" \ | |
--text="Enter your root password:" | sudo -S -v | |
if [ "$?" != 0 ]; then | |
zenity --error --text="Sorry, bad password" | |
exit | |
fi | |
#===--- | |
choices=`/usr/bin/zenity \ | |
--list --checklist \ | |
--width=275 --height=350 \ | |
--title="Select Applications" \ | |
--text "What would you like to do?" \ | |
--column "" --column "Actions" \ | |
TRUE "Install Dropbox" \ | |
TRUE "Install VLC" \ | |
TRUE "Install Deluge" \ | |
TRUE "Install Guake" \ | |
TRUE "Install Ubuntu Tweak" \ | |
TRUE "Install Compiz Settings Manager" \ | |
TRUE "Install Chromium" \ | |
TRUE "Install Extra Themes"` | |
#===--- | |
if [ "$choices" = "" ]; then | |
question=`zenity --question --text="Would you like to exit?"` | |
if [ $? -eq 0 ]; then | |
exit | |
fi | |
else | |
for choice in $choices; do | |
if [ "$choice" = "Install Dropbox" ]; then | |
apps="$apps|nautilus-dropbox" | |
elif [ "$choice" = "Install Chromium" ]; then | |
apps="${apps}|chromium-browser" | |
elif [ "$choice" = "Install VLC" ]; then | |
apps="${apps}|vlc" | |
elif [ "$choice" = "Install Deluge" ]; then | |
apps="${apps}|deluge-torrent" | |
elif [ "$choice" = "Install Extra Themes" ]; then | |
apps="${apps}|bisigi-themes|community-themes" | |
elif [ "$choice" = "Install Ubuntu Tweak" ]; then | |
apps="${apps}|ubuntu-tweak" | |
elif [ "$choice" = "Install Ruby Version Manager" ]; then | |
sources="${sources}|ppa:git-core/ppa" | |
apps="${apps}|rvm" | |
elif [ "$choice" = "Install Guake" ]; then | |
apps="${apps}|guake" | |
elif [ "$choice" = "Install Compiz Settings Manager" ]; then | |
apps="${apps}|compizconfig-settings-manager|compiz-fusion-plugins-extra" | |
fi | |
done | |
#===--- | |
( | |
echo "1" | |
echo "#Updating sources..." | |
sudo apt-get update >&2 | |
for app in $apps; do | |
echo "#Installing $app..." | |
sudo apt-get install $app | |
done | |
echo "#Preforming dist-upgrade..." | |
sudo apt-get dist-upgrade >&2 | |
echo "#Upgrading packages..." | |
sudo apt-get upgrade >&2 | |
echo "#Done!" | |
) | zenity --title="Installing Applications" \ | |
--text="Please wait..." \ | |
--progress --pulsate --auto-kill | |
if [ $? = 1 ]; then | |
exit | |
fi | |
#===--- | |
echo -n "Cleaning up... " | |
sudo apt-get clean | |
echo "Done." | |
#===--- | |
fi |
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 | |
#===--- | |
( | |
echo "1" | |
testconnection=`wget --tries=3 --timeout=15 www.google.com -O /tmp/testinternet &>/dev/null 2>&1` | |
if [ $? != 0 ]; then | |
echo "#Internet Connection: Not connected" | |
else | |
echo "#Internet Connection: Connected" | |
fi | |
) | zenity --title="Checking Internet Connection" \ | |
--text="Internet Connection: Checking..." \ | |
--width=350 \ | |
--progress --pulsate | |
if [ $? = 1 ]; then | |
exit | |
fi | |
#===--- | |
sudo -k | |
zenity --entry --hide-text \ | |
--width=350 \ | |
--title="Root Password" \ | |
--text="Enter your root password:" | sudo -S -v | |
if [ "$?" != 0 ]; then | |
zenity --error --text="Sorry, bad password" | |
exit | |
fi | |
#===--- | |
( | |
echo "1" | |
if [[ -f /etc/rvmrc ]] ; then source /etc/rvmrc ; fi | |
if [[ -f "$HOME/.rvmrc" ]] ; then source "$HOME/.rvmrc" ; fi | |
rvm_path="${rvm_path:-$HOME/.rvm}" | |
mkdir -p $rvm_path/src/ | |
builtin cd $rvm_path/src | |
rm -rf ./rvm/ | |
echo "#Cloning github repository..." | |
git clone http://github.com/wayneeseguin/rvm.git | |
builtin cd rvm | |
dos2unix scripts/* >/dev/null 2>&1 | |
echo "#Installing..." | |
bash ./scripts/install >&2 | |
echo "#Done." | |
) | zenity --title="Installing RVM" --text="Please wait..." --progress --pulsate --auto-kill | |
if [ "$?" != 0 ]; then | |
exit | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment