From: Danilo Bargen Date: Fri, 13 Jul 2012 12:07:27 +0000 (+0200) Subject: Added option to configure max_line_length X-Git-Url: https://git.madduck.net/etc/vim.git/commitdiff_plain/2aa5028219a5192be46a3d4eb3a7c93d113e9040?ds=sidebyside Added option to configure max_line_length --- diff --git a/ftplugin/python_flake8.vim b/ftplugin/python_flake8.vim index 52d9fdf..e3b3c61 100644 --- a/ftplugin/python_flake8.vim +++ b/ftplugin/python_flake8.vim @@ -22,6 +22,11 @@ if exists("g:flake8_ignore") let s:flake8_ignores=" --ignore=".g:flake8_ignore endif +let s:flake8_max_line_length="" +if exists("g:flake8_max_line_length") + let s:flake8_max_line_length=" --max-line-length=".g:flake8_max_line_length +endif + if !exists("*Flake8()") function Flake8() if !executable(s:flake8_cmd) @@ -43,7 +48,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 + let &grepprg=s:flake8_cmd.s:flake8_ignores.s:flake8_max_line_length silent! grep! % " restore grep settings