nvim: plugins: Switch to gitlinker from vim-rhubarb

Also see commit a7b12dc6.
This commit is contained in:
Sanchayan Maity 2022-01-15 11:04:18 +05:30
parent 34671c62fa
commit c35ca910e4
4 changed files with 10 additions and 15 deletions

View file

@ -29,9 +29,6 @@ nnoremap <Leader>g+ :Git stash pop<SPACE>
nnoremap <Leader>gs :Git stash list<CR> nnoremap <Leader>gs :Git stash list<CR>
nnoremap <Leader>gS :Git stash -- %<CR> nnoremap <Leader>gS :Git stash -- %<CR>
nnoremap <Leader>gt :Git reflog<CR> nnoremap <Leader>gt :Git reflog<CR>
xnoremap <Leader>gu :GBrowse!<CR>
xnoremap <Leader>gU :GBrowse<CR>
nnoremap <Leader>gu :norm 0v$<CR>:GBrowse<CR>
nnoremap <Leader>gw :Gwrite<CR> nnoremap <Leader>gw :Gwrite<CR>
nnoremap <Leader>G :Git<SPACE> nnoremap <Leader>G :Git<SPACE>

View file

@ -0,0 +1,7 @@
require"gitlinker".setup({
callbacks = {
["gitlab.freedesktop.org"] = require"gitlinker.hosts".get_gitlab_type_url,
["gitlab.gnome.org/GNOME"] = require"gitlinker.hosts".get_gitlab_type_url,
},
mappings = "<Leader>gu"
})

View file

@ -45,6 +45,7 @@ vim.g.loaded_perl_provider = 0
vim.g.loaded_node_provider = 0 vim.g.loaded_node_provider = 0
-- Disable some in built plugins completely -- Disable some in built plugins completely
vim.g.loaded_netrw = 1
vim.g.loaded_netrwPlugin = 1 vim.g.loaded_netrwPlugin = 1
vim.g.loaded_matchparen = 1 vim.g.loaded_matchparen = 1
vim.g.loaded_matchit = 1 vim.g.loaded_matchit = 1
@ -70,8 +71,6 @@ vim.g.vimtex_view_general_options = '--unique \\@pdf\\#src:@tex:@line:@col'
vim.g.dirvish_relative_paths = 1 vim.g.dirvish_relative_paths = 1
-- dispatch -- dispatch
vim.g.dispatch_no_maps = 1 vim.g.dispatch_no_maps = 1
-- vim-fugitive GBrowse GitLab
vim.g.fugitive_gitlab_domains = {'https://gitlab.freedesktop.org', 'https://gitlab.gnome.org/GNOME', 'https://gitlab.com'}
-- vim-matchup -- vim-matchup
vim.g.matchup_matchparen_offscreen = {} vim.g.matchup_matchparen_offscreen = {}

View file

@ -24,16 +24,8 @@ local init = function ()
} }
-- Git support -- Git support
use 'lewis6991/gitsigns.nvim' use 'lewis6991/gitsigns.nvim'
use { use 'tpope/vim-fugitive'
'tpope/vim-fugitive', use 'ruifm/gitlinker.nvim'
requires = {
-- GBrowse support
'tpope/vim-rhubarb',
'shumphrey/fugitive-gitlab.vim',
'https://git.sr.ht/~willdurand/srht.vim',
'mattn/webapi-vim'
}
}
use 'whiteinge/diffconflicts' use 'whiteinge/diffconflicts'
use 'junkblocker/patchreview-vim' use 'junkblocker/patchreview-vim'
-- Boost vim command line mode -- Boost vim command line mode