-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·43 lines (37 loc) · 841 Bytes
/
setup.sh
File metadata and controls
executable file
·43 lines (37 loc) · 841 Bytes
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
42
43
#!/bin/bash
set -eu
echo '===== add .zshrc ====='
ZSHRC=~/.zshrc
if [ -f "$ZSHRC" ]; then
echo "$ZSHRC exists."
else
ORIGINAL_ZSHRC=`readlink -f .zshrc`
cp "$ORIGINAL_ZSHRC" "$ZSHRC"
fi
echo '===== add .vimrc ====='
VIMRC=~/.vimrc
if [ -f "$VIMRC" ]; then
echo "$VIMRC exists."
else
ORIGINAL_VIMRC=`readlink -f .vimrc`
cp "$ORIGINAL_VIMRC" "$VIMRC"
fi
mkdir -p ~/tmp/vim
echo '===== install packages ====='
brew bundle
cd ~
echo '===== install z command ====='
ZSHD=.zsh.d
if [ -d "$ZSHD" ]; then
echo "$ZSHD exists."
else
git clone https://github.com/rupa/z.git
mv z "$ZSHD"
fi
echo '===== install vim plug ====='
if [ -f ".vim/autoload/plug.vim" ]; then
echo "vim plug exists."
else
curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
fi