-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsymlink.sh
61 lines (52 loc) · 1.1 KB
/
symlink.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#!/usr/bin/env bash
set -eu
if [ ! -e "$HOME/.zshrc" ]
then
ln -s $PWD/.zshrc $HOME/.zshrc
else
echo "$HOME/.zshrc already exists" >&2
fi
if [ ! -e "$HOME/.vimrc" ]
then
ln -s $PWD/.vimrc $HOME/.vimrc
else
echo "$HOME/.vimrc already exists" >&2
fi
if [ ! -e "$HOME/.tmux.conf" ]
then
ln -s $PWD/.tmux.conf $HOME/.tmux.conf
else
echo "$HOME/.tmux.conf already exists" >&2
fi
if [ ! -e "$HOME/.gitconfig" ]
then
ln -s $PWD/git/.gitconfig $HOME/.gitconfig
else
echo "$HOME/.gitconfig already exists" >&2
fi
if [ ! -e "$HOME/.gitignore" ]
then
ln -s $PWD/git/.gitignore $HOME/.gitignore
else
echo "$HOME/.gitignore already exists" >&2
fi
if [ ! -e "$HOME/.ssh/config" ]
then
mkdir -p $HOME/.ssh
ln -s $PWD/ssh/config $HOME/.ssh/config
else
echo "$HOME/.ssh/config already exists" >&2
fi
if [ ! -e "$HOME/.iterm" ]
then
ln -s $PWD/iterm $HOME/.iterm
else
echo "$HOME/.iterm already exists" >&2
fi
if [ ! -e "$HOME/.gnupg/gpg-agent.conf" ]
then
mkdir -p $HOME/.gnupg
ln -s $PWD/gnupg/gpg-agent.conf $HOME/.gnupg/gpg-agent.conf
else
echo "$HOME/.gnupg/gpg-agent.conf already exists" >&2
fi