mirror of
https://github.com/jdhao/nvim-config.git
synced 2025-06-08 14:14:33 +02:00
Compare commits
6 Commits
17acda10a0
...
acb8b7fcf8
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
acb8b7fcf8 | ||
|
|
46cbdc2d7f | ||
|
|
c71ad44cd3 | ||
|
|
db378b858b | ||
|
|
ee45f1f5a1 | ||
|
|
43660dd540 |
14
lua/config/git-linker.lua
Normal file
14
lua/config/git-linker.lua
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
local gitlinker = require('gitlinker')
|
||||||
|
|
||||||
|
gitlinker.setup({
|
||||||
|
mappings = nil,
|
||||||
|
})
|
||||||
|
|
||||||
|
vim.keymap.set({ 'n', 'v' }, '<leader>gl', '', {
|
||||||
|
silent = true,
|
||||||
|
desc = "get git permlink",
|
||||||
|
callback = function()
|
||||||
|
local mode = string.lower(vim.fn.mode())
|
||||||
|
gitlinker.get_buf_range_url(mode)
|
||||||
|
end
|
||||||
|
})
|
||||||
@ -9,7 +9,7 @@ hop.setup({
|
|||||||
quit_key = "<Esc>",
|
quit_key = "<Esc>",
|
||||||
})
|
})
|
||||||
|
|
||||||
vim.keymap.set({ "n", "v" }, "f", "", {
|
vim.keymap.set({ "n", "v", "o" }, "f", "", {
|
||||||
silent = true,
|
silent = true,
|
||||||
noremap = true,
|
noremap = true,
|
||||||
callback = function()
|
callback = function()
|
||||||
|
|||||||
@ -213,7 +213,7 @@ packer.startup({
|
|||||||
|
|
||||||
-- Show the content of register in preview window
|
-- Show the content of register in preview window
|
||||||
-- Plug 'junegunn/vim-peekaboo'
|
-- Plug 'junegunn/vim-peekaboo'
|
||||||
use({ "jdhao/better-escape.vim", event = { "InsertEnter" } })
|
use({ "nvim-zh/better-escape.vim", event = { "InsertEnter" } })
|
||||||
|
|
||||||
if vim.g.is_mac then
|
if vim.g.is_mac then
|
||||||
use({ "lyokha/vim-xkbswitch", event = { "InsertEnter" } })
|
use({ "lyokha/vim-xkbswitch", event = { "InsertEnter" } })
|
||||||
@ -236,6 +236,13 @@ packer.startup({
|
|||||||
|
|
||||||
use({ "christoomey/vim-conflicted", requires = "tpope/vim-fugitive", cmd = {"Conflicted"}})
|
use({ "christoomey/vim-conflicted", requires = "tpope/vim-fugitive", cmd = {"Conflicted"}})
|
||||||
|
|
||||||
|
use {
|
||||||
|
'ruifm/gitlinker.nvim',
|
||||||
|
requires = 'nvim-lua/plenary.nvim',
|
||||||
|
event = "User InGitRepo",
|
||||||
|
config = [[require('config.git-linker')]]
|
||||||
|
}
|
||||||
|
|
||||||
use({ "kevinhwang91/nvim-bqf", ft = "qf", config = [[require('config.bqf')]] })
|
use({ "kevinhwang91/nvim-bqf", ft = "qf", config = [[require('config.bqf')]] })
|
||||||
|
|
||||||
-- Better git commit experience
|
-- Better git commit experience
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user