mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-01-23 22:30:04 +08:00
24 lines
597 B
Plaintext
24 lines
597 B
Plaintext
|
#!/usr/bin/env bash
|
||
|
|
||
|
# Change to directory of this script.
|
||
|
cd "${0%/*}"
|
||
|
|
||
|
# Look for existing vader installation.
|
||
|
vader=( ${HOME}/.vim/*bundle*/vader*/plugin/vader.vim )
|
||
|
if [ -f ${vader[0]} ]; then
|
||
|
# Remove "plugin/vader.vim" suffix.
|
||
|
vader=${vader[0]%/*/*}
|
||
|
fi
|
||
|
|
||
|
if [ -d $vader ]; then
|
||
|
[[ ! -L vader.vim ]] && ln -s $vader vader.vim
|
||
|
else
|
||
|
git clone https://github.com/junegunn/vader.vim.git
|
||
|
fi
|
||
|
|
||
|
# Provide viminfo during tests, remove it on exit.
|
||
|
cp viminfo viminfo.tmp
|
||
|
trap "{ rm viminfo.tmp; }" EXIT
|
||
|
|
||
|
TERM=ansi HOME=/dev/null vim -XNu vimrc -i viminfo.tmp -c 'Vader! feature/*.vader'
|