X-Git-Url: https://git.madduck.net/etc/vim.git/blobdiff_plain/2aa5028219a5192be46a3d4eb3a7c93d113e9040..fc04a1123eb6b2aa855eddfcee6da7a04ca0408c:/ftplugin/python_flake8.vim diff --git a/ftplugin/python_flake8.vim b/ftplugin/python_flake8.vim index e3b3c61..0b386c7 100644 --- a/ftplugin/python_flake8.vim +++ b/ftplugin/python_flake8.vim @@ -27,6 +27,11 @@ if exists("g:flake8_max_line_length") let s:flake8_max_line_length=" --max-line-length=".g:flake8_max_line_length endif +let s:flake8_max_complexity="" +if exists("g:flake8_max_complexity") + let s:flake8_max_complexity=" --max-complexity=".g:flake8_max_complexity +endif + if !exists("*Flake8()") function Flake8() if !executable(s:flake8_cmd) @@ -48,7 +53,7 @@ if !exists("*Flake8()") " perform the grep itself let &grepformat="%f:%l:%c: %m\,%f:%l: %m" - let &grepprg=s:flake8_cmd.s:flake8_ignores.s:flake8_max_line_length + let &grepprg=s:flake8_cmd.s:flake8_ignores.s:flake8_max_line_length.s:flake8_max_complexity silent! grep! % " restore grep settings