forked from tobinvanpelt/dotfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit_osx
More file actions
executable file
·73 lines (59 loc) · 1.62 KB
/
init_osx
File metadata and controls
executable file
·73 lines (59 loc) · 1.62 KB
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
62
63
64
65
66
67
68
69
70
71
72
73
#!/bin/bash
# install brew deps
brew update
brew install \
zsh \
python3 \
git \
tmux \
cmake \
fzf \
ripgrep \
bat \
neovim \
pre-commit \
reattach-to-user-namespace \
zsh-history-substring-search \
direnv \
go \
coursier \
node \
yarn
# change to zsh
sudo chsh -s /bin/zsh
rm -f ~/.profile ~/.bash_profile ~/.zprofile ~/.zshrc
mv ~/.profile ~/.profile.bak 2>/dev/null
ln -s ~/.dot/profile.osx ~/.profile
ln -s ~/.dot/zprofile ~/.zprofile
ln -s ~/.dot/zshrc ~/.zshrc
ln -s ~/.dot/tmux.osx ~/.tmux.conf
ln -s ~/.dot/gitconfig ~/.gitconfig
ln -s ~/.dot/gitignore ~/.gitignore
ln -s ~/.dot/ipython_config.py ~/.ipython/profile_default/ipython_config.py
# setup local env variables file
touch ~/.env.local
# neovim config (lazy.nvim bootstraps itself via init.lua)
mkdir -p ~/.config/nvim/lua
ln -sf ~/.dot/init.lua ~/.config/nvim/init.lua
ln -sf ~/.dot/goconfig.lua ~/.config/nvim/lua/goconfig.lua
# first launch triggers lazy.nvim to install all plugins
nvim --headless "+Lazy! sync" +qa
yarn global add \
prettier \
typescript \
typescript-language-server \
pyright
# rust + cargo
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source "$HOME/.cargo/env"
# optional: legacy vim-plug setup
read -p "Install vim-plug and legacy vim config? (y/N) " install_vimplug
if [[ "$install_vimplug" =~ ^[Yy]$ ]]; then
curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
ln -s ~/.dot/vim/ ~/.vim
ln -s ~/.dot/vimrc ~/.vimrc
ln -s ~/.dot/gvimrc ~/.gvimrc
cp -r colors ~/.vim/
nvim +'PlugInstall --sync' +qa
fi