diff --git a/vim/.vim/lua/plugins/base.lua b/vim/.vim/lua/plugins/base.lua index 4276563..acc0fa6 100644 --- a/vim/.vim/lua/plugins/base.lua +++ b/vim/.vim/lua/plugins/base.lua @@ -2,6 +2,24 @@ local use_google = require("utils").use_google local buf_too_large = require("utils").buf_too_large return { + -- { + -- "m4xshen/hardtime.nvim", + -- dependencies = { "MunifTanjim/nui.nvim", "nvim-lua/plenary.nvim" }, + -- opts = {}, + -- }, + { + "folke/flash.nvim", + event = "VeryLazy", + opts = {}, + -- stylua: ignore + keys = { + { "s", mode = { "n", "x", "o" }, function() require("flash").jump() end, desc = "Flash" }, + { "S", mode = { "n", "x", "o" }, function() require("flash").treesitter() end, desc = "Flash Treesitter" }, + { "r", mode = "o", function() require("flash").remote() end, desc = "Remote Flash" }, + { "R", mode = { "o", "x" }, function() require("flash").treesitter_search() end, desc = "Treesitter Search" }, + { "", mode = { "c" }, function() require("flash").toggle() end, desc = "Toggle Flash Search" }, + }, + }, { "Bekaboo/dropbar.nvim", -- optional, but required for fuzzy finder support @@ -66,6 +84,7 @@ return { }) end, }, + "tpope/vim-abolish", { "johmsalas/text-case.nvim", dependencies = { "nvim-telescope/telescope.nvim" }, diff --git a/vim/.vim/lua/plugins/diagnostics.lua b/vim/.vim/lua/plugins/diagnostics.lua index 8da041c..fbb93a2 100644 --- a/vim/.vim/lua/plugins/diagnostics.lua +++ b/vim/.vim/lua/plugins/diagnostics.lua @@ -13,8 +13,9 @@ return { end, keys = { { "xt", ":Telescope diagnostics" }, - { "xw", ":Trouble workspace_diagnostics" }, - { "xd", ":Trouble document_diagnostics" }, + { "gr", ":Trouble lsp_references" }, + { "xw", ":Trouble workspace_diagnostics" }, + { "xd", ":Trouble document_diagnostics" }, { "[g", "lua vim.diagnostic.goto_prev()" }, { "]g", "lua vim.diagnostic.goto_next()" }, }, diff --git a/vim/.vim/lua/plugins/paint.lua b/vim/.vim/lua/plugins/paint.lua new file mode 100644 index 0000000..ad2d66b --- /dev/null +++ b/vim/.vim/lua/plugins/paint.lua @@ -0,0 +1,54 @@ +return { + "folke/paint.nvim", + config = function() + vim.api.nvim_set_hl(0, "LightPurple", { fg = "#7f67c5" }) + + require("paint").setup({ + highlights = { + -- Highlight /** @something */ + { + filter = { filetype = "java" }, + pattern = "%*.-(@[%w_]+)%s?", + hl = "Constant", + }, + -- Highlight /** @param something */ + { + filter = { filetype = "java" }, + pattern = "%*.*@param%s+([%w_+]+)%s?", + hl = "Identifier", + }, + -- Highlight /** {@link} */ + -- { + -- filter = { filetype = "java" }, + -- pattern = "%*.*{%s?(@link)%s+[%w_+]+%s?}", + -- hl = "Red", + -- }, + -- -- Highlight /** {@link something} */ + -- { + -- filter = { filetype = "java" }, + -- pattern = "%*.*{%s?@link%s+([%w_+]+)%s?}", + -- hl = "Yellow", + -- }, + -- + -- WASM + { pattern = "(W)ASM", hl = "LightRed", filter = {} }, + { pattern = "W(A)SM", hl = "LightBlue", filter = {} }, + { pattern = "WA(S)M", hl = "LightGreen", filter = {} }, + { pattern = "WAS(M)", hl = "LightYellow", filter = {} }, + + -- Google + -- { pattern = "Google", hl = "LightBlue", filter = {} }, + -- { pattern = "(G)oogle", hl = "LightBlue", filter = {} }, + -- { pattern = "G(o)ogle", hl = "LightRed", filter = {} }, + -- { pattern = "Go(o)gle", hl = "LightYellow", filter = {} }, + -- { pattern = "Goo(g)le", hl = "LightBlue", filter = {} }, + -- { pattern = "Goog(l)e", hl = "LightGreen", filter = {} }, + -- { pattern = "Googl(e)", hl = "LightRed", filter = {} }, + + -- cnieves + { pattern = "cnieves", hl = "LightPurple", filter = {} }, + { pattern = "Christian Nieves", hl = "LightPurple", filter = {} }, + }, + }) + end, +}