Skip to content

Commit

Permalink
update vimplus install.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
chxuan committed Sep 18, 2018
1 parent 4130d68 commit 80169dc
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ An automatic configuration program for vim
- **`安装vimplus会经常失败,安装了几次都不成功!!!`**
vimplus安装时需要访问外国网站,由于网络原因,可能会失败,安装成功也要1个多小时,ycm插件有200M左右,下载比较耗时,这里有下载好的[YouCompleteMe.tar.gz][37]文件,下载后解压到~/.vim/plugged/目录,并进入YouCompleteMe目录执行`./install.py --clang-completer`即可安装。
vimplus安装时需要访问外国网站,由于网络原因,可能会失败,安装成功也要1个多小时,ycm插件有200M左右,下载比较耗时,这里有下载好的[YouCompleteMe.tar.gz][37]文件,下载后解压到~/.vim/plugged/目录,并进入YouCompleteMe目录,linux用户执行`./install.py --clang-completer`,mac用户执行`./install.py --clang-completer --system-libclang`即可安装。
- **`使用第三方库时怎么让ycm补全第三方库API?`**
Expand Down
15 changes: 11 additions & 4 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -182,13 +182,20 @@ function install_vim_plugin()
vim -c "PlugInstall" -c "q" -c "q"
}

# 编译ycm插件
function compile_ycm()
# linux编译ycm插件
function compile_ycm_on_linux()
{
cd ~/.vim/plugged/YouCompleteMe
./install.py --clang-completer
}

# mac编译ycm插件
function compile_ycm_on_mac()
{
cd ~/.vim/plugged/YouCompleteMe
./install.py --clang-completer --system-libclang
}

# 打印logo
function print_logo()
{
Expand Down Expand Up @@ -217,7 +224,7 @@ function install_vimplus_on_mac()
install_fonts_on_mac
download_vim_plug
install_vim_plugin
compile_ycm
compile_ycm_on_mac
print_logo
}

Expand All @@ -227,7 +234,7 @@ function begin_install_vimplus()
install_fonts_on_linux
download_vim_plug
install_vim_plugin
compile_ycm
compile_ycm_on_linux
print_logo
}

Expand Down

0 comments on commit 80169dc

Please sign in to comment.