Vint is a Vim script Language Lint. The goal to reach for Vint is:
- Highly extensible
- Highly customizable
- High performance
But now, Vint is under development. We hope you develop a policy to help us.
You can install with pip.
$ pip install vim-vint
You can use Vint with scrooloose/syntastic:
let g:syntastic_vim_checkers = ['vint']
Vint will read config files on the following priority order:
- User config:
- e.g.
~/.vintrc.yaml(the filename can be.vintrc.ymlor.vintrc) - Project config:
- e.g.
path/to/proj/.vintrc.yaml(the filename can be.vintrc.ymlor.vintrc) - Command line config:
- e.g.
$ vint --error,$ vint --max-violations 10 - Comment config (highest priority):
- e.g.
" vint: -ProhibitAbbreviationOption +ProhibitSetNoCompatible
You can see all options on Wiki.
The default configuration is defined in default_config.yaml.
You can configure global Vint config by ~/.vintrc.yaml as following:
cmdargs:
# Checking more strictly
severity: style_problem
# Enable coloring
color: true
# Enable Neovim syntax
env:
neovim: true
policies:
# Disable a violation
ProhibitSomethingEvil:
enabled: false
# Enable a violation
ProhibitSomethingBad:
enabled: trueYou can see all policy names on Vint linting policy summary.
You can configure project local Vint config by .vintrc.yaml as
following:
cmdargs:
# Checking more strictly
severity: style_problem
# Enable coloring
color: true
# Enable Neovim syntax
env:
neovim: true
policies:
# Disable a violation
ProhibitSomethingEvil:
enabled: false
# Enable a violation
ProhibitSomethingBad:
enabled: trueYou can see all policy names on Vint linting policy summary.
You can configure linting severity, max errors, ... as following:
$ vint --color --style ~/.vimrc
You can enable/disable linting policies by a comment as following:
" vint: -ProhibitAbbreviationOption
let s:save_cpo = &cpo
set cpo&vim
" vint: +ProhibitAbbreviationOption
" do something...
" vint: -ProhibitAbbreviationOption
let &cpo = s:save_cpo
unlet s:save_cpoThis syntax is: " vint: [+-]<PolicyName> [+-]<PolicyName> ....
You can see all policy names on Vint linting policy summary.