diff --git a/autoload/neomake.vim b/autoload/neomake.vim index 47ec63af159016..464b903a2cff03 100644 --- a/autoload/neomake.vim +++ b/autoload/neomake.vim @@ -207,8 +207,9 @@ function! neomake#Make(options) abort let tempfile = 1 let tempsuffix = '.'.neomake#utils#Random().'.neomake.tmp' let makepath .= tempsuffix - " TODO Make this cross platform - silent exe 'w !cat > '.shellescape(makepath) + let escapedpath = fnameescape(makepath) + noautocmd silent exe 'keepalt w! '.escapedpath + noautocmd silent exe 'bwipeout '.escapedpath call neomake#utils#LoudMessage('Neomake: wrote temp file '.makepath) endif endif