diff --git a/autoload/classpath.vim b/autoload/classpath.vim index fa3f9a9..696ac39 100644 --- a/autoload/classpath.vim +++ b/autoload/classpath.vim @@ -104,7 +104,7 @@ function! classpath#detect(...) abort if &verbose echomsg 'Determining class path with '.cmd.' ...' endif - let out = system('cd ' . shellescape(root) . ' && ' . cmd) + let out = system('cd ' . shellescape(root) . (&shell =~? 'cmd' ? '; ' : ' && ') . cmd) catch /^Vim:Interrupt/ return default endtry