-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.sh
executable file
·85 lines (85 loc) · 3.61 KB
/
setup.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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
#/bin/sh
# install vim
sudo apt-get -y remove vim vim-runtime gvim
# install deps for manually building vim
sudo apt-get -y install liblua5.1-dev luajit libluajit-5.1 python-dev ruby-dev libperl-dev libncurses5-dev libatk1.0-dev libx11-dev libxpm-dev libxt-dev python2.7 python3.6 python-pip python3-pip libgnome2-dev libgnomeui-dev libgtk2.0-dev libbonoboui2-dev libcairo2-dev
sudo mkdir /usr/include/lua5.1/include
sudo cp /usr/include/lua5.1/* /usr/include/lua5.1/include
git clone https://github.com/vim/vim.git
cd vim
sudo make uninstall # remove previous custom builds if any
# pay attention here check if directories are correct
make distclean
./configure --with-features=huge \
--enable-multibyte \
--enable-rubyinterp=yes \
--enable-pythoninterp=yes \
--enable-python3interp=yes \
--with-python3-config-dir=/usr/lib/python3.6/config-3.6m-x86_64-linux-gnu \
--enable-perlinterp=yes \
--enable-luainterp=yes \
--with-luajit \
--with-lua-prefix=/usr/include/lua5.1 \
--enable-gui=auto \
--enable-largefile \
--enable-fail-if-missing \
--enable-cscope \
--prefix=/usr/local
sudo make VIMRUNTIMEDIR=/usr/local/share/vim/vim81
sudo make install
cd ..
sudo rm -rf vim
#install neovim-bridge for the autocomplete
sudo apt-get install -y python3-setuptools
pip install wheel
pip install neovim
go get -u github.com/mdempsky/gocode
# install and change to zsh
sudo apt-get -y install zsh
chsh -s $(which zsh)
# zsh plugin manager
sh -c "$(wget https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O -)"
git clone git://github.com/zsh-users/zaw.git ~/.oh-my-zsh/custom/plugins/zaw
git clone https://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting
git clone https://github.com/JamesKovacs/zsh_completions_mongodb.git ~/.oh-my-zsh/custom/plugins/mongodb
# install tmux
sudo apt-get -y install curl xclip python-pygments
TMUX_VERSION=2.5
sudo apt-get -y remove tmux
sudo apt-get -y install wget tar libevent-dev libncurses-dev
wget https://github.com/tmux/tmux/releases/download/${TMUX_VERSION}/tmux-${TMUX_VERSION}.tar.gz
tar xf tmux-${TMUX_VERSION}.tar.gz
rm -f tmux-${TMUX_VERSION}.tar.gz
cd tmux-${TMUX_VERSION}
sudo make uninstall
./configure
make
sudo make install
cd -
sudo rm -rf /usr/local/src/tmux-*
sudo mv tmux-${TMUX_VERSION} /usr/local/src
# tmux plugin manager
git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm
git clone https://github.com/tmux-plugins/tmux-sensible ~/.tmux/plugins/tmux-sensible
# install tmux nord theme
git clone https://github.com/arcticicestudio/nord-tmux ~/.tmux/plugins/nord-tmux
# vim plugin manager
mkdir -p ~/.vim/autoload ~/.vim/bundle && curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim
# install vim fonts
# note: do not forget to set terminal emulator font to DroidSansMono
mkdir ~/.local/share/fonts && cd ~/.local/share/fonts && curl -fLo "Droid Sans Mono for Powerline Nerd Font Complete.otf" https://github.com/ryanoasis/nerd-fonts/raw/master/patched-fonts/DroidSansMono/complete/Droid%20Sans%20Mono%20Nerd%20Font%20Complete.otf
# install vim-tagbar deps
sudo apt-get -y install exuberant-ctags
# simlink and proper files
rm ~/.vimrc
rm ~/.tmux.conf
rm ~/.zshrc
rm ~/vim-plugins
ln -s `pwd`/vim-plugins ~/vim-plugins
ln -s `pwd`/.vimrc ~/.vimrc
ln -s `pwd`/.tmux.conf ~/.tmux.conf
ln -s `pwd`/.zshrc ~/.zshrc
touch .zsh_private
# needed for the vim 8+ persistent undo history
mkdir ~/.vim/undo