From aec1dd0266ea9ee981bf4e1ad6b10e8debac98d7 Mon Sep 17 00:00:00 2001 From: punkfairie <23287005+punkfairie@users.noreply.github.com> Date: Mon, 11 Mar 2024 18:08:14 -0700 Subject: [PATCH] =?UTF-8?q?=E2=99=BB=20refactor(nvim):=20Major=20nvim=20pl?= =?UTF-8?q?ugin=20spec=20refactor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .config/nvim/lazy-lock.json | 14 +- .config/nvim/lua/config/tabset.lua | 11 ++ .config/nvim/lua/plugins/beacon.lua | 9 ++ .../plugins/{formatting.lua => conform.lua} | 0 .config/nvim/lua/plugins/cutlass.lua | 15 +++ .config/nvim/lua/plugins/diffview.lua | 6 + .config/nvim/lua/plugins/dim.lua | 7 + .config/nvim/lua/plugins/editor.lua | 123 ------------------ .config/nvim/lua/plugins/gitsigns.lua | 8 ++ .config/nvim/lua/plugins/lazygit.lua | 6 + .config/nvim/lua/plugins/linting.lua | 19 --- .config/nvim/lua/plugins/luasnip.lua | 16 +++ .config/nvim/lua/plugins/mason-lspconfig.lua | 12 ++ .config/nvim/lua/plugins/mason.lua | 24 ++++ .config/nvim/lua/plugins/neo-tree.lua | 18 +++ .config/nvim/lua/plugins/nerdy.lua | 9 ++ .../lua/plugins/{coding.lua => nvim-cmp.lua} | 30 +---- .config/nvim/lua/plugins/nvim-devdocs.lua | 36 +++++ .config/nvim/lua/plugins/nvim-emmet.lua | 9 ++ .config/nvim/lua/plugins/nvim-lint.lua | 21 +++ .../plugins/{lsp.lua => nvim-lspconfig.lua} | 44 ------- .../{treesitter.lua => nvim-treesitter.lua} | 9 -- .config/nvim/lua/plugins/refactoring.lua | 10 ++ .config/nvim/lua/plugins/ssr.lua | 15 +++ .config/nvim/lua/plugins/tabset.lua | 6 + .config/nvim/lua/plugins/treesj.lua | 10 ++ .config/nvim/lua/plugins/vim-blade.lua | 6 + .config/nvim/lua/plugins/vim-dotenv.lua | 6 + .config/nvim/lua/plugins/vim-pkgbuild.lua | 6 + .../nvim/lua/plugins/vim-tmux-navigator.lua | 19 +++ 30 files changed, 297 insertions(+), 227 deletions(-) create mode 100644 .config/nvim/lua/config/tabset.lua create mode 100644 .config/nvim/lua/plugins/beacon.lua rename .config/nvim/lua/plugins/{formatting.lua => conform.lua} (100%) create mode 100644 .config/nvim/lua/plugins/cutlass.lua create mode 100644 .config/nvim/lua/plugins/diffview.lua create mode 100644 .config/nvim/lua/plugins/dim.lua delete mode 100644 .config/nvim/lua/plugins/editor.lua create mode 100644 .config/nvim/lua/plugins/gitsigns.lua create mode 100644 .config/nvim/lua/plugins/lazygit.lua delete mode 100644 .config/nvim/lua/plugins/linting.lua create mode 100644 .config/nvim/lua/plugins/luasnip.lua create mode 100644 .config/nvim/lua/plugins/mason-lspconfig.lua create mode 100644 .config/nvim/lua/plugins/mason.lua create mode 100644 .config/nvim/lua/plugins/neo-tree.lua create mode 100644 .config/nvim/lua/plugins/nerdy.lua rename .config/nvim/lua/plugins/{coding.lua => nvim-cmp.lua} (69%) create mode 100644 .config/nvim/lua/plugins/nvim-devdocs.lua create mode 100644 .config/nvim/lua/plugins/nvim-emmet.lua create mode 100644 .config/nvim/lua/plugins/nvim-lint.lua rename .config/nvim/lua/plugins/{lsp.lua => nvim-lspconfig.lua} (79%) rename .config/nvim/lua/plugins/{treesitter.lua => nvim-treesitter.lua} (85%) create mode 100644 .config/nvim/lua/plugins/refactoring.lua create mode 100644 .config/nvim/lua/plugins/ssr.lua create mode 100644 .config/nvim/lua/plugins/tabset.lua create mode 100644 .config/nvim/lua/plugins/treesj.lua create mode 100644 .config/nvim/lua/plugins/vim-blade.lua create mode 100644 .config/nvim/lua/plugins/vim-dotenv.lua create mode 100644 .config/nvim/lua/plugins/vim-pkgbuild.lua create mode 100644 .config/nvim/lua/plugins/vim-tmux-navigator.lua diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json index 12b39ef..03adcb3 100644 --- a/.config/nvim/lazy-lock.json +++ b/.config/nvim/lazy-lock.json @@ -2,15 +2,16 @@ "LazyVim": { "branch": "main", "commit": "e3bfcb9bf74292dc846f5d1710fbb2e8f36a687a" }, "LuaSnip": { "branch": "master", "commit": "a7a4b4682c4b3e2ba82b82a4e6e5f5a0e79dec32" }, "SchemaStore.nvim": { "branch": "main", "commit": "b788bde023f9fbc2eb86e89d32c0bf98a60ae406" }, - "aerial.nvim": { "branch": "master", "commit": "31fbd369bbbeb53080c4b1ead9e76be322725ef5" }, + "aerial.nvim": { "branch": "master", "commit": "c8a40b12668b0861c9c519f13a8a5f29a1f1ef28" }, "beacon.nvim": { "branch": "main", "commit": "d02ee7dfcc999537c2f09abdf667aab52f8648f3" }, "bufferline.nvim": { "branch": "main", "commit": "64e2c5def50dfd6b6f14d96a45fa3d815a4a1eef" }, "catppuccin": { "branch": "main", "commit": "045e3499d9ec8d84635fb08877ae44fd33f6a38d" }, "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, + "cmp-emoji": { "branch": "main", "commit": "0acd702358230abeb6576769f7116e766bca28a0" }, "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" }, "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, - "conform.nvim": { "branch": "master", "commit": "5a15cc46e75cad804fd51ec5af9227aeb1d1bdaa" }, + "conform.nvim": { "branch": "master", "commit": "db2c697fe8302f0328b50b480204be1b577a1e2f" }, "cutlass.nvim": { "branch": "main", "commit": "1ac7e4b53d79410be52a9e464d44c60556282b3e" }, "dashboard-nvim": { "branch": "master", "commit": "413442b12d85315fc626c44a0ce4929b213ef604" }, "diffview.nvim": { "branch": "main", "commit": "3dc498c9777fe79156f3d32dddd483b8b3dbd95f" }, @@ -24,7 +25,7 @@ "lazy.nvim": { "branch": "main", "commit": "83493db50a434a4c5c648faf41e2ead80f96e478" }, "lazygit.nvim": { "branch": "main", "commit": "774dcecbd0b9b57be6c150adacb60ced79b11b23" }, "leap.nvim": { "branch": "main", "commit": "bf5d64f072a74968191f9994b0c05fac64f5f015" }, - "lualine.nvim": { "branch": "master", "commit": "8b56462bfb746760465264de41b4907310f113ec" }, + "lualine.nvim": { "branch": "master", "commit": "3c55675a7bc170d21d7ea70874ae66fbf5cfb0dc" }, "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "55716a879568a498fa236593c8119789054a3b8e" }, "mason.nvim": { "branch": "main", "commit": "3b5068f0fc565f337d67a2d315d935f574848ee7" }, @@ -42,6 +43,7 @@ "neotest": { "branch": "master", "commit": "4440cc2227894c2ae9b0673a30e6cc6f1836e8c2" }, "neotest-python": { "branch": "master", "commit": "2e83d2bc00acbcc1fd529dbf0a0e677cabfe6b50" }, "neotest-rspec": { "branch": "main", "commit": "0d73fe6de6baf951f6b95f55a4770429b9d58953" }, + "nerdy.nvim": { "branch": "main", "commit": "1ad36242f40a8fd95ae5711258540a07a5dabb51" }, "noice.nvim": { "branch": "main", "commit": "bf67d70bd7265d075191e7812d8eb42b9791f737" }, "none-ls.nvim": { "branch": "main", "commit": "ff3819c52ca04232fb70fbd6c1639de9abcbe122" }, "nui.nvim": { "branch": "main", "commit": "756c59f46057cd2d43619cd3a6d4e01b2aa60295" }, @@ -49,11 +51,11 @@ "nvim-devdocs": { "branch": "master", "commit": "521d24661ffe6d1ba025debea2675c765a9c1ee1" }, "nvim-emmet": { "branch": "main", "commit": "928cfb74ed436d6d326ccab2061cf3592de1bf55" }, "nvim-lint": { "branch": "master", "commit": "e824adb9bc01647f71e55457353a68f0f37f9931" }, - "nvim-lspconfig": { "branch": "master", "commit": "99330586c6e1912c890fc39d19d97571fde660cd" }, + "nvim-lspconfig": { "branch": "master", "commit": "1917b562a02f20885900b1da0f0ea25028ccedab" }, "nvim-navic": { "branch": "master", "commit": "8649f694d3e76ee10c19255dece6411c29206a54" }, "nvim-notify": { "branch": "master", "commit": "5371f4bfc1f6d3adf4fe9d62cd3a9d44356bfd15" }, "nvim-spectre": { "branch": "master", "commit": "3712ff0cdf4f9f877d9ca708d835a877d9a0abaf" }, - "nvim-treesitter": { "branch": "master", "commit": "488bec03254207b1dd071be8cb1fb78434b6e777" }, + "nvim-treesitter": { "branch": "master", "commit": "9d39f00a9559cf3505d73b486c0b8055a6db4215" }, "nvim-treesitter-context": { "branch": "master", "commit": "b8b7e52c1517d401d7c519787d5dc4528c41291a" }, "nvim-treesitter-textobjects": { "branch": "master", "commit": "b7a0bfa3e93697ca5b61b15df633404bf8f45883" }, "nvim-ts-autotag": { "branch": "main", "commit": "531f48334c422222aebc888fd36e7d109cb354cd" }, @@ -62,7 +64,9 @@ "persistence.nvim": { "branch": "main", "commit": "4982499c1636eac254b72923ab826ee7827b3084" }, "plenary.nvim": { "branch": "master", "commit": "f7adfc4b3f4f91aab6caebf42b3682945fbc35be" }, "project.nvim": { "branch": "main", "commit": "8c6bad7d22eef1b71144b401c9f74ed01526a4fb" }, + "refactoring.nvim": { "branch": "master", "commit": "93d69cce9f0cbee8afae5b2380b296323792645f" }, "sqlite.lua": { "branch": "master", "commit": "40701b6151f8883980c1548647116de39b763540" }, + "ssr.nvim": { "branch": "main", "commit": "bb323ba621ac647b4ac5638b47666e3ef3c279e1" }, "tabset.nvim": { "branch": "main", "commit": "996f95e4105d053a163437e19a40bd2ea10abeb2" }, "telescope-fzf-native.nvim": { "branch": "main", "commit": "9ef21b2e6bb6ebeaf349a0781745549bbb870d27" }, "telescope.nvim": { "branch": "master", "commit": "7472420f8734c710bd7009081cef9b97f08a3821" }, diff --git a/.config/nvim/lua/config/tabset.lua b/.config/nvim/lua/config/tabset.lua new file mode 100644 index 0000000..5ed5585 --- /dev/null +++ b/.config/nvim/lua/config/tabset.lua @@ -0,0 +1,11 @@ +return { + defaults = { + tabwidth = 2, + expandtab = true, + }, + languages = { + fish = { + tabwidth = 4, + }, + }, +} diff --git a/.config/nvim/lua/plugins/beacon.lua b/.config/nvim/lua/plugins/beacon.lua new file mode 100644 index 0000000..7763a30 --- /dev/null +++ b/.config/nvim/lua/plugins/beacon.lua @@ -0,0 +1,9 @@ +return { + { + "rainbowhxch/beacon.nvim", + event = "CursorMoved", + cond = function() + return not vim.g.neovide + end, + }, +} diff --git a/.config/nvim/lua/plugins/formatting.lua b/.config/nvim/lua/plugins/conform.lua similarity index 100% rename from .config/nvim/lua/plugins/formatting.lua rename to .config/nvim/lua/plugins/conform.lua diff --git a/.config/nvim/lua/plugins/cutlass.lua b/.config/nvim/lua/plugins/cutlass.lua new file mode 100644 index 0000000..385fd12 --- /dev/null +++ b/.config/nvim/lua/plugins/cutlass.lua @@ -0,0 +1,15 @@ +return { + { + "gbprod/cutlass.nvim", + event = "BufReadPost", + opts = { + cut_key = "x", + override_del = true, + registers = { + select = "_", + delete = "_", + change = "_", + }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/diffview.lua b/.config/nvim/lua/plugins/diffview.lua new file mode 100644 index 0000000..9ab05d8 --- /dev/null +++ b/.config/nvim/lua/plugins/diffview.lua @@ -0,0 +1,6 @@ +return { + { + "sindrets/diffview.nvim", + config = true, + }, +} diff --git a/.config/nvim/lua/plugins/dim.lua b/.config/nvim/lua/plugins/dim.lua new file mode 100644 index 0000000..afec06b --- /dev/null +++ b/.config/nvim/lua/plugins/dim.lua @@ -0,0 +1,7 @@ +return { + { + "0oAstro/dim.lua", + event = "LspAttach", + config = true, + }, +} diff --git a/.config/nvim/lua/plugins/editor.lua b/.config/nvim/lua/plugins/editor.lua deleted file mode 100644 index 2e48c8a..0000000 --- a/.config/nvim/lua/plugins/editor.lua +++ /dev/null @@ -1,123 +0,0 @@ -return { - { - "nvim-neo-tree/neo-tree.nvim", - opts = { - close_if_last_window = true, - window = { - width = 30, - }, - filesystem = { - filtered_items = { - hide_dotfiles = false, - hide_gitignored = false, - hide_hidden = false, - }, - }, - }, - }, - - { - "FotiadisM/tabset.nvim", - opts = { - defaults = { - tabwidth = 2, - expandtab = true, - }, - languages = { - fish = { - tabwidth = 4, - }, - }, - }, - }, - - { - "gbprod/cutlass.nvim", - event = "BufReadPost", - opts = { - cut_key = "x", - override_del = true, - registers = { - select = "_", - delete = "d", - change = "_", - }, - }, - }, - - { - "rainbowhxch/beacon.nvim", - event = "CursorMoved", - cond = function() - return not vim.g.neovide - end, - }, - - { - "lewis6991/gitsigns.nvim", - dependencies = { - { - "sindrets/diffview.nvim", - config = true, - }, - }, - }, - - { - "kdheepak/lazygit.nvim", - cmd = "LazyGit", - }, - - { - "christoomey/vim-tmux-navigator", - cmd = { - "TmuxNavigateLeft", - "TmuxNavigateDown", - "TmuxNavigateUp", - "TmuxNavigateRight", - "TmuxNavigatePrevious", - }, - keys = { - { "", "TmuxNavigateLeft" }, - { "", "TmuxNavigateDown" }, - { "", "TmuxNavigateUp" }, - { "", "TmuxNavigateRight" }, - { "", "TmuxNavigatePrevious" }, - }, - }, - - { - "luckasRanarison/nvim-devdocs", - dependencies = { - "nvim-lua/plenary.nvim", - "nvim-telescope/telescope.nvim", - "nvim-treesitter/nvim-treesitter", - }, - opts = { - ensure_installed = { - "bash", - "bootstrap~5", - "css", - "eslint", - "fish~3.7", - "html", - "http", - "javascript", - "laravel~10", - "liquid", - "lodash~4", - "lua~5.4", - "markdown", - "nginx", - "node", - "php", - "postgresql~16", - "sass", - "typescript", - "vite", - "vue~3", - "dom", - }, - }, - }, -} diff --git a/.config/nvim/lua/plugins/gitsigns.lua b/.config/nvim/lua/plugins/gitsigns.lua new file mode 100644 index 0000000..d6b52c2 --- /dev/null +++ b/.config/nvim/lua/plugins/gitsigns.lua @@ -0,0 +1,8 @@ +return { + { + "lewis6991/gitsigns.nvim", + dependencies = { + "sindrets/diffview.nvim", + }, + }, +} diff --git a/.config/nvim/lua/plugins/lazygit.lua b/.config/nvim/lua/plugins/lazygit.lua new file mode 100644 index 0000000..c898cc8 --- /dev/null +++ b/.config/nvim/lua/plugins/lazygit.lua @@ -0,0 +1,6 @@ +return { + { + "kdheepak/lazygit.nvim", + cmd = "LazyGit", + }, +} diff --git a/.config/nvim/lua/plugins/linting.lua b/.config/nvim/lua/plugins/linting.lua deleted file mode 100644 index 492bee5..0000000 --- a/.config/nvim/lua/plugins/linting.lua +++ /dev/null @@ -1,19 +0,0 @@ -return { - "mfussenegger/nvim-lint", - opts = { - linters_by_ft = { - gitcommit = { "commitlint" }, - sql = { "sqlfluff" }, - yaml = { "yamllint" }, - bash = { "shellcheck" }, - sh = { "shellcheck" }, - }, - linters = { - commitlint = { - args = { - "--config ~/.config/git/commitlint.config.js", - }, - }, - }, - }, -} diff --git a/.config/nvim/lua/plugins/luasnip.lua b/.config/nvim/lua/plugins/luasnip.lua new file mode 100644 index 0000000..974ad8b --- /dev/null +++ b/.config/nvim/lua/plugins/luasnip.lua @@ -0,0 +1,16 @@ +return { + { + "L3MON4D3/LuaSnip", + keys = { { "" } }, + opts = { + store_selection_keys = "", + }, + config = function(_, opts) + local luasnip = require("luasnip") + + luasnip.setup(opts) + + luasnip.loaders.from_lua.lazy_load({ lazy_paths = { "~/.config/nvim/lua/snippets" } }) + end, + }, +} diff --git a/.config/nvim/lua/plugins/mason-lspconfig.lua b/.config/nvim/lua/plugins/mason-lspconfig.lua new file mode 100644 index 0000000..5564054 --- /dev/null +++ b/.config/nvim/lua/plugins/mason-lspconfig.lua @@ -0,0 +1,12 @@ +return { + { + "williamboman/mason-lspconfig.nvim", + dependencies = { + "williamboman/mason.nvim", + "neovim/nvim-lspconfig", + }, + opts = { + automatic_installation = true, + }, + }, +} diff --git a/.config/nvim/lua/plugins/mason.lua b/.config/nvim/lua/plugins/mason.lua new file mode 100644 index 0000000..72d030c --- /dev/null +++ b/.config/nvim/lua/plugins/mason.lua @@ -0,0 +1,24 @@ +return { + { + "williamboman/mason.nvim", + opts = { + ensure_installed = { + -- general + "commitlint", + "prettier", + + -- data/conf + "yamllint", + + -- php + "blade-formatter", + "pint", + "rustywind", + + -- shell + "shellcheck", + "shfmt", + }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/neo-tree.lua b/.config/nvim/lua/plugins/neo-tree.lua new file mode 100644 index 0000000..067f2b3 --- /dev/null +++ b/.config/nvim/lua/plugins/neo-tree.lua @@ -0,0 +1,18 @@ +return { + { + "nvim-neo-tree/neo-tree.nvim", + opts = { + close_if_last_window = true, + window = { + width = 30, + }, + filesystem = { + filtered_items = { + hide_dotfiles = false, + hide_gitignored = false, + hide_hidden = false, + }, + }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/nerdy.lua b/.config/nvim/lua/plugins/nerdy.lua new file mode 100644 index 0000000..aead6dc --- /dev/null +++ b/.config/nvim/lua/plugins/nerdy.lua @@ -0,0 +1,9 @@ +return { + { + "2kabhishek/nerdy.nvim", + cmd = "Nerdy", + keys = { + { "ci", "Nerdy", desc = "Pick Icon" }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/coding.lua b/.config/nvim/lua/plugins/nvim-cmp.lua similarity index 69% rename from .config/nvim/lua/plugins/coding.lua rename to .config/nvim/lua/plugins/nvim-cmp.lua index 215b1a8..4599e44 100644 --- a/.config/nvim/lua/plugins/coding.lua +++ b/.config/nvim/lua/plugins/nvim-cmp.lua @@ -1,21 +1,9 @@ local cmp = require("cmp") return { - { - "L3MON4D3/LuaSnip", - keys = { { "" } }, - opts = { - store_selection_keys = "", - }, - config = function(_, opts) - require("luasnip").setup(opts) - - require("luasnip.loaders.from_lua").lazy_load({ lazy_paths = { "~/.config/nvim/lua/snippets" } }) - end, - }, - { "hrsh7th/nvim-cmp", + dependencies = { "hrsh7th/cmp-emoji" }, opts = function(_, opts) opts.mapping = cmp.mapping.preset.insert({ [""] = cmp.mapping.select_next_item({ behavior = cmp.SelectBehavior.Insert }), @@ -35,21 +23,9 @@ return { end, }) + table.insert(opts.sources, { name = "emoji" }) + return opts end, }, - - { - "m-pilia/vim-pkgbuild", - ft = { "pkgbuild" }, - }, - - { - "jwalton512/vim-blade", - }, - - { - "tpope/vim-dotenv", - ft = { "dotenv" }, - }, } diff --git a/.config/nvim/lua/plugins/nvim-devdocs.lua b/.config/nvim/lua/plugins/nvim-devdocs.lua new file mode 100644 index 0000000..134797c --- /dev/null +++ b/.config/nvim/lua/plugins/nvim-devdocs.lua @@ -0,0 +1,36 @@ +return { + { + "luckasRanarison/nvim-devdocs", + dependencies = { + "nvim-lua/plenary.nvim", + "nvim-telescope/telescope.nvim", + "nvim-treesitter/nvim-treesitter", + }, + opts = { + ensure_installed = { + "bash", + "bootstrap~5", + "css", + "eslint", + "fish~3.7", + "html", + "http", + "javascript", + "laravel~10", + "liquid", + "lodash~4", + "lua~5.4", + "markdown", + "nginx", + "node", + "php", + "postgresql~16", + "sass", + "typescript", + "vite", + "vue~3", + "dom", + }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/nvim-emmet.lua b/.config/nvim/lua/plugins/nvim-emmet.lua new file mode 100644 index 0000000..7494ebf --- /dev/null +++ b/.config/nvim/lua/plugins/nvim-emmet.lua @@ -0,0 +1,9 @@ +return { + { + "olrtg/nvim-emmet", + config = function() + vim.keymap.set({ "n", "v" }, "xe", require("nvim-emmet").wrap_with_abbreviation) + end, + ft = { "html", "css", "scss", "vue" }, + }, +} diff --git a/.config/nvim/lua/plugins/nvim-lint.lua b/.config/nvim/lua/plugins/nvim-lint.lua new file mode 100644 index 0000000..fdfe2f9 --- /dev/null +++ b/.config/nvim/lua/plugins/nvim-lint.lua @@ -0,0 +1,21 @@ +return { + { + "mfussenegger/nvim-lint", + opts = { + linters_by_ft = { + gitcommit = { "commitlint" }, + sql = { "sqlfluff" }, + yaml = { "yamllint" }, + bash = { "shellcheck" }, + sh = { "shellcheck" }, + }, + linters = { + commitlint = { + args = { + "--config ~/.config/git/commitlint.config.js", + }, + }, + }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/lsp.lua b/.config/nvim/lua/plugins/nvim-lspconfig.lua similarity index 79% rename from .config/nvim/lua/plugins/lsp.lua rename to .config/nvim/lua/plugins/nvim-lspconfig.lua index 50f59a7..1bf7b0f 100644 --- a/.config/nvim/lua/plugins/lsp.lua +++ b/.config/nvim/lua/plugins/nvim-lspconfig.lua @@ -1,34 +1,4 @@ return { - { - "williamboman/mason.nvim", - opts = { - ensure_installed = { - -- general - "commitlint", - "prettier", - - -- data/conf - "yamllint", - - -- php - "blade-formatter", - "pint", - "rustywind", - - -- shell - "shellcheck", - "shfmt", - }, - }, - }, - - { - "williamboman/mason-lspconfig.nvim", - opts = { - automatic_installation = true, - }, - }, - { "neovim/nvim-lspconfig", ---@class PluginLspOpts @@ -123,18 +93,4 @@ return { }, }, }, - - { - "olrtg/nvim-emmet", - config = function() - vim.keymap.set({ "n", "v" }, "xe", require("nvim-emmet").wrap_with_abbreviation) - end, - ft = { "html", "css", "scss", "vue" }, - }, - - { - "0oAstro/dim.lua", - event = "LspAttach", - config = true, - }, } diff --git a/.config/nvim/lua/plugins/treesitter.lua b/.config/nvim/lua/plugins/nvim-treesitter.lua similarity index 85% rename from .config/nvim/lua/plugins/treesitter.lua rename to .config/nvim/lua/plugins/nvim-treesitter.lua index 66289be..8f16f33 100644 --- a/.config/nvim/lua/plugins/treesitter.lua +++ b/.config/nvim/lua/plugins/nvim-treesitter.lua @@ -56,13 +56,4 @@ return { require("nvim-treesitter.configs").setup(opts) end, }, - - { - "Wansmer/treesj", - keys = { "m", "j", "s" }, - dependencies = { "nvim-treesitter/nvim-treesitter" }, - opts = { - max_join_length = 80, - }, - }, } diff --git a/.config/nvim/lua/plugins/refactoring.lua b/.config/nvim/lua/plugins/refactoring.lua new file mode 100644 index 0000000..153ee7d --- /dev/null +++ b/.config/nvim/lua/plugins/refactoring.lua @@ -0,0 +1,10 @@ +return { + { + "ThePrimeagen/refactoring.nvim", + dependencies = { + "nvim-lua/plenary.nvim", + "nvim-treesitter/nvim-treesitter", + }, + config = true, + }, +} diff --git a/.config/nvim/lua/plugins/ssr.lua b/.config/nvim/lua/plugins/ssr.lua new file mode 100644 index 0000000..0bb4f9c --- /dev/null +++ b/.config/nvim/lua/plugins/ssr.lua @@ -0,0 +1,15 @@ +return { + { + "cshuaimin/ssr.nvim", + keys = { + { + "sR", + function() + require("ssr").open() + end, + mode = { "n", "x" }, + desc = "Structural Replace", + }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/tabset.lua b/.config/nvim/lua/plugins/tabset.lua new file mode 100644 index 0000000..0d54768 --- /dev/null +++ b/.config/nvim/lua/plugins/tabset.lua @@ -0,0 +1,6 @@ +return { + { + "FotiadisM/tabset.nvim", + opts = require("config.tabset"), + }, +} diff --git a/.config/nvim/lua/plugins/treesj.lua b/.config/nvim/lua/plugins/treesj.lua new file mode 100644 index 0000000..c62e929 --- /dev/null +++ b/.config/nvim/lua/plugins/treesj.lua @@ -0,0 +1,10 @@ +return { + { + "Wansmer/treesj", + keys = { "m", "j", "s" }, + dependencies = { "nvim-treesitter/nvim-treesitter" }, + opts = { + max_join_length = 80, + }, + }, +} diff --git a/.config/nvim/lua/plugins/vim-blade.lua b/.config/nvim/lua/plugins/vim-blade.lua new file mode 100644 index 0000000..fb22e0f --- /dev/null +++ b/.config/nvim/lua/plugins/vim-blade.lua @@ -0,0 +1,6 @@ +return { + { + "jwalton512/vim-blade", + ft = { "blade" }, + }, +} diff --git a/.config/nvim/lua/plugins/vim-dotenv.lua b/.config/nvim/lua/plugins/vim-dotenv.lua new file mode 100644 index 0000000..418cd3e --- /dev/null +++ b/.config/nvim/lua/plugins/vim-dotenv.lua @@ -0,0 +1,6 @@ +return { + { + "tpope/vim-dotenv", + ft = { "dotenv" }, + }, +} diff --git a/.config/nvim/lua/plugins/vim-pkgbuild.lua b/.config/nvim/lua/plugins/vim-pkgbuild.lua new file mode 100644 index 0000000..e98146b --- /dev/null +++ b/.config/nvim/lua/plugins/vim-pkgbuild.lua @@ -0,0 +1,6 @@ +return { + { + "m-pilia/vim-pkgbuild", + ft = { "pkgbuild" }, + }, +} diff --git a/.config/nvim/lua/plugins/vim-tmux-navigator.lua b/.config/nvim/lua/plugins/vim-tmux-navigator.lua new file mode 100644 index 0000000..ce695d8 --- /dev/null +++ b/.config/nvim/lua/plugins/vim-tmux-navigator.lua @@ -0,0 +1,19 @@ +return { + { + "christoomey/vim-tmux-navigator", + cmd = { + "TmuxNavigateLeft", + "TmuxNavigateDown", + "TmuxNavigateUp", + "TmuxNavigateRight", + "TmuxNavigatePrevious", + }, + keys = { + { "", "TmuxNavigateLeft" }, + { "", "TmuxNavigateDown" }, + { "", "TmuxNavigateUp" }, + { "", "TmuxNavigateRight" }, + { "", "TmuxNavigatePrevious" }, + }, + }, +}