Remove shellslash options, fix windows find (#40)
This commit is contained in:
parent
e00fb95767
commit
bef84296d8
@ -106,16 +106,9 @@ function! latex#view(...) " {{{1
|
|||||||
" Join arguments to pass them on to the viewer
|
" Join arguments to pass them on to the viewer
|
||||||
let args = join(a:000, ' ') . ' '
|
let args = join(a:000, ' ') . ' '
|
||||||
|
|
||||||
" Disable shellslash
|
|
||||||
let l:ssl = &l:ssl
|
|
||||||
setlocal nossl
|
|
||||||
|
|
||||||
let exe = {}
|
let exe = {}
|
||||||
let exe.cmd = g:latex_viewer . ' ' . args . shellescape(outfile)
|
let exe.cmd = g:latex_viewer . ' ' . args . shellescape(outfile)
|
||||||
|
|
||||||
" Restore shellslash
|
|
||||||
let &l:ssl = l:ssl
|
|
||||||
|
|
||||||
call latex#util#execute(exe)
|
call latex#util#execute(exe)
|
||||||
endfunction
|
endfunction
|
||||||
" }}}1
|
" }}}1
|
||||||
|
@ -72,10 +72,6 @@ function! latex#latexmk#clean(full) " {{{1
|
|||||||
return
|
return
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Disable shellslash
|
|
||||||
let l:ssl = &l:ssl
|
|
||||||
setlocal nossl
|
|
||||||
|
|
||||||
"
|
"
|
||||||
" Run latexmk clean process
|
" Run latexmk clean process
|
||||||
"
|
"
|
||||||
@ -97,9 +93,6 @@ function! latex#latexmk#clean(full) " {{{1
|
|||||||
\ }
|
\ }
|
||||||
call latex#util#execute(exe)
|
call latex#util#execute(exe)
|
||||||
|
|
||||||
" Restore shellslash
|
|
||||||
let &l:ssl = l:ssl
|
|
||||||
|
|
||||||
if a:full
|
if a:full
|
||||||
echomsg "latexmk full clean finished"
|
echomsg "latexmk full clean finished"
|
||||||
else
|
else
|
||||||
@ -232,10 +225,6 @@ function! s:latexmk_set_cmd(data) " {{{1
|
|||||||
" which allows inspection of latexmk output
|
" which allows inspection of latexmk output
|
||||||
let tmp = tempname()
|
let tmp = tempname()
|
||||||
|
|
||||||
" Disable shellslash
|
|
||||||
let l:ssl = &l:ssl
|
|
||||||
setlocal nossl
|
|
||||||
|
|
||||||
if has('win32')
|
if has('win32')
|
||||||
let cmd = 'cd /D ' . shellescape(a:data.root)
|
let cmd = 'cd /D ' . shellescape(a:data.root)
|
||||||
let cmd .= ' && set max_print_line=2000 & latexmk'
|
let cmd .= ' && set max_print_line=2000 & latexmk'
|
||||||
@ -259,9 +248,6 @@ function! s:latexmk_set_cmd(data) " {{{1
|
|||||||
|
|
||||||
let cmd .= ' ' . shellescape(a:data.base)
|
let cmd .= ' ' . shellescape(a:data.base)
|
||||||
|
|
||||||
" Restore shellslash
|
|
||||||
let &l:ssl = l:ssl
|
|
||||||
|
|
||||||
if has('win32')
|
if has('win32')
|
||||||
let cmd .= ' >' . tmp
|
let cmd .= ' >' . tmp
|
||||||
let cmd = 'cmd /s /c "' . cmd . '"'
|
let cmd = 'cmd /s /c "' . cmd . '"'
|
||||||
@ -279,7 +265,8 @@ function! s:latexmk_set_pid(data) " {{{1
|
|||||||
let tmpfile = tempname()
|
let tmpfile = tempname()
|
||||||
silent execute '!cmd /c "wmic process where '
|
silent execute '!cmd /c "wmic process where '
|
||||||
\ . '(CommandLine LIKE "latexmk\%' . a:data.base . '\%") '
|
\ . '(CommandLine LIKE "latexmk\%' . a:data.base . '\%") '
|
||||||
\ . 'get ProcessId /value | find "ProcessId" '
|
\ . 'get ProcessId /value'
|
||||||
|
\ . '| \%WINDIR\%\system32\find "ProcessId" '
|
||||||
\ . '>' . tmpfile . ' "'
|
\ . '>' . tmpfile . ' "'
|
||||||
let pids = readfile(tmpfile)
|
let pids = readfile(tmpfile)
|
||||||
let a:data.pid = strpart(pids[0], 10)
|
let a:data.pid = strpart(pids[0], 10)
|
||||||
|
Loading…
Reference in New Issue
Block a user