mirror of
https://github.com/amix/vimrc
synced 2025-07-07 08:45:00 +08:00
Updated plugins
This commit is contained in:
@ -3,7 +3,17 @@ function! cargo#Load()
|
||||
endfunction
|
||||
|
||||
function! cargo#cmd(args)
|
||||
execute "! cargo" a:args
|
||||
" Trim trailing spaces. This is necessary since :terminal command parses
|
||||
" trailing spaces as an empty argument.
|
||||
let args = substitute(a:args, '\s\+$', '', '')
|
||||
if has('terminal')
|
||||
let cmd = 'terminal'
|
||||
elseif has('nvim')
|
||||
let cmd = 'noautocmd new | terminal'
|
||||
else
|
||||
let cmd = '!'
|
||||
endif
|
||||
execute cmd 'cargo' args
|
||||
endfunction
|
||||
|
||||
function! s:nearest_cargo(...) abort
|
||||
|
Reference in New Issue
Block a user