Suda support for CDC
This commit is contained in:
parent
c5f70a427a
commit
04d97575a7
10
init.vim
10
init.vim
|
@ -97,7 +97,15 @@ nnoremap <leader>fq <cmd>Telescope quickfix<cr>
|
|||
nnoremap <leader>fc <cmd>Telescope command_history<cr>
|
||||
nnoremap <leader>fs <cmd>Telescope search_history<cr>
|
||||
|
||||
command CDC cd %:p:h
|
||||
function! StripSuda(p)
|
||||
return substitute(a:p, 'suda://', '', '')
|
||||
endfunction
|
||||
|
||||
function! ChangeCurDir()
|
||||
execute 'cd ' . StripSuda(expand('%:p:h'))
|
||||
endfunction
|
||||
|
||||
command CDC execute "cd " . StripSuda(expand('%:p:h'))
|
||||
|
||||
let g:lt_location_list_toggle_map = '<leader>l'
|
||||
let g:lt_quickfix_list_toggle_map = '<leader>L' " unsure if I'm using this
|
||||
|
|
Loading…
Reference in New Issue