-
Notifications
You must be signed in to change notification settings - Fork 5
/
setup
39 lines (35 loc) · 1.22 KB
/
setup
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
#!/usr/bin/env bash
function setup_dotfiles() {
cd $HOME && \
echo -e "\nPreparing your new Mac for awesomeness!!\n\n"
which -s brew
if [[ $? != 0 ]] ; then
# Install Homebrew
echo "Homebrew not found installing it for you..."
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
else
echo 'Updating Homebrew...'
brew update --verbose >/dev/null 2>&1
fi
which -s git
if [[ $? != 0 ]] ; then
# Install Homebrew
echo "Git is not installed. Installing it for you.."
brew install git
else
echo 'Cloning nmrony/dotfiles repository in ~/.dotfiles'
git clone https://github.com/nmrony/dotfiles $HOME/.dotfiles
fi
cd $HOME/.dotfiles && \
echo '✨✨✨ Making your Terminal WOWsome ✨✨✨' && \
sh $HOME/.dotfiles/bootstrap.sh && \
# Intentionally mixing tab and space here for pretty output
cat <<-EOF
There is a brew.sh and .macos script which makes your Mac
more friendly for development. I highly recommend to take
a look into those files. Please do CHECK and ADD/EDIT those
files before running.
INFORMATION: Please create .extra in you HOME directory to override or for customizing configurations
EOF
}
setup_dotfiles