/ build-vim.sh
build-vim.sh
 1  #! /usr/bin/env sh
 2  
 3  ################################################################################
 4  # build my custom vim environment from pure os 
 5  ################################################################################
 6  
 7  # NATIVE_INSTALL='yes | sudo pacman -Sy'
 8  # need export NATIVE_INSTALL before run the script
 9  #if [ -z "$NATIVE_INSTALL" ]; then
10  #	echo 'error : Undefined `NATIVE_INSTALL`!'
11  #	exit 1
12  #fi
13  
14  if command -v curl > /dev/null ; then
15  	echo 'Curl is satisfied!'
16  else
17  	eval $NATIVE_INSTALL curl
18  fi
19  
20  # reduct vimrc
21  curl -fLo $HOME/.vimrc \
22      https://raw.githubusercontent.com/Shylock-Hg/config.linux/master/.vimrc
23  
24  # vim-plug
25  curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
26      https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
27  
28  # install and configure `pathogen`, `git`, `vim` and `viman`
29  # curl https://raw.githubusercontent.com/Shylock-Hg/viman/master/install.sh | sh
30  
31  #if command -v viman > /dev/null ; then
32  #	echo 'Viman is in PATH!'
33  #else
34  #	export PATH="$PATH:$HOME/.local/bin"
35  #fi
36  
37  #cp ./viman/.viman.yml $HOME/.viman.yml
38  #if curl https://raw.githubusercontent.com/Shylock-Hg/config.linux/master/viman/.viman.yml -o $HOME/.viman.yml ; then
39  #        viman -Sf $HOME/.viman.yml
40  #fi
41