Merge pull request #251 from Chiel92/write-read-viminfo

Write and read from the viminfo before and after formatting.
This commit is contained in:
Chiel ten Brinke 2018-10-12 18:01:51 +02:00 committed by GitHub
commit 4b65df2444
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -297,7 +297,7 @@ endfunction
" Create a command for formatting the entire buffer
" Save and recall window state to prevent vim from jumping to line 1
command! -nargs=? -range=% -complete=filetype -bar Autoformat let winview=winsaveview()|<line1>,<line2>call s:TryAllFormatters(<f-args>)|call winrestview(winview)
command! -nargs=? -range=% -complete=filetype -bar Autoformat let winview=winsaveview()|wviminfo|<line1>,<line2>call s:TryAllFormatters(<f-args>)|call winrestview(winview)|rviminfo
" Functions for iterating through list of available formatters