Svn is not installed on the Windows computers on which I use the
vim-latex suite, so I attempted to get the latest versions on /trunk
by downloading the tarball using the "Download GNU tarball" link on
this page:
http://vim-latex.svn.sourceforge.net/viewvc/vim-latex/trunk/vimfiles/
I discovered several places in various plugin files where other
files were sourced without properly accounting for spaces in path
names. I fixed each of these by adding calls to fnameescape().
Patches are attached.
Regards,
Gary
*** envmacros.vim.orig Mon Jun 1 23:33:37 2009
--- envmacros.vim Mon Jun 1 23:04:23 2009
***************
*** 10,16 ****
finish
endif
! exe 'so '.expand('<sfile>:p:h').'/wizardfuncs.vim'
nmap <silent> <script> <plug> i
imap <silent> <script> <C-o><plug> <Nop>
--- 10,16 ----
finish
endif
! exe 'so '.fnameescape(expand('<sfile>:p:h').'/wizardfuncs.vim')
nmap <silent> <script> <plug> i
imap <silent> <script> <C-o><plug> <Nop>
*** main.vim.orig Mon Jun 1 23:33:27 2009
--- main.vim Mon Jun 1 23:02:58 2009
***************
*** 29,35 ****
" set up personal defaults.
runtime ftplugin/tex/texrc
" set up global defaults.
! exe "so ".s:path.'/texrc'
" }}}
--- 29,35 ----
" set up personal defaults.
runtime ftplugin/tex/texrc
" set up global defaults.
! exe "so ".fnameescape(s:path.'/texrc')
" }}}
***************
*** 805,843 ****
" }}}
" source texproject.vim before other files
! exe 'source '.s:path.'/texproject.vim'
" source all the relevant files.
! exe 'source '.s:path.'/texmenuconf.vim'
! exe 'source '.s:path.'/envmacros.vim'
! exe 'source '.s:path.'/elementmacros.vim'
" source utf-8 or plain math menus
if exists("g:Tex_UseUtfMenus") && g:Tex_UseUtfMenus != 0 && has("gui_running")
! exe 'source '.s:path.'/mathmacros-utf.vim'
else
! exe 'source '.s:path.'/mathmacros.vim'
endif
! exe 'source '.s:path.'/multicompile.vim'
! exe 'source '.s:path.'/compiler.vim'
! exe 'source '.s:path.'/folding.vim'
! exe 'source '.s:path.'/templates.vim'
! exe 'source '.s:path.'/custommacros.vim'
! exe 'source '.s:path.'/bibtex.vim'
" source advanced math functions
if g:Tex_AdvancedMath == 1
! exe 'source '.s:path.'/brackets.vim'
! exe 'source '.s:path.'/smartspace.vim'
endif
if g:Tex_Diacritics != 0
! exe 'source '.s:path.'/diacritics.vim'
endif
! exe 'source '.s:path.'/texviewer.vim'
! exe 'source '.s:path.'/version.vim'
"
==============================================================================
" Finally set up the folding, options, mappings and quit.
--- 805,843 ----
" }}}
" source texproject.vim before other files
! exe 'source '.fnameescape(s:path.'/texproject.vim')
" source all the relevant files.
! exe 'source '.fnameescape(s:path.'/texmenuconf.vim')
! exe 'source '.fnameescape(s:path.'/envmacros.vim')
! exe 'source '.fnameescape(s:path.'/elementmacros.vim')
" source utf-8 or plain math menus
if exists("g:Tex_UseUtfMenus") && g:Tex_UseUtfMenus != 0 && has("gui_running")
! exe 'source '.fnameescape(s:path.'/mathmacros-utf.vim')
else
! exe 'source '.fnameescape(s:path.'/mathmacros.vim')
endif
! exe 'source '.fnameescape(s:path.'/multicompile.vim')
! exe 'source '.fnameescape(s:path.'/compiler.vim')
! exe 'source '.fnameescape(s:path.'/folding.vim')
! exe 'source '.fnameescape(s:path.'/templates.vim')
! exe 'source '.fnameescape(s:path.'/custommacros.vim')
! exe 'source '.fnameescape(s:path.'/bibtex.vim')
" source advanced math functions
if g:Tex_AdvancedMath == 1
! exe 'source '.fnameescape(s:path.'/brackets.vim')
! exe 'source '.fnameescape(s:path.'/smartspace.vim')
endif
if g:Tex_Diacritics != 0
! exe 'source '.fnameescape(s:path.'/diacritics.vim')
endif
! exe 'source '.fnameescape(s:path.'/texviewer.vim')
! exe 'source '.fnameescape(s:path.'/version.vim')
"
==============================================================================
" Finally set up the folding, options, mappings and quit.
***************
*** 921,927 ****
let g:Tex_completion_explorer = ','
" Mappings defined in package files will overwrite all other
! exe 'source '.s:path.'/packages.vim'
"
==============================================================================
" These functions are used to immitate certain operating system type functions
--- 921,927 ----
let g:Tex_completion_explorer = ','
" Mappings defined in package files will overwrite all other
! exe 'source '.fnameescape(s:path.'/packages.vim')
"
==============================================================================
" These functions are used to immitate certain operating system type functions
*** texmenuconf.vim.orig Mon Jun 1 23:33:00 2009
--- texmenuconf.vim Mon Jun 1 22:35:53 2009
***************
*** 89,95 ****
if a:type == 'math'
if a:action == 1
let g:Tex_MathMenus = 1
! exe 'so '.s:path.'/mathmacros.vim'
exe 'amenu disable '.menuloc.'Add\ Math\ Menu'
exe 'amenu enable '.menuloc.'Remove\ Math\ Menu'
elseif a:action == 0
--- 89,95 ----
if a:type == 'math'
if a:action == 1
let g:Tex_MathMenus = 1
! exe 'so '.fnameescape(s:path.'/mathmacros.vim')
exe 'amenu disable '.menuloc.'Add\ Math\ Menu'
exe 'amenu enable '.menuloc.'Remove\ Math\ Menu'
elseif a:action == 0
***************
*** 107,117 ****
exe 'amenu enable '.menuloc.'Expand\ Elements'
exe 'amenu disable '.menuloc.'Compress\ Elements'
endif
! exe 'source '.s:path.'/elementmacros.vim'
elseif a:type == 'packages'
if a:action == 1
let g:Tex_PackagesMenu = 1
! exe 'so '.s:path.'/packages.vim'
exe 'amenu disable '.menuloc.'Load\ Packages\ Menu'
endif
endif
--- 107,117 ----
exe 'amenu enable '.menuloc.'Expand\ Elements'
exe 'amenu disable '.menuloc.'Compress\ Elements'
endif
! exe 'source '.fnameescape(s:path.'/elementmacros.vim')
elseif a:type == 'packages'
if a:action == 1
let g:Tex_PackagesMenu = 1
! exe 'so '.fnameescape(s:path.'/packages.vim')
exe 'amenu disable '.menuloc.'Load\ Packages\ Menu'
endif
endif
*** texproject.vim.orig Mon Jun 1 23:33:13 2009
--- texproject.vim Mon Jun 1 22:36:08 2009
***************
*** 39,45 ****
if glob(Tex_GetMainFileName(':p').'.latexmain') != ''
call Tex_Debug("Tex_ProjectLoad: sourcing
[".Tex_GetMainFileName().".latexmain]", "proj")
! exec 'source '.Tex_GetMainFileName().'.latexmain'
endif
call Tex_CD(curd)
--- 39,45 ----
if glob(Tex_GetMainFileName(':p').'.latexmain') != ''
call Tex_Debug("Tex_ProjectLoad: sourcing
[".Tex_GetMainFileName().".latexmain]", "proj")
! exec 'source 'fnameescape(.Tex_GetMainFileName().'.latexmain')
endif
call Tex_CD(curd)
*** tex_latexSuite.vim.orig Mon Jun 1 23:31:57 2009
--- tex_latexSuite.vim Mon Jun 1 22:35:23 2009
***************
*** 5,11 ****
if !exists('s:initLatexSuite')
let s:initLatexSuite = 1
! exec 'so '.expand('<sfile>:p:h').'/latex-suite/main.vim'
silent! do LatexSuite User LatexSuiteInitPost
endif
--- 5,11 ----
if !exists('s:initLatexSuite')
let s:initLatexSuite = 1
! exec 'so '.fnameescape(expand('<sfile>:p:h').'/latex-suite/main.vim')
silent! do LatexSuite User LatexSuiteInitPost
endif
------------------------------------------------------------------------------
OpenSolaris 2009.06 is a cutting edge operating system for enterprises
looking to deploy the next generation of Solaris that includes the latest
innovations from Sun and the OpenSource community. Download a copy and
enjoy capabilities such as Networking, Storage and Virtualization.
Go to: http://p.sf.net/sfu/opensolaris-get
_______________________________________________
Vim-latex-devel mailing list
Vim-latex-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vim-latex-devel