Merge branch 'master' into dev

This commit is contained in:
Chiel ten Brinke 2015-10-28 13:57:45 +01:00
commit 10e80a996c
2 changed files with 8 additions and 3 deletions

View File

@ -195,6 +195,7 @@ else:
# It is not entirely clear when and why that happens.
# However, extra newlines are almost never required, while there are linters that complain
# about superfluous newlines, so we remove one empty newline at the end of the file.
stdoutdata = stdoutdata.decode('utf-8')
if stdoutdata[-1] == os.linesep:
stdoutdata = stdoutdata[:-1]

View File

@ -4,12 +4,16 @@
" Python
if !exists('g:formatdef_autopep8')
let g:formatdef_autopep8 = '"autopep8 - --range ".a:firstline." ".a:lastline." ".(&textwidth ? "--max-line-length=".&textwidth : "")'
if !exists('g:formatdef_autopep8_1_0_3')
let g:formatdef_autopep8_1_0_3 = '"autopep8 - --range ".a:firstline." ".a:lastline." ".(&textwidth ? "--max-line-length=".&textwidth : "")'
endif
if !exists('g:formatdef_autopep8_1_2_1')
let g:formatdef_autopep8_1_2_1 = '"autopep8 - --line-range ".a:firstline." ".a:lastline." ".(&textwidth ? "--max-line-length=".&textwidth : "")'
endif
if !exists('g:formatters_python')
let g:formatters_python = ['autopep8']
let g:formatters_python = ['autopep8_1_0_3', 'autopep8_1_2_1']
endif