Skip to content

Commit 0da0b0d

Browse files
committed
Work around &shellslash setting on Windows
1 parent ef35a59 commit 0da0b0d

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

autoload/xolox/easytags.vim

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
" Vim script
22
" Author: Peter Odding <peter@peterodding.com>
3-
" Last Change: October 29, 2011
3+
" Last Change: November 21, 2011
44
" URL: http://peterodding.com/code/vim/easytags/
55

6-
let g:xolox#easytags#version = '2.7.2'
6+
let g:xolox#easytags#version = '2.7.3'
77

88
" Public interface through (automatic) commands. {{{1
99

@@ -160,7 +160,7 @@ function! s:prep_cmdline(cfile, tagsfile, firstrun, arguments, context) " {{{3
160160
let program = xolox#misc#option#get('easytags_cmd')
161161
let cmdline = [program, '--fields=+l', '--c-kinds=+p', '--c++-kinds=+p']
162162
if a:firstrun
163-
call add(cmdline, shellescape('-f' . a:tagsfile))
163+
call add(cmdline, xolox#misc#escape#shell('-f' . a:tagsfile))
164164
call add(cmdline, '--sort=' . (&ic ? 'foldcase' : 'yes'))
165165
else
166166
call add(cmdline, '--sort=no')
@@ -173,13 +173,13 @@ function! s:prep_cmdline(cfile, tagsfile, firstrun, arguments, context) " {{{3
173173
if a:cfile != ''
174174
if xolox#misc#option#get('easytags_autorecurse', 0)
175175
call add(cmdline, '-R')
176-
call add(cmdline, shellescape(a:cfile))
176+
call add(cmdline, xolox#misc#escape#shell(a:cfile))
177177
else
178178
" TODO Should --language-force distinguish between C and C++?
179179
" TODO --language-force doesn't make sense for JavaScript tags in HTML files?
180180
let filetype = xolox#easytags#to_ctags_ft(&filetype)
181-
call add(cmdline, shellescape('--language-force=' . filetype))
182-
call add(cmdline, shellescape(a:cfile))
181+
call add(cmdline, xolox#misc#escape#shell('--language-force=' . filetype))
182+
call add(cmdline, xolox#misc#escape#shell(a:cfile))
183183
endif
184184
let have_args = 1
185185
else
@@ -190,7 +190,7 @@ function! s:prep_cmdline(cfile, tagsfile, firstrun, arguments, context) " {{{3
190190
else
191191
let matches = split(expand(arg), "\n")
192192
if !empty(matches)
193-
call map(matches, 'shellescape(s:canonicalize(v:val, a:context))')
193+
call map(matches, 'xolox#misc#escape#shell(s:canonicalize(v:val, a:context))')
194194
call extend(cmdline, matches)
195195
let have_args = 1
196196
endif

0 commit comments

Comments
 (0)