Ⅰ. 插件描述
Prefer local eslint over global with neomakeⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'benjie/neomake-local-eslint-vim'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'benjie/neomake-local-eslint-vim'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'benjie/neomake-local-eslint-vim'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/benjie/neomake-local-eslint.vim
Ⅳ. 文档说明
# local-npm-bin.vim
Prefer local repo install of eslint, flow, etc over global install
Thanks to @mtscout6 for the syntastic version as
inspiration, and @ohjames for performance
improvements.
Installation Instructions
Using vim plugged you just need to add the following to your vimrc:
Plug 'benjie/local-npm-bin.vim'Then open vim and run :PlugInstall
Contributing
The following enable local eslint for neomake, and local flow forvim-flow. Anything this simple to add equivalent variables for other plugins
would be welcome.
let b:neomake_javascript_eslint_exe = GetNpmBin('eslint')
let g:flow#flowpath = GetNpmBin('flow')If you've got other thoughts, PRs are welcome but I'm trying to keep this
really simple - so nothing too complex!
Inspired By
Inspired by http://blog.pixelastic.com/2015/10/05/use-local-eslint-in-syntastic/