asyncrun.vim
asyncrun.vim copied to clipboard
Encoding filenames
Hello,
I use GVim (v8) on Windows. AsyncRun works fine with only ascii characters in filenames.
With non ascii characters, I have problems (gcc in this example, but same with pdflatex):
:AsyncRun gcc -Wall -o "$(VIM_FILENOEXT)" "$(VIM_FILENAME)"
output in quickfix:
|| [gcc -Wall -o "file with é in name" "file with é in name.c"]
|| gcc: error: file with +® in name.c: No such file or directory
|| gcc: fatal error: no input files
|| compilation terminated.
|| [Finished in 0 seconds with code 1]
The following one works fine (but kind of lose the interest of AsyncRun):
:AsyncRun -mode=2 gcc -Wall -o "$(VIM_FILENOEXT)" "$(VIM_FILENAME)"
output in window vimrun.exe:
C:\windows\system32\cmd.exe /c (gcc -Wall -o ^"file with é in name^" ^"file with é in name.c^")
Hit any key to close this window...
I modified encoding, termencoding, g:asyncrun_encs = 'utf8' or latin1 or my current chcp cp850 etc. without more success.
Where am I wrong?
Is the problem related to issue #131?
don't modify any of encoding or termencoding. try:
let g:asyncrun_encs='cp850'
Ok, I removed encoding and termencoding, and only left the line you suggested. But it only changed the representation of the "bad" character in the quickfix output:
|| [gcc -Wall -o "file with é in name" "file with é in name.c"]
|| gcc: error: file with + in name.c: No such file or directory
|| gcc: fatal error: no input files
|| compilation terminated.
|| [Finished in 0 seconds with code 1]
Late answer, but letting only set encoding=utf-8 and let g:asyncrun_encs='cp850' in vimrc made the thing, so that's fine, the issue can be closed.