From aa687e1591e4977f875901a1bd5718fb9b4187f9 Mon Sep 17 00:00:00 2001 From: Adam French Date: Thu, 12 Mar 2026 15:19:52 +0000 Subject: [PATCH] Update nvim config: split plugins, update README Co-Authored-By: Claude Opus 4.6 --- nvim/README.md | 20 ++++++-- nvim/lazyvim.json | 44 ++++++++---------- nvim/lua/config/lazy.lua | 2 - nvim/lua/plugins/autopairs.lua | 7 +++ nvim/lua/plugins/claudecode.lua | 26 +++++++++++ nvim/lua/plugins/colorscheme.lua | 3 ++ nvim/lua/plugins/dap.lua | 3 ++ nvim/lua/plugins/harpoon.lua | 16 +++++++ nvim/lua/plugins/markview.lua | 11 +++++ nvim/lua/plugins/neogit.lua | 20 ++++++++ nvim/lua/plugins/plugins.lua | 72 ----------------------------- nvim/lua/plugins/snacks.lua | 35 ++++++++++++++ nvim/lua/plugins/spectre.lua | 11 +++++ nvim/lua/plugins/todo-comments.lua | 14 ++++++ nvim/lua/plugins/undotree.lua | 8 ++++ nvim/lua/plugins/whichkey.lua | 73 ++++++++++++++++++++++++++++++ 16 files changed, 264 insertions(+), 101 deletions(-) create mode 100644 nvim/lua/plugins/autopairs.lua create mode 100644 nvim/lua/plugins/claudecode.lua create mode 100644 nvim/lua/plugins/colorscheme.lua create mode 100644 nvim/lua/plugins/dap.lua create mode 100644 nvim/lua/plugins/harpoon.lua create mode 100644 nvim/lua/plugins/markview.lua create mode 100644 nvim/lua/plugins/neogit.lua delete mode 100644 nvim/lua/plugins/plugins.lua create mode 100644 nvim/lua/plugins/snacks.lua create mode 100644 nvim/lua/plugins/spectre.lua create mode 100644 nvim/lua/plugins/todo-comments.lua create mode 100644 nvim/lua/plugins/undotree.lua create mode 100644 nvim/lua/plugins/whichkey.lua diff --git a/nvim/README.md b/nvim/README.md index 185280b..466b4a9 100644 --- a/nvim/README.md +++ b/nvim/README.md @@ -1,4 +1,18 @@ -# đŸ’€ LazyVim +# Personal Neovim Config -A starter template for [LazyVim](https://github.com/LazyVim/LazyVim). -Refer to the [documentation](https://lazyvim.github.io/installation) to get started. +My personal Neovim configuration built on [LazyVim](https://github.com/LazyVim/LazyVim). + +## Current Setup + +- **Base**: LazyVim with Gruvbox colorscheme +- **AI**: Claude Code integration (`claudecode.nvim`) +- **UI**: Snacks dashboard (custom STP banner), Which-Key (helix preset) +- **Languages**: TypeScript, Vue, Python, Go, SQL, Tailwind, Docker +- **Extras**: mini-surround, Prettier formatting, git extras + +## Suggested Plugins to Add + +- **vim-fugitive** or **neogit** - deeper git workflow beyond LazyVim's built-in gitsigns +- **nvim-lint** - async linting beyond what LSP provides +- **oil.nvim** - file explorer that works like a buffer (edit filesystem like text) +- **zen-mode.nvim** - distraction-free writing/coding diff --git a/nvim/lazyvim.json b/nvim/lazyvim.json index 12a4694..1a7406d 100644 --- a/nvim/lazyvim.json +++ b/nvim/lazyvim.json @@ -1,25 +1,21 @@ { - "extras": [ - "lazyvim.plugins.extras.ai.claudecode", - "lazyvim.plugins.extras.ai.copilot", - "lazyvim.plugins.extras.coding.mini-surround", - "lazyvim.plugins.extras.editor.dial", - "lazyvim.plugins.extras.formatting.prettier", - "lazyvim.plugins.extras.lang.docker", - "lazyvim.plugins.extras.lang.git", - "lazyvim.plugins.extras.lang.go", - "lazyvim.plugins.extras.lang.python", - "lazyvim.plugins.extras.lang.sql", - "lazyvim.plugins.extras.lang.tailwind", - "lazyvim.plugins.extras.lang.typescript", - "lazyvim.plugins.extras.lang.vue", - "lazyvim.plugins.extras.ui.edgy", - "lazyvim.plugins.extras.util.dot", - "lazyvim.plugins.extras.util.gitui" - ], - "install_version": 8, - "news": { - "NEWS.md": "11866" - }, - "version": 8 -} \ No newline at end of file + "extras": [ + "lazyvim.plugins.extras.ai.claudecode", + "lazyvim.plugins.extras.coding.mini-surround", + "lazyvim.plugins.extras.formatting.prettier", + "lazyvim.plugins.extras.lang.docker", + "lazyvim.plugins.extras.lang.git", + "lazyvim.plugins.extras.lang.go", + "lazyvim.plugins.extras.lang.python", + "lazyvim.plugins.extras.lang.sql", + "lazyvim.plugins.extras.lang.tailwind", + "lazyvim.plugins.extras.lang.typescript", + "lazyvim.plugins.extras.lang.vue" + ], + "install_version": 8, + "news": { + "NEWS.md": "11866" + }, + "version": 8 +} + diff --git a/nvim/lua/config/lazy.lua b/nvim/lua/config/lazy.lua index d73bfa1..c2c0bb9 100644 --- a/nvim/lua/config/lazy.lua +++ b/nvim/lua/config/lazy.lua @@ -16,9 +16,7 @@ vim.opt.rtp:prepend(lazypath) require("lazy").setup({ spec = { - -- add LazyVim and import its plugins { "LazyVim/LazyVim", import = "lazyvim.plugins" }, - -- import/override with your plugins { import = "plugins" }, }, defaults = { diff --git a/nvim/lua/plugins/autopairs.lua b/nvim/lua/plugins/autopairs.lua new file mode 100644 index 0000000..a0fb1f2 --- /dev/null +++ b/nvim/lua/plugins/autopairs.lua @@ -0,0 +1,7 @@ +return { + { + "windwp/nvim-autopairs", + event = "InsertEnter", + opts = {}, + }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/claudecode.lua b/nvim/lua/plugins/claudecode.lua new file mode 100644 index 0000000..2b10879 --- /dev/null +++ b/nvim/lua/plugins/claudecode.lua @@ -0,0 +1,26 @@ +return { + { + "coder/claudecode.nvim", + dependencies = { "folke/snacks.nvim" }, + config = true, + keys = { + { "a", nil, desc = "AI/Claude Code" }, + { "ac", "ClaudeCode", desc = "Toggle Claude" }, + { "af", "ClaudeCodeFocus", desc = "Focus Claude" }, + { "ar", "ClaudeCode --resume", desc = "Resume Claude" }, + { "aC", "ClaudeCode --continue", desc = "Continue Claude" }, + { "am", "ClaudeCodeSelectModel", desc = "Select Claude model" }, + { "ab", "ClaudeCodeAdd %", desc = "Add current buffer" }, + { "as", "ClaudeCodeSend", mode = "v", desc = "Send to Claude" }, + { + "as", + "ClaudeCodeTreeAdd", + desc = "Add file", + ft = { "NvimTree", "neo-tree", "oil", "minifiles", "netrw" }, + }, + -- Diff management + { "aa", "ClaudeCodeDiffAccept", desc = "Accept diff" }, + { "ad", "ClaudeCodeDiffDeny", desc = "Deny diff" }, + }, + }, +} diff --git a/nvim/lua/plugins/colorscheme.lua b/nvim/lua/plugins/colorscheme.lua new file mode 100644 index 0000000..5167df4 --- /dev/null +++ b/nvim/lua/plugins/colorscheme.lua @@ -0,0 +1,3 @@ +return { + { "ellisonleao/gruvbox.nvim" }, +} diff --git a/nvim/lua/plugins/dap.lua b/nvim/lua/plugins/dap.lua new file mode 100644 index 0000000..ff1921a --- /dev/null +++ b/nvim/lua/plugins/dap.lua @@ -0,0 +1,3 @@ +return { + { import = "lazyvim.plugins.extras.dap.core" }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/harpoon.lua b/nvim/lua/plugins/harpoon.lua new file mode 100644 index 0000000..a919e90 --- /dev/null +++ b/nvim/lua/plugins/harpoon.lua @@ -0,0 +1,16 @@ +return { + { + "ThePrimeagen/harpoon", + branch = "harpoon2", + dependencies = { "nvim-lua/plenary.nvim" }, + opts = {}, + keys = { + { "a", function() require("harpoon"):list():add() end, desc = "Harpoon Add File" }, + { "", function() local harpoon = require("harpoon") harpoon.ui:toggle_quick_menu(harpoon:list()) end, desc = "Harpoon Quick Menu" }, + { "", function() require("harpoon"):list():select(1) end, desc = "Harpoon File 1" }, + { "", function() require("harpoon"):list():select(2) end, desc = "Harpoon File 2" }, + { "", function() require("harpoon"):list():select(3) end, desc = "Harpoon File 3" }, + { "", function() require("harpoon"):list():select(4) end, desc = "Harpoon File 4" }, + }, + }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/markview.lua b/nvim/lua/plugins/markview.lua new file mode 100644 index 0000000..1de2d5a --- /dev/null +++ b/nvim/lua/plugins/markview.lua @@ -0,0 +1,11 @@ +return { + { + "OXY2DEV/markview.nvim", + ft = "markdown", + dependencies = { + "nvim-treesitter/nvim-treesitter", + "nvim-tree/nvim-web-devicons", + }, + opts = {}, + }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/neogit.lua b/nvim/lua/plugins/neogit.lua new file mode 100644 index 0000000..a5cd74e --- /dev/null +++ b/nvim/lua/plugins/neogit.lua @@ -0,0 +1,20 @@ +return { + { + "NeogitOrg/neogit", + dependencies = { + "nvim-lua/plenary.nvim", + "sindrets/diffview.nvim", + }, + keys = { + { "gg", function() require("neogit").open() end, desc = "Neogit" }, + { "gc", function() require("neogit").open({ "commit" }) end, desc = "Neogit Commit" }, + { "gl", function() require("neogit").open({ "log" }) end, desc = "Neogit Log" }, + { "gp", function() require("neogit").open({ "push" }) end, desc = "Neogit Push" }, + }, + opts = { + integrations = { + diffview = true, + }, + }, + }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/plugins.lua b/nvim/lua/plugins/plugins.lua deleted file mode 100644 index 6174eb0..0000000 --- a/nvim/lua/plugins/plugins.lua +++ /dev/null @@ -1,72 +0,0 @@ -return { - { "ellisonleao/gruvbox.nvim" }, - { - "LazyVim/LazyVim", - opts = { - colorscheme = "gruvbox", - }, - { - "kawre/leetcode.nvim", - dependencies = { - "nvim-lua/plenary.nvim", - "MunifTanjim/nui.nvim", - }, - opts = { - lang = "rust", - - keys = { - toggle = { "q" }, ---@type string|string[] - confirm = { "" }, ---@type string|string[] - - reset_testcases = "r", ---@type string - use_testcase = "U", ---@type string - focus_testcases = "H", ---@type string - focus_result = "L", ---@type string - }, - }, - }, - }, - -- { - -- "yetone/avante.nvim", - -- build = vim.fn.has("win32") ~= 0 and "powershell -ExecutionPolicy Bypass -File Build.ps1 -BuildFromSource false" - -- or "make", - -- event = "VeryLazy", - -- opts = { - -- provider = "copilot", - -- selection = { - -- hint_display = "none", - -- }, - -- behaviour = { - -- auto_set_keymaps = false, - -- }, - -- }, - -- cmd = { - -- "AvanteAsk", - -- "AvanteBuild", - -- "AvanteChat", - -- "AvanteClear", - -- "AvanteEdit", - -- "AvanteFocus", - -- "AvanteHistory", - -- "AvanteModels", - -- "AvanteRefresh", - -- "AvanteShowRepoMap", - -- "AvanteStop", - -- "AvanteSwitchProvider", - -- "AvanteToggle", - -- }, - -- keys = { - -- { "aa", "AvanteAsk", desc = "Ask Avante" }, - -- { "ac", "AvanteChat", desc = "Chat with Avante" }, - -- { "ae", "AvanteEdit", desc = "Edit Avante" }, - -- { "af", "AvanteFocus", desc = "Focus Avante" }, - -- { "ah", "AvanteHistory", desc = "Avante History" }, - -- { "am", "AvanteModels", desc = "Select Avante Model" }, - -- { "an", "AvanteChatNew", desc = "New Avante Chat" }, - -- { "ap", "AvanteSwitchProvider", desc = "Switch Avante Provider" }, - -- { "ar", "AvanteRefresh", desc = "Refresh Avante" }, - -- { "as", "AvanteStop", desc = "Stop Avante" }, - -- { "at", "AvanteToggle", desc = "Toggle Avante" }, - -- }, - -- }, -} diff --git a/nvim/lua/plugins/snacks.lua b/nvim/lua/plugins/snacks.lua new file mode 100644 index 0000000..249c0e7 --- /dev/null +++ b/nvim/lua/plugins/snacks.lua @@ -0,0 +1,35 @@ +return { + { + "snacks.nvim", + opts = { + dashboard = { + preset = { + pick = function(cmd, opts) + return LazyVim.pick(cmd, opts)() + end, + header = [[ + ███████╗████████╗██████╗ + ██╔════╝╚══██╔══╝██╔══██╗ + ███████╗ ██║ ██████╔╝ + ╚════██║ ██║ ██╔═══╝ + ███████║ ██║ ██║ + ╚══════╝ ╚═╝ ╚═╝ + ]], + -- stylua: ignore + ---@type snacks.dashboard.Item[] + keys = { + { icon = " ", key = "f", desc = "Find File", action = ":lua Snacks.dashboard.pick('files')" }, + { icon = " ", key = "n", desc = "New File", action = ":ene | startinsert" }, + { icon = "ï€ą ", key = "g", desc = "Find Text", action = ":lua Snacks.dashboard.pick('live_grep')" }, + { icon = " ", key = "r", desc = "Recent Files", action = ":lua Snacks.dashboard.pick('oldfiles')" }, + { icon = "ïŁ ", key = "c", desc = "Config", action = ":lua Snacks.dashboard.pick('files', {cwd = vim.fn.stdpath('config')})" }, + { icon = " ", key = "s", desc = "Restore Session", section = "session" }, + { icon = "îȘŒ ", key = "x", desc = "Lazy Extras", action = ":LazyExtras" }, + { icon = "ó°’Č ", key = "l", desc = "Lazy", action = ":Lazy" }, + { icon = " ", key = "q", desc = "Quit", action = ":qa" }, + }, + }, + }, + }, + }, +} diff --git a/nvim/lua/plugins/spectre.lua b/nvim/lua/plugins/spectre.lua new file mode 100644 index 0000000..0aea872 --- /dev/null +++ b/nvim/lua/plugins/spectre.lua @@ -0,0 +1,11 @@ +return { + { + "nvim-pack/nvim-spectre", + dependencies = { "nvim-lua/plenary.nvim" }, + keys = { + { "sr", function() require("spectre").open() end, desc = "Replace in Files (Spectre)" }, + { "sr", function() require("spectre").open_visual({ select_word = true }) end, mode = "v", desc = "Replace Word (Spectre)" }, + }, + opts = {}, + }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/todo-comments.lua b/nvim/lua/plugins/todo-comments.lua new file mode 100644 index 0000000..687d4ca --- /dev/null +++ b/nvim/lua/plugins/todo-comments.lua @@ -0,0 +1,14 @@ +return { + { + "folke/todo-comments.nvim", + event = "VeryLazy", + dependencies = { "nvim-lua/plenary.nvim" }, + opts = {}, + keys = { + { "]t", function() require("todo-comments").jump_next() end, desc = "Next Todo Comment" }, + { "[t", function() require("todo-comments").jump_prev() end, desc = "Prev Todo Comment" }, + { "xt", "Trouble todo", desc = "Todo (Trouble)" }, + { "st", "TodoTelescope", desc = "Todo" }, + }, + }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/undotree.lua b/nvim/lua/plugins/undotree.lua new file mode 100644 index 0000000..a33e110 --- /dev/null +++ b/nvim/lua/plugins/undotree.lua @@ -0,0 +1,8 @@ +return { + { + "mbbill/undotree", + keys = { + { "cu", "UndotreeToggle", desc = "Undotree Toggle" }, + }, + }, +} \ No newline at end of file diff --git a/nvim/lua/plugins/whichkey.lua b/nvim/lua/plugins/whichkey.lua new file mode 100644 index 0000000..1c5e3fa --- /dev/null +++ b/nvim/lua/plugins/whichkey.lua @@ -0,0 +1,73 @@ +return { + { + "folke/which-key.nvim", + event = "VeryLazy", + opts_extend = { "spec" }, + opts = { + preset = "helix", + defaults = {}, + spec = { + { + mode = { "n", "x" }, + { "", group = "tabs" }, + { "c", group = "code" }, + { "d", group = "debug" }, + { "dp", group = "profiler" }, + { "f", group = "file/find" }, + { "g", group = "git" }, + { "gh", group = "hunks" }, + { "q", group = "quit/session" }, + { "s", group = "search" }, + { "u", group = "ui" }, + { "x", group = "diagnostics/quickfix" }, + { "[", group = "prev" }, + { "]", group = "next" }, + { "g", group = "goto" }, + { "gs", group = "surround" }, + { "z", group = "fold" }, + { + "b", + group = "buffer", + expand = function() + return require("which-key.extras").expand.buf() + end, + }, + { + "w", + group = "windows", + proxy = "", + expand = function() + return require("which-key.extras").expand.win() + end, + }, + -- better descriptions + { "gx", desc = "Open with system app" }, + }, + }, + }, + keys = { + { + "?", + function() + require("which-key").show({ global = false }) + end, + desc = "Buffer Keymaps (which-key)", + }, + { + "", + function() + require("which-key").show({ keys = "", loop = true }) + end, + desc = "Window Hydra Mode (which-key)", + }, + }, + config = function(_, opts) + local wk = require("which-key") + wk.setup(opts) + if not vim.tbl_isempty(opts.defaults) then + LazyVim.warn("which-key: opts.defaults is deprecated. Please use opts.spec instead.") + wk.register(opts.defaults) + end + end, + }, +}