Verbose: mention cmd dir and run dir
This commit is contained in:
parent
49c8ce0f13
commit
14f7fda000
@ -159,7 +159,13 @@ endfunction
|
|||||||
" Function: #verbose {{{1
|
" Function: #verbose {{{1
|
||||||
function! sy#verbose(msg, ...) abort
|
function! sy#verbose(msg, ...) abort
|
||||||
if &verbose
|
if &verbose
|
||||||
echomsg printf('[sy%s] %s', (a:0 ? ':'.a:1 : ''), a:msg)
|
if type(a:msg) == type([])
|
||||||
|
for msg in a:msg
|
||||||
|
echomsg printf('[sy%s] %s', (a:0 ? ':'.a:1 : ''), msg)
|
||||||
|
endfor
|
||||||
|
else
|
||||||
|
echomsg printf('[sy%s] %s', (a:0 ? ':'.a:1 : ''), a:msg)
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
@ -75,7 +75,7 @@ function! sy#repo#get_diff_start(vcs) abort
|
|||||||
let [cmd, options] = s:initialize_job(a:vcs)
|
let [cmd, options] = s:initialize_job(a:vcs)
|
||||||
let [cwd, chdir] = sy#util#chdir()
|
let [cwd, chdir] = sy#util#chdir()
|
||||||
|
|
||||||
call sy#verbose(printf('CMD: %s | CWD: %s', string(cmd), b:sy.info.dir), a:vcs)
|
call sy#verbose(['CMD: '. string(cmd), 'CMD DIR: '. b:sy.info.dir, 'ORIG DIR: '. cwd], a:vcs)
|
||||||
|
|
||||||
try
|
try
|
||||||
execute chdir fnameescape(b:sy.info.dir)
|
execute chdir fnameescape(b:sy.info.dir)
|
||||||
@ -100,7 +100,7 @@ function! sy#repo#get_diff_start(vcs) abort
|
|||||||
let [cmd, options] = s:initialize_job(a:vcs)
|
let [cmd, options] = s:initialize_job(a:vcs)
|
||||||
let [cwd, chdir] = sy#util#chdir()
|
let [cwd, chdir] = sy#util#chdir()
|
||||||
|
|
||||||
call sy#verbose(printf('CMD: %s | CWD: %s', string(cmd), getcwd()), a:vcs)
|
call sy#verbose(['CMD: '. string(cmd), 'CMD DIR: '. b:sy.info.dir, 'ORIG DIR: '. cwd], a:vcs)
|
||||||
|
|
||||||
try
|
try
|
||||||
execute chdir fnameescape(b:sy.info.dir)
|
execute chdir fnameescape(b:sy.info.dir)
|
||||||
|
Loading…
Reference in New Issue
Block a user