尝试在vim中为yuml文件类型设置makeprg时,手动工作,而不是在vimrc中工作
我正在尝试使以下条目在我的.vimrc中工作:尝试在vim中为yuml文件类型设置makeprg时,手动工作,而不是在vimrc中工作,vim,Vim,我正在尝试使以下条目在我的.vimrc中工作: autocmd FileType yuml set makeprg=yuml\ -i\ %\ -o\ %<\.pdf\ -f\ pdf\ &\ sleep\ 1\;\ evince\ %<.pdf\ & 我不知道到底出了什么问题,但在脚本化autocmd中,我会跳过转义问题,使用:let: :autocmd FileType yuml let &makeprg = 'yuml -i % -o %<.pd
autocmd FileType yuml set makeprg=yuml\ -i\ %\ -o\ %<\.pdf\ -f\ pdf\ &\ sleep\ 1\;\ evince\ %<.pdf\ &
我不知道到底出了什么问题,但在脚本化autocmd中,我会跳过转义问题,使用
:let
:
:autocmd FileType yuml let &makeprg = 'yuml -i % -o %<.pdf -f pdf & sleep 1; evince %<.pdf &'
:autocmd FileType yuml let&makeprg='yuml-i%-o%我不知道到底是什么错误,但在脚本化的autocmd中,我会跳过转义问题,而使用:let
:
:autocmd FileType yuml let &makeprg = 'yuml -i % -o %<.pdf -f pdf & sleep 1; evince %<.pdf &'
:autocmd FileType yuml let&makeprg='yuml-i%-o%谢谢你让我走上了正确的道路,我忘了定义文件类型。所以基本上我只需要定义:au BufRead,BufNewFile*.yuml set filetype=yuml谢谢你让我走上了正确的道路,我忘了定义文件类型。所以基本上我要定义的就是:au BufRead,BufNewFile*.yuml set filetype=yuml
:autocmd FileType yuml let &makeprg = 'yuml -i % -o %<.pdf -f pdf & sleep 1; evince %<.pdf &'