Fix git blame toggle mapping
This commit is contained in:
parent
d7a046389a
commit
466f52599a
|
@ -28,6 +28,7 @@ vim.cmd([[colorscheme gruvbox]])
|
|||
|
||||
require("sets")
|
||||
require("mappings")
|
||||
require("autocmd")
|
||||
require("git")
|
||||
require("lsp")
|
||||
require("line")
|
||||
|
|
|
@ -1,4 +1,11 @@
|
|||
vim.api.nvim_create_autocmd({ "FocusGained" }, {
|
||||
pattern = { "*" },
|
||||
command = "checktime",
|
||||
})
|
||||
-- vim.api.nvim_create_autocmd({ "BufNewFile", "BufRead" }, {
|
||||
-- pattern = { "*.yaml", "*.yml" },
|
||||
-- callback = function()
|
||||
-- local fname = vim.fn.expand("%:p")
|
||||
-- if require("lspconfig.util").root_pattern("Chart.yaml")(fname) then
|
||||
-- vim.opt_local.filetype = "helm"
|
||||
-- else
|
||||
-- vim.opt_local.filetype = "yaml"
|
||||
-- end
|
||||
-- end,
|
||||
-- })
|
||||
|
|
|
@ -127,6 +127,14 @@ lspconfig.terraformls.setup({})
|
|||
-- json & yaml
|
||||
lspconfig.jsonls.setup({})
|
||||
lspconfig.yamlls.setup({})
|
||||
-- helm
|
||||
-- lspconfig.helm_ls.setup({
|
||||
-- filetypes = { "helm" },
|
||||
-- cmd = { "helm_ls", "serve" },
|
||||
-- root_dir = function(fname)
|
||||
-- return require("lspconfig.util").root_pattern("Chart.yaml")(fname)
|
||||
-- end,
|
||||
-- })
|
||||
|
||||
-- Install LSP servers automatically
|
||||
require("mason-lspconfig").setup({ automatic_installation = true })
|
||||
|
|
|
@ -51,7 +51,7 @@ vim.keymap.set("", "\\", ':let @/ = ""<CR>', opts)
|
|||
|
||||
-- Git
|
||||
vim.keymap.set("n", "<leader>gd", vim.cmd.Gvdiff, opts)
|
||||
-- vim.keymap.set("n", "<leader>gb", vim.cmd('Gitsigns toggle_current_line_blame'))
|
||||
vim.keymap.set("n", "<leader>gb", function() vim.cmd("Gitsigns toggle_current_line_blame") end, opts)
|
||||
|
||||
-- window movement
|
||||
vim.keymap.set("n", "<leader>wn", "<C-W>j", opts)
|
||||
|
|
Loading…
Reference in New Issue