71769107dbff230ec7607368f50f9ff93b88b581

Author
Robby Russell <robby@planetargon.com>
Committer
Robby Russell <robby@planetargon.com>
Date

Message

Adding an installer tool

Diff

 1diff --git a/tools/install.sh b/tools/install.sh
 2new file mode 100644
 3index 0000000000000000000000000000000000000000..d820adcb59ccadb9e7be4fccc41939b33e055aac
 4--- /dev/null
 5+++ b/tools/install.sh
 6@@ -0,0 +1,24 @@
 7+if [ -d ~/.oh-my-zsh ]
 8+then
 9+  echo "You already have Oh My Zsh installed. You'll need to remove ~/.oh-my-zsh if you want to install"
10+  exit
11+else
12+  echo "Cloning Oh My Zsh..."
13+  /usr/bin/env git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh
14+fi
15+
16+echo "Looking for an existing zsh config..."
17+if [ -f ~/.zshrc ]
18+then
19+  echo "Found ~/.zshrc. Backing up to ~/.zshrc.pre-oh-my-zsh";
20+  cp ~/.zshrc ~/.zshrc.pre-oh-my-zsh;
21+  rm ~/.zshrc;
22+fi
23+
24+echo "Symlinking .zshrc to ~/.oh-my-zsh/"
25+ln -s ~/.oh-my-zsh/zshrc ~/.zshrc
26+
27+echo "Time to change your default shell to zsh!"
28+chsh -s /bin/zsh
29+
30+echo "Hooray! Oh My Zsh has been installed."