-
Notifications
You must be signed in to change notification settings - Fork 0
/
install
executable file
·35 lines (26 loc) · 1.55 KB
/
install
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
#!/usr/bin/env bash
set -e
CONFIG="install.conf.yaml"
DOTBOT_DIR="dotbot"
OHMYZSH_DIR=".oh-my-zsh/custom/themes/powerlevel10k"
DOTBOT_BIN="bin/dotbot"
BASEDIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
cd "${BASEDIR}"
git -C "${DOTBOT_DIR}" submodule sync --quiet --recursive
git submodule update --init --recursive "${DOTBOT_DIR}"
git -C "${OHMYZSH_DIR}" submodule sync --quiet --recursive
git submodule update --init --recursive "${OHMYZSH_DIR}"
# rm -rf $HOME/.oh-my-zsh
rm -rf $HOME/.zshrc.pre-oh-my-zsh*
which -s brew || yes '' | /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
[[ -d "$HOME/.oh-my-zsh" ]] || bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended
brew install findutils
gxargs -r brew tap -v < <(comm -23 ${BASEDIR}/packages/homebrew-tap <(brew tap)) || gxargs -r brew tap <${BASEDIR}/packages/homebrew-tap
gxargs -r brew install --formula -v < <(comm -23 ${BASEDIR}/packages/homebrew <(brew list --formula -1)) || gxargs -r brew install --formula <${BASEDIR}/packages/homebrew
gxargs -r brew install --cask -v < <(comm -23 ${BASEDIR}/packages/homebrew-cask <(brew list --cask -1))
GO111MODULE=on gxargs go get -u -v <${BASEDIR}/packages/go
gxargs -r cargo install <${BASEDIR}/packages/cargo
"${BASEDIR}/${DOTBOT_DIR}/${DOTBOT_BIN}" -d "${BASEDIR}" -c "${CONFIG}" "${@}"
tmux new-session -d -s setup-tmux 'nvim +Tmuxline +"TmuxlineSnapshot $HOME/.vim/plugged/tmuxline.vim/tmux.conf" +qa'
pyenv install --skip-existing 3.8.5
pyenv global 3.8.5