-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsetup.sh
41 lines (36 loc) · 1002 Bytes
/
setup.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/usr/bin/env sh
# Install Homebrew
if ! command -v brew > /dev/null 2>&1; then
echo "Installing Homebrew..."
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
else
echo "Homebrew is already available... skipping the installation"
echo "Updating Homebrew..."
brew update
fi
# Install zsh
if command -v `zsh --version` > /dev/null 2>&1; then
echo "Installing Zsh..."
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
# Make Zsh default shell
chsh -s /usr/local/bin/zsh
else
echo "Zsh is already available...skipping the installation"
echo "Upgrading Zsh..."
upgrade_oh_my_zsh
fi
# Main installation
if [ -d ~/.setup-osx ]; then
cd ~/.setup-osx
git pull
else
git clone https://github.com/nadidami/setup-osx.git ~/.setup-osx
cd ~/.setup-osx
fi
sh install_brews.sh
sh install_casks.sh
sh install_postgres.sh
sh install_ruby.sh
sh setup_zsh.sh
sh setup_git.sh
sh setup_vim.sh