[vim] git push/pull commands through a vim internal pane

This commit is contained in:
2022-09-08 12:17:14 +03:00
parent b3d099122a
commit b3b907c408

View File

@@ -98,8 +98,12 @@ nnoremap <leader>gu :GitGutterUndoHunk<CR> " undo git change under the line
" Magit plugin config
"
nnoremap <leader>gs :Magit<CR>| " git status
nnoremap <leader>gp :! git push<CR>| " git Push
nnoremap <leader>gP :! git pull<CR>| " git Pull
function GitPullPush(cmd)
echo system('git '.a:cmd)
" redraw!
endfunction
nnoremap <leader>gp :call GitPullPush("push")<CR>| " git Push
nnoremap <leader>gP :call GitPullPush("pull")<CR>| " git Pull
"
" NERDTree plugin config