-
Notifications
You must be signed in to change notification settings - Fork 0
/
install.sh
executable file
·37 lines (27 loc) · 810 Bytes
/
install.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
#!/usr/bin/env bash
set -eEuo pipefail
export ROOTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
# load helper functions
source ${ROOTDIR}/lib.sh
# create localbin
mkdir -p "${LOCALBIN}"
# setup simple links
if ! is_mac; then
safelink "${HOME}/bin" "${ROOTDIR}/bin"
fi
# link .config dirs
for x in ${ROOTDIR}/config/*; do
if [[ -d "${x}" ]]; then
safelink "${HOME}/.config/$(basename ${x})" "${x}"
fi
done
# install dotfiles
safelink "${HOME}/.Xresources" "${ROOTDIR}/config/xresources"
safelink "${HOME}/.xsessionrc" "${ROOTDIR}/config/xsessionrc"
safelink "${HOME}/.zshrc" "${ROOTDIR}/config/zsh/zshrc"
# install tools
source ${ROOTDIR}/tools.sh
# setup gitconfig
source ${ROOTDIR}/gitconfig.sh
# install wallpapers
safelink "${HOME}/.wallpapers" "${ROOTDIR}/wallpapers"