Skip to content

Commit 686c7cc

Browse files
Alexander Zhanggerw
authored andcommitted
Add quotes to file names in compile rules
1 parent 935a0fa commit 686c7cc

File tree

1 file changed

+10
-10
lines changed
  • ftplugin/latex-suite

1 file changed

+10
-10
lines changed

ftplugin/latex-suite/texrc

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -104,24 +104,24 @@ TexLet g:Tex_MultipleCompileFormats = 'dvi'
104104
" but it is known that it can sometimes give different results in the output,
105105
" so use it with care. The '-file-line-error' flag helps sanitize LaTeX error
106106
" messages for processing by Vim.
107-
TexLet g:Tex_CompileRule_dvi = 'latex -interaction=nonstopmode -file-line-error-style $*'
107+
TexLet g:Tex_CompileRule_dvi = 'latex -interaction=nonstopmode -file-line-error-style "$*"'
108108
TexLet g:Tex_EscapeChars = '{}\'
109109

110-
TexLet g:Tex_CompileRule_ps = 'dvips -Ppdf -o $*.ps $*.dvi'
110+
TexLet g:Tex_CompileRule_ps = 'dvips -Ppdf -o "$*.ps" "$*.dvi"'
111111

112112
" ways to generate pdf files. there are soo many...
113113
" NOTE: pdflatex generates the same output as latex. therefore quickfix is
114114
" possible.
115115
" Synctex is now supported by pdflatex.
116-
TexLet g:Tex_CompileRule_pdf = 'pdflatex -synctex=1 -interaction=nonstopmode -file-line-error-style $*'
116+
TexLet g:Tex_CompileRule_pdf = 'pdflatex -synctex=1 -interaction=nonstopmode -file-line-error-style "$*"'
117117

118-
" TexLet g:Tex_CompileRule_pdf = 'ps2pdf $*.ps'
119-
" TexLet g:Tex_CompileRule_pdf = 'dvipdfm $*.dvi'
120-
" TexLet g:Tex_CompileRule_pdf = 'dvipdf $*.dvi'
118+
" TexLet g:Tex_CompileRule_pdf = 'ps2pdf "$*.ps"'
119+
" TexLet g:Tex_CompileRule_pdf = 'dvipdfm "$*.dvi"'
120+
" TexLet g:Tex_CompileRule_pdf = 'dvipdf "$*.dvi"'
121121

122-
TexLet g:Tex_CompileRule_html = 'latex2html $*.tex'
122+
TexLet g:Tex_CompileRule_html = 'latex2html "$*.tex"'
123123

124-
TexLet g:Tex_CompileRule_bib = g:Tex_BibtexFlavor . ' $*'
124+
TexLet g:Tex_CompileRule_bib = g:Tex_BibtexFlavor . ' "$*"'
125125

126126
" Set Tex_UseMakefile to 0 if you want to ignore the presence of a Makefile
127127
" when deciding how to compile
@@ -193,7 +193,7 @@ endif
193193
" Suppose you have a latex->html converter which converts a file say foo.tex
194194
" to a file foo/index.html. Then you would use:
195195
"
196-
" let g:Tex_ViewRuleComplete_html = 'MozillaFirebird $*/index.html &'
196+
" let g:Tex_ViewRuleComplete_html = 'MozillaFirebird "$*/index.html" &'
197197
"
198198
" Doing something like this would not be possible using Tex_ViewRule_html
199199
TexLet g:Tex_ViewRuleComplete_dvi = ''
@@ -237,7 +237,7 @@ TexLet g:Tex_BibtexFlavor = 'bibtex'
237237

238238
" specifies the MakeIndedx flavor and if necessary options. $* will be
239239
" replaced by the *root* of the main file name. See above.
240-
TexLet g:Tex_MakeIndexFlavor = 'makeindex $*.idx'
240+
TexLet g:Tex_MakeIndexFlavor = 'makeindex "$*.idx"'
241241

242242
" By default the program described by g:Tex_Flavor above is called with the
243243
" flags '--src-specials --interaction=nonstopmode'. If your particular version

0 commit comments

Comments
 (0)