diff options
author | Luca Matei Pintilie <luca@lucamatei.com> | 2023-05-24 20:23:47 +0000 |
---|---|---|
committer | Luca Matei Pintilie <luca@lucamatei.com> | 2023-05-24 20:23:47 +0000 |
commit | 0517926ee7ff8651def9f0b89f71a87d1173c928 (patch) | |
tree | d254873cbbe4b0e505e9ad477cdb66f2a0ca00da | |
parent | 18feff24b30bb4bbe21b3baad8b5456c0b0fd3c1 (diff) | |
download | dotfiles-0517926ee7ff8651def9f0b89f71a87d1173c928.tar dotfiles-0517926ee7ff8651def9f0b89f71a87d1173c928.tar.gz dotfiles-0517926ee7ff8651def9f0b89f71a87d1173c928.tar.bz2 dotfiles-0517926ee7ff8651def9f0b89f71a87d1173c928.tar.lz dotfiles-0517926ee7ff8651def9f0b89f71a87d1173c928.tar.xz dotfiles-0517926ee7ff8651def9f0b89f71a87d1173c928.tar.zst dotfiles-0517926ee7ff8651def9f0b89f71a87d1173c928.zip |
nvim: remove some unneeded code and plugins/lsp, and add live_grep keybind
-rw-r--r-- | .config/nvim/lua/general.lua | 2 | ||||
-rw-r--r-- | .config/nvim/lua/keybinds.lua | 4 | ||||
-rw-r--r-- | .config/nvim/lua/lsp.lua | 36 | ||||
-rw-r--r-- | .config/nvim/lua/plugins.lua | 11 |
4 files changed, 23 insertions, 30 deletions
diff --git a/.config/nvim/lua/general.lua b/.config/nvim/lua/general.lua index 03b01e7..03f511a 100644 --- a/.config/nvim/lua/general.lua +++ b/.config/nvim/lua/general.lua @@ -63,7 +63,7 @@ vim.g.markdown_fenced_languages = { "xml"; "mermaid"; "yaml"; - "yml"; + "yml=yaml"; "sql"; "sh"; "sh=bash"; diff --git a/.config/nvim/lua/keybinds.lua b/.config/nvim/lua/keybinds.lua index fa4d1a4..f4040c2 100644 --- a/.config/nvim/lua/keybinds.lua +++ b/.config/nvim/lua/keybinds.lua @@ -20,7 +20,8 @@ vim.keymap.set("n", "<Leader>F", vim.lsp.buf.format) vim.keymap.set("n", "<Leader>d", vim.diagnostic.open_float) vim.keymap.set("n", "<Leader>J", vim.lsp.buf.signature_help) -vim.keymap.set("n", "<Leader>f", telescope.find_files) +vim.keymap.set("n", "<Leader>fF", telescope.find_files) +vim.keymap.set("n", "<Leader>ff", telescope.live_grep) vim.keymap.set("n", "<Leader><TAB>", telescope.buffers) vim.keymap.set("n", "<Leader>D", telescope.lsp_definitions) vim.keymap.set("n", "<Leader>R", telescope.lsp_references) @@ -68,4 +69,3 @@ wk.register({ ["J"] = "Signature help"; ["U"] = "Undo tree"; }, { prefix = "<leader>" }); - diff --git a/.config/nvim/lua/lsp.lua b/.config/nvim/lua/lsp.lua index d7715f5..07aeac2 100644 --- a/.config/nvim/lua/lsp.lua +++ b/.config/nvim/lua/lsp.lua @@ -211,31 +211,31 @@ lspconfig.omnisharp.setup({ analyze_open_documents_only = false; }) -lspconfig.marksman.setup({ - root_dir = vim.loop.cwd; - on_attach = on_attach; - capabilities = capabilities; -}) +-- lspconfig.marksman.setup({ +-- root_dir = vim.loop.cwd; +-- on_attach = on_attach; +-- capabilities = capabilities; +-- }) -lspconfig.jsonls.setup({ - capabilities = capabilities; - cmd = { "vscode-json-language-server"; "--stdio" }; - on_attach = on_attach; -}) +-- lspconfig.jsonls.setup({ +-- capabilities = capabilities; +-- cmd = { "vscode-json-language-server"; "--stdio" }; +-- on_attach = on_attach; +-- }) -lspconfig.html.setup({ - capabilities = capabilities; - cmd = { "vscode-html-language-server"; "--stdio" }; - on_attach = on_attach; -}) +-- lspconfig.html.setup({ +-- capabilities = capabilities; +-- cmd = { "vscode-html-language-server"; "--stdio" }; +-- on_attach = on_attach; +-- }) -lspconfig.cssls.setup({ capabilities = capabilities; on_attach = on_attach }) +-- lspconfig.cssls.setup({ capabilities = capabilities; on_attach = on_attach }) -lspconfig.bashls.setup({ capabilities = capabilities; on_attach = on_attach }) +-- lspconfig.bashls.setup({ capabilities = capabilities; on_attach = on_attach }) lspconfig.clangd.setup({ capabilities = capabilities; on_attach = on_attach }) -lspconfig.dockerls.setup({ capabilities = capabilities; on_attach = on_attach }) +-- lspconfig.dockerls.setup({ capabilities = capabilities; on_attach = on_attach }) lspconfig.eslint.setup({ capabilities = capabilities; on_attach = on_attach }) diff --git a/.config/nvim/lua/plugins.lua b/.config/nvim/lua/plugins.lua index 679cf6e..b0def30 100644 --- a/.config/nvim/lua/plugins.lua +++ b/.config/nvim/lua/plugins.lua @@ -46,7 +46,8 @@ local PKGS = { { url = "https://github.com/google/vim-maktaba.git" }; { url = "https://github.com/editorconfig/editorconfig-vim.git" }; - { url = "https://github.com/nathom/filetype.nvim.git" }; + -- Some bugs when opening shell files + -- { url = "https://github.com/nathom/filetype.nvim.git" }; { url = "https://github.com/wfxr/minimap.vim.git" }; -- LSP @@ -198,14 +199,6 @@ local function init_plugins() -- Define 'comment' textobject (like `dgc` - delete whole comment block) textobject = "gc"; }; - - -- Hook functions to be executed at certain stage of commenting - hooks = { - -- Before successful commenting. Does nothing by default. - pre = function() end; - -- After successful commenting. Does nothing by default. - post = function() end; - }; }) require("gitsigns").setup { |