From 65ed47dbd41b0719d9b16c93086ae8becd6d81cc Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sat, 22 Nov 2025 22:06:26 +0100 Subject: [PATCH 01/39] explorer on the right --- lazy-lock.json | 35 +++++++++++++++++++++++++++ lazyvim.json | 10 ++++++++ lua/plugins/snacks.lua | 55 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 100 insertions(+) create mode 100644 lazy-lock.json create mode 100644 lazyvim.json create mode 100644 lua/plugins/snacks.lua diff --git a/lazy-lock.json b/lazy-lock.json new file mode 100644 index 0000000..b0ddee7 --- /dev/null +++ b/lazy-lock.json @@ -0,0 +1,35 @@ +{ + "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, + "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, + "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, + "catppuccin": { "branch": "main", "commit": "da33755d00e09bff2473978910168ff9ea5dc453" }, + "conform.nvim": { "branch": "master", "commit": "afce105eb47b0869dfafdac90d82f02ef2419d61" }, + "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, + "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, + "gitsigns.nvim": { "branch": "main", "commit": "cdafc320f03f2572c40ab93a4eecb733d4016d07" }, + "grug-far.nvim": { "branch": "main", "commit": "b58b2d65863f4ebad88b10a1ddd519e5380466e0" }, + "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, + "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, + "lualine.nvim": { "branch": "master", "commit": "3946f0122255bc377d14a59b27b609fb3ab25768" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "7d527c76c43f46294de9c19d39c5a86317809b4b" }, + "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, + "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, + "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, + "mini.pairs": { "branch": "main", "commit": "b316e68f2d242d5bd010deaab645daa27ed86297" }, + "neo-tree.nvim": { "branch": "main", "commit": "a981ef287503c668434bffa78071d5b9ff92c12f" }, + "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, + "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, + "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, + "nvim-lspconfig": { "branch": "master", "commit": "a2a277114dbb93e98f04b5087a9b832918b7da15" }, + "nvim-treesitter": { "branch": "main", "commit": "bb83a676128d95c865e40ba71376d883bdadec14" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, + "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, + "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, + "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, + "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, + "todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" }, + "tokyonight.nvim": { "branch": "main", "commit": "5da1b76e64daf4c5d410f06bcb6b9cb640da7dfd" }, + "trouble.nvim": { "branch": "main", "commit": "bd67efe408d4816e25e8491cc5ad4088e708a69a" }, + "ts-comments.nvim": { "branch": "main", "commit": "123a9fb12e7229342f807ec9e6de478b1102b041" }, + "which-key.nvim": { "branch": "main", "commit": "3aab2147e74890957785941f0c1ad87d0a44c15a" } +} diff --git a/lazyvim.json b/lazyvim.json new file mode 100644 index 0000000..d8bcaf6 --- /dev/null +++ b/lazyvim.json @@ -0,0 +1,10 @@ +{ + "extras": [ + + ], + "install_version": 8, + "news": { + "NEWS.md": "11866" + }, + "version": 8 +} \ No newline at end of file diff --git a/lua/plugins/snacks.lua b/lua/plugins/snacks.lua new file mode 100644 index 0000000..3cc8ddb --- /dev/null +++ b/lua/plugins/snacks.lua @@ -0,0 +1,55 @@ +return { + -- Import the snacks explorer extra + { import = "lazyvim.plugins.extras.editor.snacks_explorer" }, + + -- Configure snacks.nvim + { + "folke/snacks.nvim", + keys = { + { + "\\", + function() + Snacks.explorer() + end, + desc = "Toggle Snacks Explorer (Picker)", + }, + { "e", false }, + }, + opts = { + scroll = { + enabled = false, -- Disable scrolling animations + }, + picker = { + sources = { + explorer = { + hidden = false, -- Show hidden files by default + layout = { preset = "right" }, -- Position on the right + ignored = false, + git_status = true, -- Show git status + diagnostics = true, -- Show diagnostics + follow_file = true, -- Follow current file + win = { + list = { + keys = { + ["P"] = "toggle_preview", -- Custom key + ["L"] = function() + -- Get current line and try to extract file path + local line = vim.api.nvim_get_current_line() + local filepath = line:match("%s*(.-)%s*$") -- trim whitespace + + if filepath and vim.fn.filereadable(filepath) == 1 then + local explorer_win = vim.api.nvim_get_current_win() + vim.cmd("wincmd p") + vim.cmd("edit " .. vim.fn.fnameescape(filepath)) + vim.api.nvim_set_current_win(explorer_win) + end + end, + }, + }, + }, + }, + }, + }, + }, + }, +} From 92ed9fd5fb4d500c8b983f0365d6525fdfae7382 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sat, 22 Nov 2025 23:34:42 +0100 Subject: [PATCH 02/39] typescript and telescope edits --- lazy-lock.json | 2 +- lua/plugins/telescope.lua | 3 +++ lua/plugins/typescript-tools.lua | 7 +++++++ lua/plugins/typescript.lua | 3 +++ 4 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 lua/plugins/telescope.lua create mode 100644 lua/plugins/typescript-tools.lua create mode 100644 lua/plugins/typescript.lua diff --git a/lazy-lock.json b/lazy-lock.json index b0ddee7..9f86bd0 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -16,7 +16,6 @@ "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, "mini.pairs": { "branch": "main", "commit": "b316e68f2d242d5bd010deaab645daa27ed86297" }, - "neo-tree.nvim": { "branch": "main", "commit": "a981ef287503c668434bffa78071d5b9ff92c12f" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, @@ -31,5 +30,6 @@ "tokyonight.nvim": { "branch": "main", "commit": "5da1b76e64daf4c5d410f06bcb6b9cb640da7dfd" }, "trouble.nvim": { "branch": "main", "commit": "bd67efe408d4816e25e8491cc5ad4088e708a69a" }, "ts-comments.nvim": { "branch": "main", "commit": "123a9fb12e7229342f807ec9e6de478b1102b041" }, + "typescript-tools.nvim": { "branch": "master", "commit": "c2f5910074103705661e9651aa841e0d7eea9932" }, "which-key.nvim": { "branch": "main", "commit": "3aab2147e74890957785941f0c1ad87d0a44c15a" } } diff --git a/lua/plugins/telescope.lua b/lua/plugins/telescope.lua new file mode 100644 index 0000000..9ebf6b5 --- /dev/null +++ b/lua/plugins/telescope.lua @@ -0,0 +1,3 @@ +return { + { import = "lazyvim.plugins.extras.editor.telescope" }, +} diff --git a/lua/plugins/typescript-tools.lua b/lua/plugins/typescript-tools.lua new file mode 100644 index 0000000..0acfc05 --- /dev/null +++ b/lua/plugins/typescript-tools.lua @@ -0,0 +1,7 @@ +-- return { +-- "pmizio/typescript-tools.nvim", +-- dependencies = { "nvim-lua/plenary.nvim" }, +-- event = { "BufReadPre", "BufNewFile" }, +-- ft = { "typescript", "javascript" }, +-- opts = {}, +-- } diff --git a/lua/plugins/typescript.lua b/lua/plugins/typescript.lua new file mode 100644 index 0000000..f5c77bd --- /dev/null +++ b/lua/plugins/typescript.lua @@ -0,0 +1,3 @@ +return { + { import = "lazyvim.plugins.extras.lang.typescript" }, +} From 0175469f55e5f110f4f697c6f734b2f11384501f Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sat, 22 Nov 2025 22:53:10 +0000 Subject: [PATCH 03/39] typescript-tools instead of vtsls --- lua/plugins/typescript-tools.lua | 7 ------- lua/plugins/typescript.lua | 23 ++++++++++++++++++++++- 2 files changed, 22 insertions(+), 8 deletions(-) delete mode 100644 lua/plugins/typescript-tools.lua diff --git a/lua/plugins/typescript-tools.lua b/lua/plugins/typescript-tools.lua deleted file mode 100644 index 0acfc05..0000000 --- a/lua/plugins/typescript-tools.lua +++ /dev/null @@ -1,7 +0,0 @@ --- return { --- "pmizio/typescript-tools.nvim", --- dependencies = { "nvim-lua/plenary.nvim" }, --- event = { "BufReadPre", "BufNewFile" }, --- ft = { "typescript", "javascript" }, --- opts = {}, --- } diff --git a/lua/plugins/typescript.lua b/lua/plugins/typescript.lua index f5c77bd..f5f7891 100644 --- a/lua/plugins/typescript.lua +++ b/lua/plugins/typescript.lua @@ -1,3 +1,24 @@ return { - { import = "lazyvim.plugins.extras.lang.typescript" }, + -- disable vtsls + { + "neovim/nvim-lspconfig", + opts = { + servers = { + vtsls = false, + tsserver = false, + }, + }, + }, + + -- enable typescript-tools + { + "pmizio/typescript-tools.nvim", + ft = { + "typescript", + "typescriptreact", + "javascript", + "javascriptreact", + }, + opts = {}, + }, } From 118453110e1deca0e76075762b99b9628a8cd91e Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sat, 22 Nov 2025 23:43:19 +0000 Subject: [PATCH 04/39] toggle term, git improvements, keymaps... --- lazy-lock.json | 1 + lua/config/keymaps.lua | 10 ++++++++++ lua/config/options.lua | 5 +++++ lua/plugins/git.lua | 15 +++++++++++++++ lua/plugins/toggle-term.lua | 18 ++++++++++++++++++ 5 files changed, 49 insertions(+) create mode 100644 lua/plugins/git.lua create mode 100644 lua/plugins/toggle-term.lua diff --git a/lazy-lock.json b/lazy-lock.json index 9f86bd0..dfc586b 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -27,6 +27,7 @@ "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, "todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" }, + "toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" }, "tokyonight.nvim": { "branch": "main", "commit": "5da1b76e64daf4c5d410f06bcb6b9cb640da7dfd" }, "trouble.nvim": { "branch": "main", "commit": "bd67efe408d4816e25e8491cc5ad4088e708a69a" }, "ts-comments.nvim": { "branch": "main", "commit": "123a9fb12e7229342f807ec9e6de478b1102b041" }, diff --git a/lua/config/keymaps.lua b/lua/config/keymaps.lua index 2c134f7..a1ad03e 100644 --- a/lua/config/keymaps.lua +++ b/lua/config/keymaps.lua @@ -1,3 +1,13 @@ -- Keymaps are automatically loaded on the VeryLazy event -- Default keymaps that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/keymaps.lua -- Add any additional keymaps here + +---- Move lines +vim.keymap.set("v", "J", ":m '>+1gv=gv") +vim.keymap.set("v", "K", ":m '<-2gv=gv") + +-- Cursor in middle when jumping +vim.keymap.set("n", "", "zz") +vim.keymap.set("n", "", "zz") +vim.keymap.set("n", "n", "nzzzv") +vim.keymap.set("n", "N", "Nzzzv") diff --git a/lua/config/options.lua b/lua/config/options.lua index 3ea1454..95b6d74 100644 --- a/lua/config/options.lua +++ b/lua/config/options.lua @@ -1,3 +1,8 @@ -- Options are automatically loaded before lazy.nvim startup -- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua -- Add any additional options here +vim.schedule(function() + vim.o.clipboard = "unnamedplus" +end) + +vim.o.scrolloff = 10 diff --git a/lua/plugins/git.lua b/lua/plugins/git.lua new file mode 100644 index 0000000..e677e2c --- /dev/null +++ b/lua/plugins/git.lua @@ -0,0 +1,15 @@ +return { + { + "lewis6991/gitsigns.nvim", + keys = { + -- Override LazyVim Git Blame popup with inline toggle + { + "tb", + function() + require("gitsigns").toggle_current_line_blame() + end, + desc = "Toggle Inline Blame", + }, + }, + }, +} diff --git a/lua/plugins/toggle-term.lua b/lua/plugins/toggle-term.lua new file mode 100644 index 0000000..7dd3627 --- /dev/null +++ b/lua/plugins/toggle-term.lua @@ -0,0 +1,18 @@ +return { + "akinsho/toggleterm.nvim", + version = "*", + + keys = { + { "tt", "ToggleTerm direction=float", desc = "Toggle Terminal" }, + }, + + opts = { + open_mapping = [[tt]], + direction = "float", + float_opts = { border = "rounded" }, + }, + + config = function(_, opts) + require("toggleterm").setup(opts) + end, +} From e2bc0d8e2b3fb265e5e8654aace620264596c662 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sun, 23 Nov 2025 01:58:22 +0100 Subject: [PATCH 05/39] transparency --- lazy-lock.json | 1 + lua/plugins/transparency.lua | 61 ++++++++++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+) create mode 100644 lua/plugins/transparency.lua diff --git a/lazy-lock.json b/lazy-lock.json index dfc586b..082ddc0 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -29,6 +29,7 @@ "todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" }, "toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" }, "tokyonight.nvim": { "branch": "main", "commit": "5da1b76e64daf4c5d410f06bcb6b9cb640da7dfd" }, + "transparent.nvim": { "branch": "main", "commit": "8ac59883de84e9cd1850ea25cf087031c5ba7d54" }, "trouble.nvim": { "branch": "main", "commit": "bd67efe408d4816e25e8491cc5ad4088e708a69a" }, "ts-comments.nvim": { "branch": "main", "commit": "123a9fb12e7229342f807ec9e6de478b1102b041" }, "typescript-tools.nvim": { "branch": "master", "commit": "c2f5910074103705661e9651aa841e0d7eea9932" }, diff --git a/lua/plugins/transparency.lua b/lua/plugins/transparency.lua new file mode 100644 index 0000000..a771483 --- /dev/null +++ b/lua/plugins/transparency.lua @@ -0,0 +1,61 @@ +local function apply_transparency() + local groups = { + "Normal", + "NormalNC", + "NormalFloat", + "FloatBorder", + "SignColumn", + "LineNr", + "CursorLineNr", + "EndOfBuffer", + "TelescopeNormal", + "TelescopeBorder", + "TelescopePromptBorder", + "TelescopeResultsBorder", + "TelescopePreviewBorder", + "NeoTreeNormal", + "NeoTreeNormalNC", + "NeoTreeWinSeparator", + "NeoTreeEndOfBuffer", + "Pmenu", + "PmenuSel", + } + + for _, group in ipairs(groups) do + vim.api.nvim_set_hl(0, group, { bg = "none" }) + end +end + +return { + { + "LazyVim/LazyVim", + opts = { + colorscheme = function() + vim.cmd("colorscheme tokyonight") -- or your theme + apply_transparency() + end, + }, + }, + + -- Automatically re-apply transparency when UI elements refresh + { + "xiyaowong/transparent.nvim", + event = "VeryLazy", + config = function() + -- when floats open + vim.api.nvim_create_autocmd("User", { + pattern = { + "SnacksPickerOpen", + "SnacksPickerClose", + "LazyVimFloat", + }, + callback = apply_transparency, + }) + + -- when switching colorscheme + vim.api.nvim_create_autocmd("ColorScheme", { + callback = apply_transparency, + }) + end, + }, +} From 02c78f4433f71c9c495e6eabb65bc767751828f1 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sun, 23 Nov 2025 02:55:58 +0100 Subject: [PATCH 06/39] precognition.lua vim motion inline hints --- lazy-lock.json | 1 + lua/plugins/precognition.lua | 28 ++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100644 lua/plugins/precognition.lua diff --git a/lazy-lock.json b/lazy-lock.json index 082ddc0..85e52be 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -25,6 +25,7 @@ "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, + "precognition.nvim": { "branch": "main", "commit": "2aae2687207029b3611a0e19a289f9e1c7efbe16" }, "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, "todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" }, "toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" }, diff --git a/lua/plugins/precognition.lua b/lua/plugins/precognition.lua new file mode 100644 index 0000000..554ada0 --- /dev/null +++ b/lua/plugins/precognition.lua @@ -0,0 +1,28 @@ +return { + "tris203/precognition.nvim", + event = "VeryLazy", + opts = { + -- startVisible = true, + -- showBlankVirtLine = true, + -- highlightColor = { link = "Comment" }, + -- hints = { + -- Caret = { text = "^", prio = 2 }, + -- Dollar = { text = "$", prio = 1 }, + -- MatchingPair = { text = "%", prio = 5 }, + -- Zero = { text = "0", prio = 1 }, + -- w = { text = "w", prio = 10 }, + -- b = { text = "b", prio = 9 }, + -- e = { text = "e", prio = 8 }, + -- W = { text = "W", prio = 7 }, + -- B = { text = "B", prio = 6 }, + -- E = { text = "E", prio = 5 }, + -- }, + -- gutterHints = { + -- -- prio is not currently used for gutter hints + -- G = { text = "G", prio = 1 }, + -- gg = { text = "gg", prio = 1 }, + -- PrevParagraph = { text = "{", prio = 1 }, + -- NextParagraph = { text = "}", prio = 1 }, + -- }, + }, +} From e162fa9f4978c2394fc21784313ad99123917925 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sun, 23 Nov 2025 02:03:44 +0000 Subject: [PATCH 07/39] extra config for precognition --- lua/plugins/precognition.lua | 44 ++++++++++++++++++------------------ 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/lua/plugins/precognition.lua b/lua/plugins/precognition.lua index 554ada0..e667d1c 100644 --- a/lua/plugins/precognition.lua +++ b/lua/plugins/precognition.lua @@ -2,27 +2,27 @@ return { "tris203/precognition.nvim", event = "VeryLazy", opts = { - -- startVisible = true, - -- showBlankVirtLine = true, - -- highlightColor = { link = "Comment" }, - -- hints = { - -- Caret = { text = "^", prio = 2 }, - -- Dollar = { text = "$", prio = 1 }, - -- MatchingPair = { text = "%", prio = 5 }, - -- Zero = { text = "0", prio = 1 }, - -- w = { text = "w", prio = 10 }, - -- b = { text = "b", prio = 9 }, - -- e = { text = "e", prio = 8 }, - -- W = { text = "W", prio = 7 }, - -- B = { text = "B", prio = 6 }, - -- E = { text = "E", prio = 5 }, - -- }, - -- gutterHints = { - -- -- prio is not currently used for gutter hints - -- G = { text = "G", prio = 1 }, - -- gg = { text = "gg", prio = 1 }, - -- PrevParagraph = { text = "{", prio = 1 }, - -- NextParagraph = { text = "}", prio = 1 }, - -- }, + startVisible = true, + showBlankVirtLine = true, + highlightColor = { link = "Comment" }, + hints = { + Caret = { text = "^", prio = 2 }, + Dollar = { text = "$", prio = 1 }, + MatchingPair = { text = "%", prio = 5 }, + Zero = { text = "0", prio = 1 }, + w = { text = "w", prio = 10 }, + b = { text = "b", prio = 9 }, + e = { text = "e", prio = 8 }, + W = { text = "W", prio = 7 }, + B = { text = "B", prio = 6 }, + E = { text = "E", prio = 5 }, + }, + gutterHints = { + -- prio is not currently used for gutter hints + G = { text = "G", prio = 1 }, + gg = { text = "gg", prio = 1 }, + PrevParagraph = { text = "{", prio = 1 }, + NextParagraph = { text = "}", prio = 1 }, + }, }, } From 78786ce1aaa3032f6d993fab056d1ed192893faa Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 24 Nov 2025 10:22:57 +0100 Subject: [PATCH 08/39] precognition --- lazy-lock.json | 2 +- lua/config/keymaps.lua | 3 +++ lua/plugins/precognition.lua | 35 ++++++++++++++++++++++++++++++----- 3 files changed, 34 insertions(+), 6 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 85e52be..2c62a6d 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -10,7 +10,7 @@ "grug-far.nvim": { "branch": "main", "commit": "b58b2d65863f4ebad88b10a1ddd519e5380466e0" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, - "lualine.nvim": { "branch": "master", "commit": "3946f0122255bc377d14a59b27b609fb3ab25768" }, + "lualine.nvim": { "branch": "master", "commit": "e5459241bde5949305b9583bb4eedf322a2a8e7c" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "7d527c76c43f46294de9c19d39c5a86317809b4b" }, "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, diff --git a/lua/config/keymaps.lua b/lua/config/keymaps.lua index a1ad03e..dbe5fca 100644 --- a/lua/config/keymaps.lua +++ b/lua/config/keymaps.lua @@ -11,3 +11,6 @@ vim.keymap.set("n", "", "zz") vim.keymap.set("n", "", "zz") vim.keymap.set("n", "n", "nzzzv") vim.keymap.set("n", "N", "Nzzzv") + +-- Prcognition +vim.keymap.set("n", "tp", require("precognition").toggle) diff --git a/lua/plugins/precognition.lua b/lua/plugins/precognition.lua index e667d1c..035573f 100644 --- a/lua/plugins/precognition.lua +++ b/lua/plugins/precognition.lua @@ -1,4 +1,7 @@ return { + -- Other options + -- nvim-spider + -- leap.nvim "tris203/precognition.nvim", event = "VeryLazy", opts = { @@ -9,20 +12,42 @@ return { Caret = { text = "^", prio = 2 }, Dollar = { text = "$", prio = 1 }, MatchingPair = { text = "%", prio = 5 }, + Zero = { text = "0", prio = 1 }, + w = { text = "w", prio = 10 }, b = { text = "b", prio = 9 }, e = { text = "e", prio = 8 }, + ge = { text = "ge", prio = 7 }, W = { text = "W", prio = 7 }, B = { text = "B", prio = 6 }, E = { text = "E", prio = 5 }, + gE = { text = "gE", prio = 4 }, + + f = { text = "f", prio = 10 }, + F = { text = "F", prio = 9 }, + t = { text = "t", prio = 8 }, + T = { text = "T", prio = 7 }, + + ["("] = { text = "(", prio = 3 }, + [")"] = { text = ")", prio = 3 }, }, gutterHints = { - -- prio is not currently used for gutter hints - G = { text = "G", prio = 1 }, - gg = { text = "gg", prio = 1 }, - PrevParagraph = { text = "{", prio = 1 }, - NextParagraph = { text = "}", prio = 1 }, + G = { text = "G" }, + gg = { text = "gg" }, + PrevParagraph = { text = "{" }, + NextParagraph = { text = "}" }, + + Top = { text = "H" }, + Middle = { text = "M" }, + Bottom = { text = "L" }, + + SearchForward = { text = "/" }, + SearchBackward = { text = "?" }, + NextMatch = { text = "n" }, + PrevMatch = { text = "N" }, + + MarkJump = { text = "'" }, }, }, } From e24151ddf9107757cf7c94e67bb866bd8313f03c Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 24 Nov 2025 13:14:20 +0100 Subject: [PATCH 09/39] osc52 for remote env clipboard --- lazy-lock.json | 1 + lua/plugins/osc52.lua | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 lua/plugins/osc52.lua diff --git a/lazy-lock.json b/lazy-lock.json index 2c62a6d..1850972 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -20,6 +20,7 @@ "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, "nvim-lspconfig": { "branch": "master", "commit": "a2a277114dbb93e98f04b5087a9b832918b7da15" }, + "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, "nvim-treesitter": { "branch": "main", "commit": "bb83a676128d95c865e40ba71376d883bdadec14" }, "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, diff --git a/lua/plugins/osc52.lua b/lua/plugins/osc52.lua new file mode 100644 index 0000000..2e1ead2 --- /dev/null +++ b/lua/plugins/osc52.lua @@ -0,0 +1,19 @@ +return { + { + "ojroques/nvim-osc52", + config = function() + require("osc52").setup({ + max_length = 0, -- Maximum length of selection (0 for no limit) + silent = false, -- Disable message on successful copy + trim = false, -- Trim surrounding whitespaces before copy + }) + local function copy() + if (vim.v.event.operator == "y" or vim.v.event.operator == "d") and vim.v.event.regname == "" then + require("osc52").copy_register("") + end + end + + vim.api.nvim_create_autocmd("TextYankPost", { callback = copy }) + end, + }, +} From b6d19714e2bc9a9aee403f2d9dd239a649bcb3ba Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 24 Nov 2025 12:15:50 +0000 Subject: [PATCH 10/39] lazy-lock sync --- lazy-lock.json | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 1850972..b40820d 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -3,14 +3,14 @@ "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, "catppuccin": { "branch": "main", "commit": "da33755d00e09bff2473978910168ff9ea5dc453" }, - "conform.nvim": { "branch": "master", "commit": "afce105eb47b0869dfafdac90d82f02ef2419d61" }, + "conform.nvim": { "branch": "master", "commit": "6208aefd675939cc7c8f1a57176135974dad269f" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, "gitsigns.nvim": { "branch": "main", "commit": "cdafc320f03f2572c40ab93a4eecb733d4016d07" }, "grug-far.nvim": { "branch": "main", "commit": "b58b2d65863f4ebad88b10a1ddd519e5380466e0" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, - "lualine.nvim": { "branch": "master", "commit": "e5459241bde5949305b9583bb4eedf322a2a8e7c" }, + "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "7d527c76c43f46294de9c19d39c5a86317809b4b" }, "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, @@ -19,9 +19,14 @@ "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, +<<<<<<< Updated upstream "nvim-lspconfig": { "branch": "master", "commit": "a2a277114dbb93e98f04b5087a9b832918b7da15" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, "nvim-treesitter": { "branch": "main", "commit": "bb83a676128d95c865e40ba71376d883bdadec14" }, +======= + "nvim-lspconfig": { "branch": "master", "commit": "30a2b191bccf541ce1797946324c9329e90ec448" }, + "nvim-treesitter": { "branch": "main", "commit": "3bbae7b32e0cc417438e54ec77eb7083e5f38c0f" }, +>>>>>>> Stashed changes "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, From 514bf0e35ea6646fe0a8d9e4f7710bdb476016e2 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 25 Nov 2025 09:37:38 +0100 Subject: [PATCH 11/39] semantic highlighting disable --- lua/config/options.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lua/config/options.lua b/lua/config/options.lua index 95b6d74..1396c2b 100644 --- a/lua/config/options.lua +++ b/lua/config/options.lua @@ -6,3 +6,6 @@ vim.schedule(function() end) vim.o.scrolloff = 10 + +-- Semantic highlighting +vim.g.lazyvim_semantic_highlighting = false From 71b5b326f19e67cb9bfd5d2342cf4e79fed4b491 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 25 Nov 2025 08:39:40 +0000 Subject: [PATCH 12/39] lock sync --- lazy-lock.json | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index b40820d..d6d6dbc 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -19,14 +19,9 @@ "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, -<<<<<<< Updated upstream - "nvim-lspconfig": { "branch": "master", "commit": "a2a277114dbb93e98f04b5087a9b832918b7da15" }, - "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "bb83a676128d95c865e40ba71376d883bdadec14" }, -======= "nvim-lspconfig": { "branch": "master", "commit": "30a2b191bccf541ce1797946324c9329e90ec448" }, + "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, "nvim-treesitter": { "branch": "main", "commit": "3bbae7b32e0cc417438e54ec77eb7083e5f38c0f" }, ->>>>>>> Stashed changes "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, From 6f39b5d1d376237346787b787277f5228b8b44ad Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 25 Nov 2025 17:29:54 +0000 Subject: [PATCH 13/39] lock sync --- lazy-lock.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index d6d6dbc..36658c7 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -2,8 +2,8 @@ "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "da33755d00e09bff2473978910168ff9ea5dc453" }, - "conform.nvim": { "branch": "master", "commit": "6208aefd675939cc7c8f1a57176135974dad269f" }, + "catppuccin": { "branch": "main", "commit": "180e0435707cf1fed09a98a9739e5807d92b69be" }, + "conform.nvim": { "branch": "master", "commit": "4993e07fac6679d0a5005aa7499e0bad2bd39f19" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, "gitsigns.nvim": { "branch": "main", "commit": "cdafc320f03f2572c40ab93a4eecb733d4016d07" }, From c1254fd7a657bd590d212781129e98eb7267eb9f Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 25 Nov 2025 17:43:06 +0000 Subject: [PATCH 14/39] tsserver safety buffer exits and settings --- lua/config/options.lua | 7 +++++++ lua/plugins/typescript.lua | 15 ++++++++++++++- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/lua/config/options.lua b/lua/config/options.lua index 1396c2b..e3c1d7d 100644 --- a/lua/config/options.lua +++ b/lua/config/options.lua @@ -9,3 +9,10 @@ vim.o.scrolloff = 10 -- Semantic highlighting vim.g.lazyvim_semantic_highlighting = false + +-- Kill any orphaned tsserver processes when Neovim exits +vim.api.nvim_create_autocmd("ExitPre", { + callback = function() + vim.fn.system("pkill -f 'tsserver.js'") + end, +}) diff --git a/lua/plugins/typescript.lua b/lua/plugins/typescript.lua index f5f7891..98bd3c0 100644 --- a/lua/plugins/typescript.lua +++ b/lua/plugins/typescript.lua @@ -19,6 +19,19 @@ return { "javascript", "javascriptreact", }, - opts = {}, + opts = { + settings = { + tsserver_file_preferences = { + disableSuggestions = false, + includeInlayParameterNameHints = "all", + includeCompletionsForModuleExports = true, + }, + tsserver_enable_partial_semantic_mode = true, + tsserver_watch_options = { + watchFile = "useFsEvents", -- recommended for remote/container + watchDirectory = "useFsEvents", + }, + }, + }, }, } From 84f8aa2b36ca602e2bcbcd33d953b37f65e29f7a Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sun, 30 Nov 2025 15:48:15 +0100 Subject: [PATCH 15/39] up and down half page with j-k instead of d-u --- lazy-lock.json | 6 +++--- lua/config/keymaps.lua | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 36658c7..52ef14e 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -2,7 +2,7 @@ "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "180e0435707cf1fed09a98a9739e5807d92b69be" }, + "catppuccin": { "branch": "main", "commit": "ce4a8e0d5267e67056f9f4dcf6cb1d0933c8ca00" }, "conform.nvim": { "branch": "master", "commit": "4993e07fac6679d0a5005aa7499e0bad2bd39f19" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, @@ -19,9 +19,9 @@ "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, - "nvim-lspconfig": { "branch": "master", "commit": "30a2b191bccf541ce1797946324c9329e90ec448" }, + "nvim-lspconfig": { "branch": "master", "commit": "f1237a8b3c243608a7116fa1ad216c441d7c2264" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "3bbae7b32e0cc417438e54ec77eb7083e5f38c0f" }, + "nvim-treesitter": { "branch": "main", "commit": "c5871d9d870c866fea9f271f1a3b3f29049a4793" }, "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, diff --git a/lua/config/keymaps.lua b/lua/config/keymaps.lua index dbe5fca..4070c2b 100644 --- a/lua/config/keymaps.lua +++ b/lua/config/keymaps.lua @@ -7,10 +7,10 @@ vim.keymap.set("v", "J", ":m '>+1gv=gv") vim.keymap.set("v", "K", ":m '<-2gv=gv") -- Cursor in middle when jumping -vim.keymap.set("n", "", "zz") -vim.keymap.set("n", "", "zz") +vim.keymap.set("n", "zz") +vim.keymap.set("n", "zz") vim.keymap.set("n", "n", "nzzzv") vim.keymap.set("n", "N", "Nzzzv") --- Prcognition +-- Precognition vim.keymap.set("n", "tp", require("precognition").toggle) From ca393a9d8ea8a826f83052d71229beddf4b4fc23 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sun, 30 Nov 2025 14:50:23 +0000 Subject: [PATCH 16/39] lock update --- lazy-lock.json | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 52ef14e..1d4aaa5 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -6,7 +6,7 @@ "conform.nvim": { "branch": "master", "commit": "4993e07fac6679d0a5005aa7499e0bad2bd39f19" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, - "gitsigns.nvim": { "branch": "main", "commit": "cdafc320f03f2572c40ab93a4eecb733d4016d07" }, + "gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" }, "grug-far.nvim": { "branch": "main", "commit": "b58b2d65863f4ebad88b10a1ddd519e5380466e0" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, @@ -15,14 +15,21 @@ "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, - "mini.pairs": { "branch": "main", "commit": "b316e68f2d242d5bd010deaab645daa27ed86297" }, + "mini.pairs": { "branch": "main", "commit": "472ec50092a3314ec285d2db2baa48602d71fe93" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, +<<<<<<< Updated upstream "nvim-lspconfig": { "branch": "master", "commit": "f1237a8b3c243608a7116fa1ad216c441d7c2264" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, "nvim-treesitter": { "branch": "main", "commit": "c5871d9d870c866fea9f271f1a3b3f29049a4793" }, "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, +======= + "nvim-lspconfig": { "branch": "master", "commit": "07f4e93de92e8d4ea7ab99602e3a8c9ac0fb778a" }, + "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, + "nvim-treesitter": { "branch": "main", "commit": "17885756e63df73ed90db62e4630f744ceda6514" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "63c4dce4a56312ef1bdeafd16bdefa008fcc950a" }, +>>>>>>> Stashed changes "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, From dcba7fede5cf3e78a909d61e52da4cd51296b7ea Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sun, 30 Nov 2025 16:52:26 +0000 Subject: [PATCH 17/39] toggle term session fix --- lua/plugins/toggle-term.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/lua/plugins/toggle-term.lua b/lua/plugins/toggle-term.lua index 7dd3627..2a6975e 100644 --- a/lua/plugins/toggle-term.lua +++ b/lua/plugins/toggle-term.lua @@ -10,6 +10,7 @@ return { open_mapping = [[tt]], direction = "float", float_opts = { border = "rounded" }, + shell = vim.fn.exepath("zsh") .. " -l -i", }, config = function(_, opts) From e9348878ada59348506ebc9a84d30fee7aac720f Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Sun, 30 Nov 2025 16:52:26 +0000 Subject: [PATCH 18/39] toggle term session fix --- lua/config/keymaps.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lua/config/keymaps.lua b/lua/config/keymaps.lua index 4070c2b..a5bf90f 100644 --- a/lua/config/keymaps.lua +++ b/lua/config/keymaps.lua @@ -7,8 +7,8 @@ vim.keymap.set("v", "J", ":m '>+1gv=gv") vim.keymap.set("v", "K", ":m '<-2gv=gv") -- Cursor in middle when jumping -vim.keymap.set("n", "zz") -vim.keymap.set("n", "zz") +vim.keymap.set("n", "", "zz") +vim.keymap.set("n", "", "zz") vim.keymap.set("n", "n", "nzzzv") vim.keymap.set("n", "N", "Nzzzv") From f98fc13247a3758907ae74107b9e7cd7a728b0bd Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Fri, 5 Dec 2025 13:13:42 +0000 Subject: [PATCH 19/39] prettier set up --- lazy-lock.json | 19 ++++++------------- lua/config/lazy.lua | 7 +++++++ lua/config/options.lua | 1 + 3 files changed, 14 insertions(+), 13 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 1d4aaa5..d997617 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -3,7 +3,7 @@ "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, "catppuccin": { "branch": "main", "commit": "ce4a8e0d5267e67056f9f4dcf6cb1d0933c8ca00" }, - "conform.nvim": { "branch": "master", "commit": "4993e07fac6679d0a5005aa7499e0bad2bd39f19" }, + "conform.nvim": { "branch": "master", "commit": "ffe26e8df8115c9665d24231f8a49fadb2d611ce" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, "gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" }, @@ -11,25 +11,18 @@ "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "7d527c76c43f46294de9c19d39c5a86317809b4b" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "0b9bb925c000ae649ff7e7149c8cd00031f4b539" }, "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, "mini.pairs": { "branch": "main", "commit": "472ec50092a3314ec285d2db2baa48602d71fe93" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, -<<<<<<< Updated upstream - "nvim-lspconfig": { "branch": "master", "commit": "f1237a8b3c243608a7116fa1ad216c441d7c2264" }, + "nvim-lint": { "branch": "master", "commit": "5122c0c00a65cf6ce434b16b6a7587b62b6af00d" }, + "nvim-lspconfig": { "branch": "master", "commit": "f7c6e585fd80d5a2c075ab27ac312ac55bcf1550" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "c5871d9d870c866fea9f271f1a3b3f29049a4793" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, -======= - "nvim-lspconfig": { "branch": "master", "commit": "07f4e93de92e8d4ea7ab99602e3a8c9ac0fb778a" }, - "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "17885756e63df73ed90db62e4630f744ceda6514" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "63c4dce4a56312ef1bdeafd16bdefa008fcc950a" }, ->>>>>>> Stashed changes + "nvim-treesitter": { "branch": "main", "commit": "75797cdd8ac125c7ace065b17788b439dcf89a71" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "dfbf9596f8aa8b4bed5301647485594ff7252955" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, diff --git a/lua/config/lazy.lua b/lua/config/lazy.lua index d73bfa1..9bbdf5f 100644 --- a/lua/config/lazy.lua +++ b/lua/config/lazy.lua @@ -18,6 +18,13 @@ require("lazy").setup({ spec = { -- add LazyVim and import its plugins { "LazyVim/LazyVim", import = "lazyvim.plugins" }, + + -- language extras + { import = "lazyvim.plugins.extras.lang.typescript" }, + + -- formatting extras + { import = "lazyvim.plugins.extras.formatting.prettier" }, + -- import/override with your plugins { import = "plugins" }, }, diff --git a/lua/config/options.lua b/lua/config/options.lua index e3c1d7d..de42333 100644 --- a/lua/config/options.lua +++ b/lua/config/options.lua @@ -9,6 +9,7 @@ vim.o.scrolloff = 10 -- Semantic highlighting vim.g.lazyvim_semantic_highlighting = false +vim.g.lazyvim_prettier_needs_config = false -- Kill any orphaned tsserver processes when Neovim exits vim.api.nvim_create_autocmd("ExitPre", { From f1dc92c1e315ab6ece5b5875c7820f65e2a945a2 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Fri, 5 Dec 2025 13:13:42 +0000 Subject: [PATCH 20/39] prettier set up --- lua/plugins/conform.lua | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 lua/plugins/conform.lua diff --git a/lua/plugins/conform.lua b/lua/plugins/conform.lua new file mode 100644 index 0000000..34293f7 --- /dev/null +++ b/lua/plugins/conform.lua @@ -0,0 +1,9 @@ +return { + "stevearc/conform.nvim", + opts = { + formatters_by_ft = { + typescript = { "prettier" }, -- no Prettier for TS + typescriptreact = { "prettier" }, + }, + }, +} From 6fa39301cd725ede8e038e2b8010540ad3789aa8 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 8 Dec 2025 17:05:26 +0000 Subject: [PATCH 21/39] prettier formatting using project .yarn bin file --- lazy-lock.json | 10 +++++----- lua/plugins/conform.lua | 19 ++++++++++++++++++- 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index d997617..d4b8f59 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -2,7 +2,7 @@ "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "ce4a8e0d5267e67056f9f4dcf6cb1d0933c8ca00" }, + "catppuccin": { "branch": "main", "commit": "193e123cdbc4dd3e86db883d55349e9587f0ded6" }, "conform.nvim": { "branch": "master", "commit": "ffe26e8df8115c9665d24231f8a49fadb2d611ce" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, @@ -11,18 +11,18 @@ "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "0b9bb925c000ae649ff7e7149c8cd00031f4b539" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "c55bd8a8fb191e24176c206a7af1dd51ce7276a5" }, "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, "mini.pairs": { "branch": "main", "commit": "472ec50092a3314ec285d2db2baa48602d71fe93" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "5122c0c00a65cf6ce434b16b6a7587b62b6af00d" }, + "nvim-lint": { "branch": "master", "commit": "ebe535956106c60405b02220246e135910f6853d" }, "nvim-lspconfig": { "branch": "master", "commit": "f7c6e585fd80d5a2c075ab27ac312ac55bcf1550" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "75797cdd8ac125c7ace065b17788b439dcf89a71" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "dfbf9596f8aa8b4bed5301647485594ff7252955" }, + "nvim-treesitter": { "branch": "main", "commit": "f47f549f74cea5d5f25a5205c9e127cd882f1d20" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "76deedf0f1cec4496ef8d49b6d1f020f6d0c6ec9" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, diff --git a/lua/plugins/conform.lua b/lua/plugins/conform.lua index 34293f7..a1ba45d 100644 --- a/lua/plugins/conform.lua +++ b/lua/plugins/conform.lua @@ -1,9 +1,26 @@ +local util = require("conform.util") + return { "stevearc/conform.nvim", opts = { + formatters = { + prettier = { + command = util.from_node_modules(".yarn/sdks/prettier/bin/prettier.cjs"), + }, + eslint = { + -- Run project ESLint through Yarn + command = "yarn", + args = { "eslint", "--fix-dry-run", "--stdin", "--stdin-filename", "$FILENAME" }, + stdin = true, + cwd = util.root_file({ "eslint.config.mjs", ".pnp.cjs", "package.json" }), + timeout = 10000, -- 10s; adjust if needed + }, + }, formatters_by_ft = { - typescript = { "prettier" }, -- no Prettier for TS + typescript = { "prettier" }, typescriptreact = { "prettier" }, + javascript = { "prettier" }, + javascriptreact = { "prettier" }, }, }, } From 927dcd611976a5c91e6d2c23a4321a71db8176b8 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Wed, 17 Dec 2025 09:44:40 +0100 Subject: [PATCH 22/39] add copilot chat and completion --- lazy-lock.json | 19 +++++++++++-------- lazyvim.json | 3 ++- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index d4b8f59..f8b581d 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,9 +1,12 @@ { + "CopilotChat.nvim": { "branch": "main", "commit": "df5376c132382dd47e3e552612940cbf25b3580c" }, "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, + "blink-copilot": { "branch": "main", "commit": "7ad8209b2f880a2840c94cdcd80ab4dc511d4f39" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "193e123cdbc4dd3e86db883d55349e9587f0ded6" }, - "conform.nvim": { "branch": "master", "commit": "ffe26e8df8115c9665d24231f8a49fadb2d611ce" }, + "catppuccin": { "branch": "main", "commit": "ce8d176faa4643e026e597ae3c31db59b63cef09" }, + "conform.nvim": { "branch": "master", "commit": "9b8fa5e0b78168f68bee9bf886dc20f287c61e02" }, + "copilot.lua": { "branch": "master", "commit": "508d8b00390ff3046323f61187a57069910c6e17" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, "gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" }, @@ -11,18 +14,18 @@ "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "c55bd8a8fb191e24176c206a7af1dd51ce7276a5" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "3b3571b4dadbcb464804466e9872e7246c316af7" }, "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, - "mini.pairs": { "branch": "main", "commit": "472ec50092a3314ec285d2db2baa48602d71fe93" }, + "mini.pairs": { "branch": "main", "commit": "d5a29b6254dad07757832db505ea5aeab9aad43a" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "ebe535956106c60405b02220246e135910f6853d" }, - "nvim-lspconfig": { "branch": "master", "commit": "f7c6e585fd80d5a2c075ab27ac312ac55bcf1550" }, + "nvim-lint": { "branch": "master", "commit": "c47b71d146a0b638f46672e6704c322369385df6" }, + "nvim-lspconfig": { "branch": "master", "commit": "0d7d33e40f0c27f57cb29654ed78cab17d705e68" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "f47f549f74cea5d5f25a5205c9e127cd882f1d20" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "76deedf0f1cec4496ef8d49b6d1f020f6d0c6ec9" }, + "nvim-treesitter": { "branch": "main", "commit": "d3218d988f72ed34414959c9ccd802d393432d6e" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "0d7c800fadcfe2d33089f5726cb8907fc846eece" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, diff --git a/lazyvim.json b/lazyvim.json index d8bcaf6..262800e 100644 --- a/lazyvim.json +++ b/lazyvim.json @@ -1,6 +1,7 @@ { "extras": [ - + "lazyvim.plugins.extras.ai.copilot", + "lazyvim.plugins.extras.ai.copilot-chat" ], "install_version": 8, "news": { From 74c338653d9af09ecf44949b357b5ae7dfe7841f Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 8 Dec 2025 17:05:26 +0000 Subject: [PATCH 23/39] prettier formatting using project .yarn bin file --- lazy-lock.json | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index f8b581d..d24ad08 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -4,9 +4,9 @@ "blink-copilot": { "branch": "main", "commit": "7ad8209b2f880a2840c94cdcd80ab4dc511d4f39" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "ce8d176faa4643e026e597ae3c31db59b63cef09" }, - "conform.nvim": { "branch": "master", "commit": "9b8fa5e0b78168f68bee9bf886dc20f287c61e02" }, "copilot.lua": { "branch": "master", "commit": "508d8b00390ff3046323f61187a57069910c6e17" }, + "catppuccin": { "branch": "main", "commit": "193e123cdbc4dd3e86db883d55349e9587f0ded6" }, + "conform.nvim": { "branch": "master", "commit": "ffe26e8df8115c9665d24231f8a49fadb2d611ce" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, "gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" }, @@ -21,11 +21,11 @@ "mini.pairs": { "branch": "main", "commit": "d5a29b6254dad07757832db505ea5aeab9aad43a" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "c47b71d146a0b638f46672e6704c322369385df6" }, - "nvim-lspconfig": { "branch": "master", "commit": "0d7d33e40f0c27f57cb29654ed78cab17d705e68" }, + "nvim-lint": { "branch": "master", "commit": "ebe535956106c60405b02220246e135910f6853d" }, + "nvim-lspconfig": { "branch": "master", "commit": "f7c6e585fd80d5a2c075ab27ac312ac55bcf1550" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "d3218d988f72ed34414959c9ccd802d393432d6e" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "0d7c800fadcfe2d33089f5726cb8907fc846eece" }, + "nvim-treesitter": { "branch": "main", "commit": "f47f549f74cea5d5f25a5205c9e127cd882f1d20" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "76deedf0f1cec4496ef8d49b6d1f020f6d0c6ec9" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, From 68f6c8b1ca3634720372f1cadc0f1323d1694c95 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Wed, 17 Dec 2025 09:19:04 +0000 Subject: [PATCH 24/39] copilot configs --- lazy-lock.json | 12 ++++++------ lua/config/options.lua | 3 +++ lua/plugins/copilot.lua | 11 +++++++++++ lua/plugins/precognition.lua | 2 +- lua/plugins/typescript.lua | 3 +++ 5 files changed, 24 insertions(+), 7 deletions(-) create mode 100644 lua/plugins/copilot.lua diff --git a/lazy-lock.json b/lazy-lock.json index d24ad08..f8b581d 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -4,9 +4,9 @@ "blink-copilot": { "branch": "main", "commit": "7ad8209b2f880a2840c94cdcd80ab4dc511d4f39" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, + "catppuccin": { "branch": "main", "commit": "ce8d176faa4643e026e597ae3c31db59b63cef09" }, + "conform.nvim": { "branch": "master", "commit": "9b8fa5e0b78168f68bee9bf886dc20f287c61e02" }, "copilot.lua": { "branch": "master", "commit": "508d8b00390ff3046323f61187a57069910c6e17" }, - "catppuccin": { "branch": "main", "commit": "193e123cdbc4dd3e86db883d55349e9587f0ded6" }, - "conform.nvim": { "branch": "master", "commit": "ffe26e8df8115c9665d24231f8a49fadb2d611ce" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, "gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" }, @@ -21,11 +21,11 @@ "mini.pairs": { "branch": "main", "commit": "d5a29b6254dad07757832db505ea5aeab9aad43a" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "ebe535956106c60405b02220246e135910f6853d" }, - "nvim-lspconfig": { "branch": "master", "commit": "f7c6e585fd80d5a2c075ab27ac312ac55bcf1550" }, + "nvim-lint": { "branch": "master", "commit": "c47b71d146a0b638f46672e6704c322369385df6" }, + "nvim-lspconfig": { "branch": "master", "commit": "0d7d33e40f0c27f57cb29654ed78cab17d705e68" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "f47f549f74cea5d5f25a5205c9e127cd882f1d20" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "76deedf0f1cec4496ef8d49b6d1f020f6d0c6ec9" }, + "nvim-treesitter": { "branch": "main", "commit": "d3218d988f72ed34414959c9ccd802d393432d6e" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "0d7c800fadcfe2d33089f5726cb8907fc846eece" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, diff --git a/lua/config/options.lua b/lua/config/options.lua index de42333..7448d77 100644 --- a/lua/config/options.lua +++ b/lua/config/options.lua @@ -17,3 +17,6 @@ vim.api.nvim_create_autocmd("ExitPre", { vim.fn.system("pkill -f 'tsserver.js'") end, }) + +-- Leave ai completion to copilot +vim.g.ai_cmp = false diff --git a/lua/plugins/copilot.lua b/lua/plugins/copilot.lua new file mode 100644 index 0000000..a80edf2 --- /dev/null +++ b/lua/plugins/copilot.lua @@ -0,0 +1,11 @@ +return { + { + "zbirenbaum/copilot.lua", + opts = { + suggestion = { + enabled = true, + auto_trigger = true, + }, + }, + }, +} diff --git a/lua/plugins/precognition.lua b/lua/plugins/precognition.lua index 035573f..a203abb 100644 --- a/lua/plugins/precognition.lua +++ b/lua/plugins/precognition.lua @@ -5,7 +5,7 @@ return { "tris203/precognition.nvim", event = "VeryLazy", opts = { - startVisible = true, + startVisible = false, showBlankVirtLine = true, highlightColor = { link = "Comment" }, hints = { diff --git a/lua/plugins/typescript.lua b/lua/plugins/typescript.lua index 98bd3c0..d927dbc 100644 --- a/lua/plugins/typescript.lua +++ b/lua/plugins/typescript.lua @@ -7,6 +7,9 @@ return { vtsls = false, tsserver = false, }, + inlay_hints = { + enabled = false, + }, }, }, From c0438a49ab867fbeb3fe0f4bbc6d5d7ad2b70331 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Thu, 18 Dec 2025 08:55:39 +0000 Subject: [PATCH 25/39] change file picker to cwd --- lazy-lock.json | 5 ++--- lua/config/keymaps.lua | 5 +++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index f8b581d..673a615 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,7 +1,6 @@ { "CopilotChat.nvim": { "branch": "main", "commit": "df5376c132382dd47e3e552612940cbf25b3580c" }, "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, - "blink-copilot": { "branch": "main", "commit": "7ad8209b2f880a2840c94cdcd80ab4dc511d4f39" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, "catppuccin": { "branch": "main", "commit": "ce8d176faa4643e026e597ae3c31db59b63cef09" }, @@ -22,9 +21,9 @@ "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "c47b71d146a0b638f46672e6704c322369385df6" }, - "nvim-lspconfig": { "branch": "master", "commit": "0d7d33e40f0c27f57cb29654ed78cab17d705e68" }, + "nvim-lspconfig": { "branch": "master", "commit": "c4f67bf85b01a57e3c130352c0a0e453ab8cd5b9" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "d3218d988f72ed34414959c9ccd802d393432d6e" }, + "nvim-treesitter": { "branch": "main", "commit": "4fc09bee78e91bf4ba471cdab4bf9dfa37fde51c" }, "nvim-treesitter-textobjects": { "branch": "main", "commit": "0d7c800fadcfe2d33089f5726cb8907fc846eece" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, diff --git a/lua/config/keymaps.lua b/lua/config/keymaps.lua index a5bf90f..057cbb3 100644 --- a/lua/config/keymaps.lua +++ b/lua/config/keymaps.lua @@ -14,3 +14,8 @@ vim.keymap.set("n", "N", "Nzzzv") -- Precognition vim.keymap.set("n", "tp", require("precognition").toggle) + +-- set the file picker to always open the cwd instead of root +vim.keymap.set("n", "", function() + require("lazyvim.util").pick("files", { root = false })() +end, { desc = "Find Files (cwd)" }) From af73121656f67c17533406ea7d7b616f1211d953 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Wed, 21 Jan 2026 21:18:44 +0000 Subject: [PATCH 26/39] from atom remote --- lazy-lock.json | 31 ++++++++++++++++--------------- lazyvim.json | 3 ++- 2 files changed, 18 insertions(+), 16 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 673a615..b9317c8 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,31 +1,32 @@ { - "CopilotChat.nvim": { "branch": "main", "commit": "df5376c132382dd47e3e552612940cbf25b3580c" }, + "CopilotChat.nvim": { "branch": "main", "commit": "07dcc188bc488b2dafa9324bd42088640bee3d19" }, "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "ce8d176faa4643e026e597ae3c31db59b63cef09" }, - "conform.nvim": { "branch": "master", "commit": "9b8fa5e0b78168f68bee9bf886dc20f287c61e02" }, - "copilot.lua": { "branch": "master", "commit": "508d8b00390ff3046323f61187a57069910c6e17" }, + "catppuccin": { "branch": "main", "commit": "beaf41a30c26fd7d6c386d383155cbd65dd554cd" }, + "conform.nvim": { "branch": "master", "commit": "c2526f1cde528a66e086ab1668e996d162c75f4f" }, + "copilot.lua": { "branch": "master", "commit": "0ab400d547814b04b39a069208ff7b40ab22dfb5" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, - "gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" }, - "grug-far.nvim": { "branch": "main", "commit": "b58b2d65863f4ebad88b10a1ddd519e5380466e0" }, + "gitsigns.nvim": { "branch": "main", "commit": "42d6aed4e94e0f0bbced16bbdcc42f57673bd75e" }, + "grug-far.nvim": { "branch": "main", "commit": "794f03c97afc7f4b03fb6ec5111be507df1850cf" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "3b3571b4dadbcb464804466e9872e7246c316af7" }, - "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, - "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, - "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "80c0130c5f16b551865a69e832f1feadeedb5fbe" }, + "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, + "mini.ai": { "branch": "main", "commit": "9eae720f2b20f6ad28cbfa0ddc524e10dc2c3201" }, + "mini.icons": { "branch": "main", "commit": "efc85e42262cd0c9e1fdbf806c25cb0be6de115c" }, "mini.pairs": { "branch": "main", "commit": "d5a29b6254dad07757832db505ea5aeab9aad43a" }, + "mini.surround": { "branch": "main", "commit": "f9358544ed06bc10197e698b7fc8dc5963be3f4b" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "c47b71d146a0b638f46672e6704c322369385df6" }, - "nvim-lspconfig": { "branch": "master", "commit": "c4f67bf85b01a57e3c130352c0a0e453ab8cd5b9" }, + "nvim-lint": { "branch": "master", "commit": "ca6ea12daf0a4d92dc24c5c9ae22a1f0418ade37" }, + "nvim-lspconfig": { "branch": "master", "commit": "92ee7d42320edfbb81f3cad851314ab197fa324a" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "4fc09bee78e91bf4ba471cdab4bf9dfa37fde51c" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "0d7c800fadcfe2d33089f5726cb8907fc846eece" }, - "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, + "nvim-treesitter": { "branch": "main", "commit": "ec034813775d7e2974c7551c8c34499a828963f8" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "4d55f63252e04c5212daed958e4e940915ff16ce" }, + "nvim-ts-autotag": { "branch": "main", "commit": "db15f2e0df2f5db916e511e3fffb682ef2f6354f" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, "precognition.nvim": { "branch": "main", "commit": "2aae2687207029b3611a0e19a289f9e1c7efbe16" }, diff --git a/lazyvim.json b/lazyvim.json index 262800e..1ca8e66 100644 --- a/lazyvim.json +++ b/lazyvim.json @@ -1,7 +1,8 @@ { "extras": [ "lazyvim.plugins.extras.ai.copilot", - "lazyvim.plugins.extras.ai.copilot-chat" + "lazyvim.plugins.extras.ai.copilot-chat", + "lazyvim.plugins.extras.coding.mini-surround" ], "install_version": 8, "news": { From 4e699d2ceae868b228294d6df39340aae081cf79 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Fri, 20 Feb 2026 09:48:01 +0000 Subject: [PATCH 27/39] autocommand remove unnused imports --- lazy-lock.json | 34 +++++++++++++++++----------------- lua/config/autocmds.lua | 7 +++++++ lua/plugins/snacks.lua | 20 ++++++++++---------- 3 files changed, 34 insertions(+), 27 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index b9317c8..7d1b13f 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,35 +1,35 @@ { - "CopilotChat.nvim": { "branch": "main", "commit": "07dcc188bc488b2dafa9324bd42088640bee3d19" }, + "CopilotChat.nvim": { "branch": "main", "commit": "743d6005fb412c85309d3f3aa45f18f3a2fb2098" }, "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, - "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, + "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "beaf41a30c26fd7d6c386d383155cbd65dd554cd" }, + "catppuccin": { "branch": "main", "commit": "0a5de4da015a175f416d6ef1eda84661623e0500" }, "conform.nvim": { "branch": "master", "commit": "c2526f1cde528a66e086ab1668e996d162c75f4f" }, - "copilot.lua": { "branch": "master", "commit": "0ab400d547814b04b39a069208ff7b40ab22dfb5" }, + "copilot.lua": { "branch": "master", "commit": "dd3e345d59051464573d821b042f0a0c82410b5d" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, - "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, - "gitsigns.nvim": { "branch": "main", "commit": "42d6aed4e94e0f0bbced16bbdcc42f57673bd75e" }, - "grug-far.nvim": { "branch": "main", "commit": "794f03c97afc7f4b03fb6ec5111be507df1850cf" }, + "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, + "gitsigns.nvim": { "branch": "main", "commit": "9f3c6dd7868bcc116e9c1c1929ce063b978fa519" }, + "grug-far.nvim": { "branch": "main", "commit": "275dbedc96e61a6b8d1dfb28ba51586ddd233dcf" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "80c0130c5f16b551865a69e832f1feadeedb5fbe" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "21c2a84ce368e99b18f52ab348c4c02c32c02fcf" }, "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, "mini.ai": { "branch": "main", "commit": "9eae720f2b20f6ad28cbfa0ddc524e10dc2c3201" }, - "mini.icons": { "branch": "main", "commit": "efc85e42262cd0c9e1fdbf806c25cb0be6de115c" }, - "mini.pairs": { "branch": "main", "commit": "d5a29b6254dad07757832db505ea5aeab9aad43a" }, - "mini.surround": { "branch": "main", "commit": "f9358544ed06bc10197e698b7fc8dc5963be3f4b" }, + "mini.icons": { "branch": "main", "commit": "68c178e0958d95b3977a771f3445429b1bded985" }, + "mini.pairs": { "branch": "main", "commit": "4089aa6ea6423e02e1a8326a7a7a00159f6f5e04" }, + "mini.surround": { "branch": "main", "commit": "d648a5601e1c48f175b07d10eba141da338a0a2a" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "ca6ea12daf0a4d92dc24c5c9ae22a1f0418ade37" }, - "nvim-lspconfig": { "branch": "master", "commit": "92ee7d42320edfbb81f3cad851314ab197fa324a" }, + "nvim-lint": { "branch": "master", "commit": "bcd1a44edbea8cd473af7e7582d3f7ffc60d8e81" }, + "nvim-lspconfig": { "branch": "master", "commit": "44acfe887d4056f704ccc4f17513ed41c9e2b2e6" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "ec034813775d7e2974c7551c8c34499a828963f8" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "4d55f63252e04c5212daed958e4e940915ff16ce" }, - "nvim-ts-autotag": { "branch": "main", "commit": "db15f2e0df2f5db916e511e3fffb682ef2f6354f" }, + "nvim-treesitter": { "branch": "main", "commit": "4d9466677a5ceadef104eaa0fe08d60d91c4e9a7" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "a0e182ae21fda68c59d1f36c9ed45600aef50311" }, + "nvim-ts-autotag": { "branch": "main", "commit": "8e1c0a389f20bf7f5b0dd0e00306c1247bda2595" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, - "precognition.nvim": { "branch": "main", "commit": "2aae2687207029b3611a0e19a289f9e1c7efbe16" }, + "precognition.nvim": { "branch": "main", "commit": "06e4bfa339ddc55a49fd1adcbb403f6e0855c43b" }, "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, "todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" }, "toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" }, diff --git a/lua/config/autocmds.lua b/lua/config/autocmds.lua index 4221e75..f1a5381 100644 --- a/lua/config/autocmds.lua +++ b/lua/config/autocmds.lua @@ -6,3 +6,10 @@ -- -- Or remove existing autocmds by their group name (which is prefixed with `lazyvim_` for the defaults) -- e.g. vim.api.nvim_del_augroup_by_name("lazyvim_wrap_spell") +vim.api.nvim_create_autocmd("BufWritePre", { + pattern = { "*.tsx", "*.ts" }, + callback = function() + local tstools_api = require("typescript-tools.api") + tstools_api.remove_unused_imports(true) -- true = sync + end, +}) diff --git a/lua/plugins/snacks.lua b/lua/plugins/snacks.lua index 3cc8ddb..426f6fa 100644 --- a/lua/plugins/snacks.lua +++ b/lua/plugins/snacks.lua @@ -5,16 +5,16 @@ return { -- Configure snacks.nvim { "folke/snacks.nvim", - keys = { - { - "\\", - function() - Snacks.explorer() - end, - desc = "Toggle Snacks Explorer (Picker)", - }, - { "e", false }, - }, + -- keys = { + -- { + -- "\\", + -- function() + -- Snacks.explorer() + -- end, + -- desc = "Toggle Snacks Explorer (Picker)", + -- }, + -- { "e", false }, + -- }, opts = { scroll = { enabled = false, -- Disable scrolling animations From b16d4246be691d3245f11daccc79ccd40675c94a Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Thu, 26 Feb 2026 18:39:02 +0000 Subject: [PATCH 28/39] claude code config --- .claude/settings.local.json | 7 ++++++ lazy-lock.json | 21 ++++++++-------- lazyvim.json | 1 + lua/plugins/claude-code.lua | 50 +++++++++++++++++++++++++++++++++++++ 4 files changed, 69 insertions(+), 10 deletions(-) create mode 100644 .claude/settings.local.json create mode 100644 lua/plugins/claude-code.lua diff --git a/.claude/settings.local.json b/.claude/settings.local.json new file mode 100644 index 0000000..90dc654 --- /dev/null +++ b/.claude/settings.local.json @@ -0,0 +1,7 @@ +{ + "permissions": { + "allow": [ + "Bash(grep -rn \"nvim_exec_autocmds\\\\|User.*ClaudeCode\\\\|ClaudeCode.*User\" /home/user/.local/share/nvim/lazy/claudecode.nvim/ --include=\"*.lua\" 2>/dev/null | grep -v test | grep -v spec)" + ] + } +} diff --git a/lazy-lock.json b/lazy-lock.json index 7d1b13f..e3ab192 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -4,8 +4,9 @@ "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, "catppuccin": { "branch": "main", "commit": "0a5de4da015a175f416d6ef1eda84661623e0500" }, - "conform.nvim": { "branch": "master", "commit": "c2526f1cde528a66e086ab1668e996d162c75f4f" }, - "copilot.lua": { "branch": "master", "commit": "dd3e345d59051464573d821b042f0a0c82410b5d" }, + "claudecode.nvim": { "branch": "main", "commit": "aa9a5cebebdbfa449c1c5ff229ba5d98e66bafed" }, + "conform.nvim": { "branch": "master", "commit": "e969e302bced7ffb9a0a0323629f31feb0ca35a6" }, + "copilot.lua": { "branch": "master", "commit": "ef4bfc579b404c531c1738bacca82ed61501d877" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, "gitsigns.nvim": { "branch": "main", "commit": "9f3c6dd7868bcc116e9c1c1929ce063b978fa519" }, @@ -13,18 +14,18 @@ "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "21c2a84ce368e99b18f52ab348c4c02c32c02fcf" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "2ab512d3d8e2fd1f679543c13e0dc4606c3d3d2e" }, "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, - "mini.ai": { "branch": "main", "commit": "9eae720f2b20f6ad28cbfa0ddc524e10dc2c3201" }, - "mini.icons": { "branch": "main", "commit": "68c178e0958d95b3977a771f3445429b1bded985" }, - "mini.pairs": { "branch": "main", "commit": "4089aa6ea6423e02e1a8326a7a7a00159f6f5e04" }, - "mini.surround": { "branch": "main", "commit": "d648a5601e1c48f175b07d10eba141da338a0a2a" }, + "mini.ai": { "branch": "main", "commit": "4b0a6207341d895b6cfe9bcb1e4d3e8607bfe4f4" }, + "mini.icons": { "branch": "main", "commit": "5b9076dae1bfbe47ba4a14bc8b967cde0ab5d77e" }, + "mini.pairs": { "branch": "main", "commit": "b7fde3719340946feb75017ef9d75edebdeb0566" }, + "mini.surround": { "branch": "main", "commit": "d205d1741d1fcc1f3117b4e839bf00f74ad72fa2" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "bcd1a44edbea8cd473af7e7582d3f7ffc60d8e81" }, - "nvim-lspconfig": { "branch": "master", "commit": "44acfe887d4056f704ccc4f17513ed41c9e2b2e6" }, + "nvim-lint": { "branch": "master", "commit": "606b823a57b027502a9ae00978ebf4f5d5158098" }, + "nvim-lspconfig": { "branch": "master", "commit": "a40d22e75d951ad2fcf236ceb013d88f81d2cc9a" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "4d9466677a5ceadef104eaa0fe08d60d91c4e9a7" }, + "nvim-treesitter": { "branch": "main", "commit": "957f86ae3f049ab6681ed64c05b05768fcaed0d2" }, "nvim-treesitter-textobjects": { "branch": "main", "commit": "a0e182ae21fda68c59d1f36c9ed45600aef50311" }, "nvim-ts-autotag": { "branch": "main", "commit": "8e1c0a389f20bf7f5b0dd0e00306c1247bda2595" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, diff --git a/lazyvim.json b/lazyvim.json index 1ca8e66..3daaf7b 100644 --- a/lazyvim.json +++ b/lazyvim.json @@ -1,5 +1,6 @@ { "extras": [ + "lazyvim.plugins.extras.ai.claudecode", "lazyvim.plugins.extras.ai.copilot", "lazyvim.plugins.extras.ai.copilot-chat", "lazyvim.plugins.extras.coding.mini-surround" diff --git a/lua/plugins/claude-code.lua b/lua/plugins/claude-code.lua new file mode 100644 index 0000000..1e741a9 --- /dev/null +++ b/lua/plugins/claude-code.lua @@ -0,0 +1,50 @@ +return { + "coder/claudecode.nvim", + lazy = false, + dependencies = { "folke/snacks.nvim" }, + opts = { + log_level = "info", + focus_after_send = true, + terminal = { + git_repo_cwd = true, + snacks_win_opts = { + position = "float", + width = 0.85, + height = 0.85, + border = "rounded", + keys = { + hide = { + "jj", + function(self) + self:hide() + end, + mode = "t", + desc = "Hide Claude", + }, + }, + }, + }, + }, + keys = { + { "j", nil, desc = "Claude Code" }, + -- { "", "ClaudeCode", desc = "Toggle Claude" }, -- not working + { "jj", "ClaudeCode", desc = "Toggle Claude" }, + { "jb", "ClaudeCodeAdd %", desc = "Add current buffer" }, + { "js", "ClaudeCodeSend", mode = "v", desc = "Send selection" }, + + -- I use snacks_picker_list, not supported yet. Claude Code currently only supports these 5. + -- { + -- "js", + -- "ClaudeCodeTreeAdd", + -- desc = "Add file", + -- ft = { "NvimTree", "neo-tree", "oil", "minifiles", "netrw" }, + -- }, + { "jr", "ClaudeCode --resume", desc = "Resume session" }, + { "jc", "ClaudeCode --continue", desc = "Continue session" }, + { "jm", "ClaudeCodeSelectModel", desc = "Select model" }, + + -- Diff actions + { "ja", "ClaudeCodeDiffAccept", desc = "Accept diff" }, + { "jd", "ClaudeCodeDiffDeny", desc = "Deny diff" }, + }, +} From 8f73421b052bb3fe3b08889317d85ab371be88e5 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Thu, 26 Feb 2026 19:40:40 +0100 Subject: [PATCH 29/39] plugins update --- lazyvim.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lazyvim.json b/lazyvim.json index 3daaf7b..0a28d20 100644 --- a/lazyvim.json +++ b/lazyvim.json @@ -3,7 +3,8 @@ "lazyvim.plugins.extras.ai.claudecode", "lazyvim.plugins.extras.ai.copilot", "lazyvim.plugins.extras.ai.copilot-chat", - "lazyvim.plugins.extras.coding.mini-surround" + "lazyvim.plugins.extras.coding.mini-surround", + "lazyvim.plugins.extras.lang.markdown" ], "install_version": 8, "news": { From 09bcf41867d1703cce4f2e105b8b29ec22f595c2 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 2 Mar 2026 10:13:41 +0100 Subject: [PATCH 30/39] acii art update --- lazy-lock.json | 36 +++++++++++++++++++----------------- lua/plugins/snacks.lua | 25 +++++++++++++++++++++---- 2 files changed, 40 insertions(+), 21 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index e3ab192..8d72525 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,36 +1,38 @@ { "CopilotChat.nvim": { "branch": "main", "commit": "743d6005fb412c85309d3f3aa45f18f3a2fb2098" }, "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, - "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" }, + "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "0a5de4da015a175f416d6ef1eda84661623e0500" }, + "catppuccin": { "branch": "main", "commit": "da33755d00e09bff2473978910168ff9ea5dc453" }, "claudecode.nvim": { "branch": "main", "commit": "aa9a5cebebdbfa449c1c5ff229ba5d98e66bafed" }, - "conform.nvim": { "branch": "master", "commit": "e969e302bced7ffb9a0a0323629f31feb0ca35a6" }, + "conform.nvim": { "branch": "master", "commit": "1bf8b5b9caee51507aa51eaed3da5b0f2595c6b9" }, "copilot.lua": { "branch": "master", "commit": "ef4bfc579b404c531c1738bacca82ed61501d877" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, - "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, - "gitsigns.nvim": { "branch": "main", "commit": "9f3c6dd7868bcc116e9c1c1929ce063b978fa519" }, - "grug-far.nvim": { "branch": "main", "commit": "275dbedc96e61a6b8d1dfb28ba51586ddd233dcf" }, + "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, + "gitsigns.nvim": { "branch": "main", "commit": "cdafc320f03f2572c40ab93a4eecb733d4016d07" }, + "grug-far.nvim": { "branch": "main", "commit": "b58b2d65863f4ebad88b10a1ddd519e5380466e0" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, - "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "2ab512d3d8e2fd1f679543c13e0dc4606c3d3d2e" }, - "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, - "mini.ai": { "branch": "main", "commit": "4b0a6207341d895b6cfe9bcb1e4d3e8607bfe4f4" }, - "mini.icons": { "branch": "main", "commit": "5b9076dae1bfbe47ba4a14bc8b967cde0ab5d77e" }, - "mini.pairs": { "branch": "main", "commit": "b7fde3719340946feb75017ef9d75edebdeb0566" }, + "lualine.nvim": { "branch": "master", "commit": "3946f0122255bc377d14a59b27b609fb3ab25768" }, + "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "7d527c76c43f46294de9c19d39c5a86317809b4b" }, + "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, + "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, + "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, + "mini.pairs": { "branch": "main", "commit": "b316e68f2d242d5bd010deaab645daa27ed86297" }, "mini.surround": { "branch": "main", "commit": "d205d1741d1fcc1f3117b4e839bf00f74ad72fa2" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "606b823a57b027502a9ae00978ebf4f5d5158098" }, - "nvim-lspconfig": { "branch": "master", "commit": "a40d22e75d951ad2fcf236ceb013d88f81d2cc9a" }, + "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, + "nvim-lspconfig": { "branch": "master", "commit": "e0fae251f8459940331960106d4bd9457cec23de" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "957f86ae3f049ab6681ed64c05b05768fcaed0d2" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "a0e182ae21fda68c59d1f36c9ed45600aef50311" }, - "nvim-ts-autotag": { "branch": "main", "commit": "8e1c0a389f20bf7f5b0dd0e00306c1247bda2595" }, + "nvim-treesitter": { "branch": "main", "commit": "bb83a676128d95c865e40ba71376d883bdadec14" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, + "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, "precognition.nvim": { "branch": "main", "commit": "06e4bfa339ddc55a49fd1adcbb403f6e0855c43b" }, + "render-markdown.nvim": { "branch": "main", "commit": "1c958131c083c8557ea499fdb08c88b8afb05c4e" }, "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, "todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" }, "toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" }, diff --git a/lua/plugins/snacks.lua b/lua/plugins/snacks.lua index 426f6fa..920451a 100644 --- a/lua/plugins/snacks.lua +++ b/lua/plugins/snacks.lua @@ -16,18 +16,35 @@ return { -- { "e", false }, -- }, opts = { + dashboard = { + preset = { + header = [[ + + + ███████████ █████████ ██████ ██████ █████████ █████ █████ █████████ +░█░░░███░░░████░░░░░███░░██████ ██████ ███░░░░░███░░███ ░░███ ███░░░░░███ +░ ░███ ░░███ ░░░ ░███░█████░███ ░███ ░███ ░███ ░███ ░███ ░░░ + ░███ ░░█████████ ░███░░███ ░███ ░███████████ ░███ ░███ ░░█████████ + ░███ ░░░░░░░░███ ░███ ░░░ ░███ ░███░░░░░███ ░███ ░███ ░░░░░░░░███ + ░███ ███ ░███ ░███ ░███ ░███ ░███ ░███ █░███ █ ███ ░███ + █████ ░░█████████ █████ ██████████ ███████████████████████████░░█████████ + ░░░░░ ░░░░░░░░░ ░░░░░ ░░░░░░░░░░ ░░░░░░░░░░░░░░░░░░░░░░░░░░░ ░░░░░░░░░ + + ]] + } + }, scroll = { enabled = false, -- Disable scrolling animations }, picker = { sources = { explorer = { - hidden = false, -- Show hidden files by default + hidden = false, -- Show hidden files by default layout = { preset = "right" }, -- Position on the right ignored = false, - git_status = true, -- Show git status - diagnostics = true, -- Show diagnostics - follow_file = true, -- Follow current file + git_status = true, -- Show git status + diagnostics = true, -- Show diagnostics + follow_file = true, -- Follow current file win = { list = { keys = { From 4b704219bc85cf76c11252e6b1a9d38b61f6e664 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 2 Mar 2026 11:54:24 +0000 Subject: [PATCH 31/39] claude keys --- lazy-lock.json | 26 +++++++++++++------------- lua/plugins/claude-code.lua | 2 +- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 8d72525..ca2ddf1 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -5,30 +5,30 @@ "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, "catppuccin": { "branch": "main", "commit": "da33755d00e09bff2473978910168ff9ea5dc453" }, "claudecode.nvim": { "branch": "main", "commit": "aa9a5cebebdbfa449c1c5ff229ba5d98e66bafed" }, - "conform.nvim": { "branch": "master", "commit": "1bf8b5b9caee51507aa51eaed3da5b0f2595c6b9" }, + "conform.nvim": { "branch": "master", "commit": "40dcec5555f960b0a04340d76eabdf4efe78599d" }, "copilot.lua": { "branch": "master", "commit": "ef4bfc579b404c531c1738bacca82ed61501d877" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, - "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, - "gitsigns.nvim": { "branch": "main", "commit": "cdafc320f03f2572c40ab93a4eecb733d4016d07" }, - "grug-far.nvim": { "branch": "main", "commit": "b58b2d65863f4ebad88b10a1ddd519e5380466e0" }, + "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, + "gitsigns.nvim": { "branch": "main", "commit": "9f3c6dd7868bcc116e9c1c1929ce063b978fa519" }, + "grug-far.nvim": { "branch": "main", "commit": "9370422e5cdd55321c0b8c4880082c5fd4e52e99" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, - "lualine.nvim": { "branch": "master", "commit": "3946f0122255bc377d14a59b27b609fb3ab25768" }, + "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "7d527c76c43f46294de9c19d39c5a86317809b4b" }, - "mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" }, - "mini.ai": { "branch": "main", "commit": "bfb26d9072670c3aaefab0f53024b2f3729c8083" }, - "mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" }, - "mini.pairs": { "branch": "main", "commit": "b316e68f2d242d5bd010deaab645daa27ed86297" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "a324581a3c83fdacdb9804b79de1cbe00ce18550" }, + "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, + "mini.ai": { "branch": "main", "commit": "4b0a6207341d895b6cfe9bcb1e4d3e8607bfe4f4" }, + "mini.icons": { "branch": "main", "commit": "5b9076dae1bfbe47ba4a14bc8b967cde0ab5d77e" }, + "mini.pairs": { "branch": "main", "commit": "b7fde3719340946feb75017ef9d75edebdeb0566" }, "mini.surround": { "branch": "main", "commit": "d205d1741d1fcc1f3117b4e839bf00f74ad72fa2" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, "nvim-lspconfig": { "branch": "master", "commit": "e0fae251f8459940331960106d4bd9457cec23de" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "bb83a676128d95c865e40ba71376d883bdadec14" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "227165aaeb07b567fb9c066f224816aa8f3ce63f" }, - "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, + "nvim-treesitter": { "branch": "main", "commit": "cb2cb74f3c3cbbcc17e79cada2060165d616d849" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "a0e182ae21fda68c59d1f36c9ed45600aef50311" }, + "nvim-ts-autotag": { "branch": "main", "commit": "8e1c0a389f20bf7f5b0dd0e00306c1247bda2595" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, "precognition.nvim": { "branch": "main", "commit": "06e4bfa339ddc55a49fd1adcbb403f6e0855c43b" }, diff --git a/lua/plugins/claude-code.lua b/lua/plugins/claude-code.lua index 1e741a9..ffc256b 100644 --- a/lua/plugins/claude-code.lua +++ b/lua/plugins/claude-code.lua @@ -30,7 +30,7 @@ return { -- { "", "ClaudeCode", desc = "Toggle Claude" }, -- not working { "jj", "ClaudeCode", desc = "Toggle Claude" }, { "jb", "ClaudeCodeAdd %", desc = "Add current buffer" }, - { "js", "ClaudeCodeSend", mode = "v", desc = "Send selection" }, + { "js", "ClaudeCodeSend", mode = { "n", "v" }, desc = "Send selection / file" }, -- I use snacks_picker_list, not supported yet. Claude Code currently only supports these 5. -- { From a889b9669d96ea5860fd3d8d97f8451abc096a32 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 3 Mar 2026 15:19:40 +0100 Subject: [PATCH 32/39] markdown tasks handling --- lua/config/keymaps.lua | 3 + lua/config/markdown-tasks.lua | 389 ++++++++++++++++++++++++++++++++ lua/plugins/render-markdown.lua | 22 ++ 3 files changed, 414 insertions(+) create mode 100644 lua/config/markdown-tasks.lua create mode 100644 lua/plugins/render-markdown.lua diff --git a/lua/config/keymaps.lua b/lua/config/keymaps.lua index 057cbb3..f92611a 100644 --- a/lua/config/keymaps.lua +++ b/lua/config/keymaps.lua @@ -19,3 +19,6 @@ vim.keymap.set("n", "tp", require("precognition").toggle) vim.keymap.set("n", "", function() require("lazyvim.util").pick("files", { root = false })() end, { desc = "Find Files (cwd)" }) + +-- Markdown task management +require("config.markdown-tasks").setup() diff --git a/lua/config/markdown-tasks.lua b/lua/config/markdown-tasks.lua new file mode 100644 index 0000000..4a964a9 --- /dev/null +++ b/lua/config/markdown-tasks.lua @@ -0,0 +1,389 @@ +-- Markdown task management +-- Keymaps are registered only in markdown buffers via FileType autocmd. +-- +-- File structure expected: +-- # TODO Lists +-- ## General Section ✅2 ❌1 +-- - [ ] undated task +-- ## DD-MM-YYYY ✅0 ❌3 (newest date first) +-- - [ ] task +-- - [x] done task + +local M = {} + +-- ── Core task operations ───────────────────────────────────────────────────── + +local function new_task() + local line = vim.api.nvim_get_current_line() + if line:match("^%s*$") then + vim.api.nvim_set_current_line("- [ ] ") + vim.cmd("startinsert!") + else + vim.cmd("normal! o- [ ] ") + vim.cmd("startinsert!") + end +end + +local function toggle_task() + local line = vim.api.nvim_get_current_line() + if line:find("%[ %]") then + vim.api.nvim_set_current_line((line:gsub("%[ %]", "[x]", 1))) + elseif line:find("%[x%]") then + vim.api.nvim_set_current_line((line:gsub("%[x%]", "[ ]", 1))) + else + return + end + -- stats updated below after toggle + local update = require("config.markdown-tasks")._update_stats + if update then update() end +end + +local function toggle_task_format() + local line = vim.api.nvim_get_current_line() + if line:find("^%s*%- %[.%] ") then + -- "- [ ] text" → "- text" + vim.api.nvim_set_current_line((line:gsub("^(%s*)%- %[.%] ", "%1- ", 1))) + elseif line:find("^%s*%- ") then + -- "- text" → "- [ ] text" + vim.api.nvim_set_current_line((line:gsub("^(%s*)%- ", "%1- [ ] ", 1))) + end +end + +local function jump_next_task() vim.fn.search("- \\[ \\]", "W") end +local function jump_prev_task() vim.fn.search("- \\[ \\]", "bW") end + +local function list_tasks_in_file() + require("snacks").picker.grep({ search = "- \\[ \\]", buffers = true }) +end + +local function search_all_tasks() + require("snacks").picker.grep({ search = "- \\[ \\]" }) +end + +-- ── Section task stats ──────────────────────────────────────────────────────── + +-- Strips the stats suffix from a heading line, returning the bare heading. +local function strip_stats(line) + return (line:gsub("%s+✅%d+ ❌%d+%s*$", "")) +end + +-- Counts [x] and [ ] tasks in a section starting at header_line (1-indexed). +local function count_section_tasks(lines, header_line) + local done, todo = 0, 0 + for i = header_line + 1, #lines do + if lines[i]:match("^## ") then break end + if lines[i]:match("^%s*%- %[x%]") then + done = done + 1 + elseif lines[i]:match("^%s*%- %[ %]") then + todo = todo + 1 + end + end + return done, todo +end + +-- Updates every ## heading with a live task count suffix. +local function update_section_stats() + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + local changed = false + for i, line in ipairs(lines) do + if line:match("^## ") then + local base = strip_stats(line) + local done, todo = count_section_tasks(lines, i) + local new_line = base .. " ✅" .. done .. " ❌" .. todo + if new_line ~= line then + lines[i] = new_line + changed = true + end + end + end + if changed then + local cursor = vim.api.nvim_win_get_cursor(0) + vim.api.nvim_buf_set_lines(0, 0, -1, false, lines) + vim.api.nvim_win_set_cursor(0, cursor) + end +end + +-- Expose so toggle_task can call it without a forward-ref issue. +M._update_stats = update_section_stats + +-- ── Spacing normalizer ─────────────────────────────────────────────────────── + +-- Enforces: one blank line before and after every heading line, no consecutive +-- blank lines, no blank lines between sibling task lines. +local function normalize_spacing() + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + + -- Strip all blank lines first so we can re-insert them deterministically. + local stripped = {} + for _, l in ipairs(lines) do + if not l:match("^%s*$") then table.insert(stripped, l) end + end + + local result = {} + + local function ensure_blank() + if #result > 0 and not result[#result]:match("^%s*$") then + table.insert(result, "") + end + end + + for i, l in ipairs(stripped) do + local is_heading = l:match("^#") + if is_heading and #result > 0 then ensure_blank() end + table.insert(result, l) + if is_heading and i < #stripped then ensure_blank() end + end + + vim.api.nvim_buf_set_lines(0, 0, -1, false, result) + update_section_stats() +end + +-- ── Date helpers ───────────────────────────────────────────────────────────── + +-- Returns date string "DD-MM-YYYY" with an optional day offset. +local function date_string(offset_days) + local t = os.time() + (offset_days or 0) * 86400 + return os.date("%d-%m-%Y", t) +end + +-- Returns 1-indexed line number of the "## DD-MM-YYYY" header, or nil. +local function find_date_section(date_str) + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + for i, line in ipairs(lines) do + if strip_stats(line) == "## " .. date_str then return i end + end +end + +-- Returns the 1-indexed line of the last non-empty content line within a +-- section (from header_line until the next ## header or EOF). +local function section_end(header_line) + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + local last = header_line + for i = header_line + 1, #lines do + if lines[i]:match("^## ") then return i - 1 end + if not lines[i]:match("^%s*$") then last = i end + end + return last +end + +-- Parses a "DD-MM-YYYY" string into a Unix timestamp for comparison. +local function date_to_time(s) + local d, m, y = s:match("(%d+)-(%d+)-(%d+)") + if not d then return 0 end + return os.time({ year = tonumber(y), month = tonumber(m), day = tonumber(d) }) +end + +-- Inserts a new "## date_str" line in descending date order (newest first). +-- Blank lines are left to normalize_spacing. +local function insert_date_section(date_str) + local new_time = date_to_time(date_str) + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + -- Find the first existing date header that is strictly older → insert before it. + for i, line in ipairs(lines) do + local existing = strip_stats(line):match("^## (%d%d%-%d%d%-%d%d%d%d)$") + if existing and date_to_time(existing) < new_time then + vim.api.nvim_buf_set_lines(0, i - 1, i - 1, false, { "## " .. date_str }) + return + end + end + -- All existing dates are newer (or there are none) → append at end. + vim.api.nvim_buf_set_lines(0, #lines, #lines, false, { "## " .. date_str }) +end + +-- ── Insert today's date header ──────────────────────────────────────────────── + +local function insert_date() + local header = "## " .. date_string(0) + local row = vim.api.nvim_win_get_cursor(0)[1] + local line = vim.api.nvim_get_current_line() + if line:match("^%s*$") then + vim.api.nvim_set_current_line(header) + else + vim.api.nvim_buf_set_lines(0, row, row, false, { header }) + vim.api.nvim_win_set_cursor(0, { row + 1, 0 }) + end + normalize_spacing() +end + + +-- ── Move task helpers ───────────────────────────────────────────────────────── + +-- Removes the task at row (1-indexed), then deletes the owning date header if +-- it is now empty. Returns the task text. +local function remove_task(row) + local line = vim.api.nvim_buf_get_lines(0, row - 1, row, false)[1] + + -- Find the ## header that owns this task before deleting it. + local all = vim.api.nvim_buf_get_lines(0, 0, -1, false) + local src_hdr = nil + for i = row, 1, -1 do + if all[i] and all[i]:match("^##") then + src_hdr = i; break + end + end + + vim.api.nvim_buf_set_lines(0, row - 1, row, false, {}) + + -- If the source was a date section that is now empty, remove its header. + if src_hdr then + local updated = vim.api.nvim_buf_get_lines(0, 0, -1, false) + local hdr = updated[src_hdr] + if hdr and strip_stats(hdr):match("^## %d%d%-%d%d%-%d%d%d%d$") then + local empty = true + for i = src_hdr + 1, #updated do + if updated[i]:match("^## ") then break end + if not updated[i]:match("^%s*$") then + empty = false; break + end + end + if empty then + vim.api.nvim_buf_set_lines(0, src_hdr - 1, src_hdr, false, {}) + end + end + end + + return line +end + +-- ── Move task to a date section ─────────────────────────────────────────────── + +local function move_task_to(date_str) + local row = vim.api.nvim_win_get_cursor(0)[1] + local line = vim.api.nvim_get_current_line() + + if not line:match("^%s*%- %[") then + vim.notify("Not on a task line", vim.log.levels.WARN) + return + end + + remove_task(row) + + local target = find_date_section(date_str) + if not target then + insert_date_section(date_str) + target = find_date_section(date_str) + end + + local insert_at = section_end(target) + vim.api.nvim_buf_set_lines(0, insert_at, insert_at, false, { line }) + + normalize_spacing() +end + +local function move_to_general() + local row = vim.api.nvim_win_get_cursor(0)[1] + local line = vim.api.nvim_get_current_line() + + if not line:match("^%s*%- %[") then + vim.notify("Not on a task line", vim.log.levels.WARN) + return + end + + remove_task(row) + + -- The general section is the first ## heading that isn't a date heading. + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + local general = nil + for i, l in ipairs(lines) do + local base = strip_stats(l) + if base:match("^## ") and not base:match("^## %d%d%-%d%d%-%d%d%d%d$") then + general = i; break + end + end + + if not general then + vim.notify("No general section found", vim.log.levels.WARN) + return + end + + local insert_at = section_end(general) + vim.api.nvim_buf_set_lines(0, insert_at, insert_at, false, { line }) + + normalize_spacing() +end + +local function move_to_today() move_task_to(date_string(0)) end +local function move_to_tomorrow() move_task_to(date_string(1)) end +local function move_to_yesterday() move_task_to(date_string(-1)) end + +-- Parses flexible date input into "DD-MM-YYYY". Accepts separators - / or none. +-- If the year is omitted (DDMM or DD-MM or DD/MM), assumes the current year. +local function parse_date_input(input) + if not input or input == "" then return nil end + input = input:match("^%s*(.-)%s*$") -- trim + + local current_year = tonumber(os.date("%Y")) + local d, m, y + + -- With separator: DD-MM-YYYY or DD/MM/YYYY (year optional) + d, m, y = input:match("^(%d%d?)[%-%/](%d%d?)[%-%/](%d%d%d%d)$") + if d then + return string.format("%02d-%02d-%04d", tonumber(d), tonumber(m), tonumber(y)) + end + + d, m = input:match("^(%d%d?)[%-%/](%d%d?)$") + if d then + return string.format("%02d-%02d-%04d", tonumber(d), tonumber(m), current_year) + end + + -- No separator: DDMMYYYY or DDMM + d, m, y = input:match("^(%d%d)(%d%d)(%d%d%d%d)$") + if d then + return string.format("%02d-%02d-%04d", tonumber(d), tonumber(m), tonumber(y)) + end + + d, m = input:match("^(%d%d)(%d%d)$") + if d then + return string.format("%02d-%02d-%04d", tonumber(d), tonumber(m), current_year) + end + + return nil +end + +local function move_to_date() + vim.ui.input({ prompt = "Date (DD-MM-YYYY): " }, function(input) + local parsed = parse_date_input(input) + if parsed then + move_task_to(parsed) + elseif input and input ~= "" then + vim.notify("Unrecognised date: " .. input, vim.log.levels.WARN) + end + end) +end + +-- ── Setup ──────────────────────────────────────────────────────────────────── + +function M.setup() + local group = vim.api.nvim_create_augroup("MarkdownTasks", { clear = true }) + vim.api.nvim_create_autocmd("FileType", { + pattern = "markdown", + group = group, + callback = function(ev) + local buf = ev.buf + local o = function(desc) return { buffer = buf, desc = desc } end + + vim.keymap.set("n", "mn", new_task, o("New task")) + vim.keymap.set("n", "mx", toggle_task, o("Toggle done")) + vim.keymap.set("n", "mf", toggle_task_format, o("Toggle task format")) + vim.keymap.set("n", "mj", jump_next_task, o("Next task")) + vim.keymap.set("n", "mk", jump_prev_task, o("Prev task")) + vim.keymap.set("n", "ml", list_tasks_in_file, o("List tasks (file)")) + vim.keymap.set("n", "ms", search_all_tasks, o("Search all tasks")) + vim.keymap.set("n", "mt", insert_date, o("Insert date header")) + vim.keymap.set("n", "mmg", move_to_general, o("Move → general")) + vim.keymap.set("n", "mmt", move_to_today, o("Move → today")) + vim.keymap.set("n", "mmT", move_to_tomorrow, o("Move → tomorrow")) + vim.keymap.set("n", "mmy", move_to_yesterday, o("Move → yesterday")) + vim.keymap.set("n", "mmd", move_to_date, o("Move → date…")) + + -- Update stats after leaving insert mode (covers new_task completions). + vim.api.nvim_create_autocmd("InsertLeave", { + buffer = buf, + group = group, + callback = update_section_stats, + }) + end, + }) +end + +return M diff --git a/lua/plugins/render-markdown.lua b/lua/plugins/render-markdown.lua new file mode 100644 index 0000000..710d543 --- /dev/null +++ b/lua/plugins/render-markdown.lua @@ -0,0 +1,22 @@ +return { + "MeanderingProgrammer/render-markdown.nvim", + opts = { + heading = { + sign = false, + icons = { "> ", "> " }, + width = { "full", "block" }, + left_pad = 1, + right_pad = 2, + }, + checkbox = { + enabled = true, + unchecked = { icon = "󰄱 ", highlight = "RenderMarkdownUnchecked" }, + checked = { icon = "󰱒 ", highlight = "RenderMarkdownChecked" }, + }, + bullet = { + enabled = true, + icons = { "●", "○", "◆", "◇" }, + }, + anti_conceal = { enabled = false }, + }, +} From 4852afab09c698f1be1bda8b48dab2c44568d075 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 3 Mar 2026 14:21:18 +0000 Subject: [PATCH 33/39] claude window edits --- lazy-lock.json | 6 +++--- lua/plugins/claude-code.lua | 5 +++++ 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index ca2ddf1..c1a6f5f 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,9 +1,9 @@ { "CopilotChat.nvim": { "branch": "main", "commit": "743d6005fb412c85309d3f3aa45f18f3a2fb2098" }, "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, - "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, + "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "da33755d00e09bff2473978910168ff9ea5dc453" }, + "catppuccin": { "branch": "main", "commit": "0a5de4da015a175f416d6ef1eda84661623e0500" }, "claudecode.nvim": { "branch": "main", "commit": "aa9a5cebebdbfa449c1c5ff229ba5d98e66bafed" }, "conform.nvim": { "branch": "master", "commit": "40dcec5555f960b0a04340d76eabdf4efe78599d" }, "copilot.lua": { "branch": "master", "commit": "ef4bfc579b404c531c1738bacca82ed61501d877" }, @@ -23,7 +23,7 @@ "mini.surround": { "branch": "main", "commit": "d205d1741d1fcc1f3117b4e839bf00f74ad72fa2" }, "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-lint": { "branch": "master", "commit": "d1118791070d090777398792a73032a0ca5c79ff" }, + "nvim-lint": { "branch": "master", "commit": "606b823a57b027502a9ae00978ebf4f5d5158098" }, "nvim-lspconfig": { "branch": "master", "commit": "e0fae251f8459940331960106d4bd9457cec23de" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, "nvim-treesitter": { "branch": "main", "commit": "cb2cb74f3c3cbbcc17e79cada2060165d616d849" }, diff --git a/lua/plugins/claude-code.lua b/lua/plugins/claude-code.lua index ffc256b..b18a533 100644 --- a/lua/plugins/claude-code.lua +++ b/lua/plugins/claude-code.lua @@ -7,7 +7,12 @@ return { focus_after_send = true, terminal = { git_repo_cwd = true, + -- split_side = "left", + -- split_width_percentage = 0.25, + -- provider = "toggleterm", -- "snacks" or "toggleterm"... + -- auto_close = true, snacks_win_opts = { + -- Floating window options position = "float", width = 0.85, height = 0.85, From 978fd1ee21ee5fcd9221b7e34fef011205259d9e Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Wed, 4 Mar 2026 09:27:46 +0100 Subject: [PATCH 34/39] markdown and toggle term updates --- lazy-lock.json | 12 +++---- lua/config/markdown-tasks.lua | 62 ++++++++++++++++++++--------------- lua/plugins/toggle-term.lua | 2 +- lua/plugins/which-key.lua | 9 +++++ 4 files changed, 51 insertions(+), 34 deletions(-) create mode 100644 lua/plugins/which-key.lua diff --git a/lazy-lock.json b/lazy-lock.json index c1a6f5f..8359819 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,16 +1,16 @@ { "CopilotChat.nvim": { "branch": "main", "commit": "743d6005fb412c85309d3f3aa45f18f3a2fb2098" }, - "LazyVim": { "branch": "main", "commit": "28db03f958d58dfff3c647ce28fdc1cb88ac158d" }, + "LazyVim": { "branch": "main", "commit": "fca0af57cc3851b14f96a795a9c9bfafc5096dd1" }, "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, "catppuccin": { "branch": "main", "commit": "0a5de4da015a175f416d6ef1eda84661623e0500" }, "claudecode.nvim": { "branch": "main", "commit": "aa9a5cebebdbfa449c1c5ff229ba5d98e66bafed" }, "conform.nvim": { "branch": "master", "commit": "40dcec5555f960b0a04340d76eabdf4efe78599d" }, - "copilot.lua": { "branch": "master", "commit": "ef4bfc579b404c531c1738bacca82ed61501d877" }, + "copilot.lua": { "branch": "master", "commit": "00446a63cba4cc59bb24fc1e210a555a3e4acdfb" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, "gitsigns.nvim": { "branch": "main", "commit": "9f3c6dd7868bcc116e9c1c1929ce063b978fa519" }, - "grug-far.nvim": { "branch": "main", "commit": "9370422e5cdd55321c0b8c4880082c5fd4e52e99" }, + "grug-far.nvim": { "branch": "main", "commit": "ac52ee2d87399dfd7b0d59d5b1d2bbaf2a4028f1" }, "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, @@ -24,7 +24,7 @@ "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, "nvim-lint": { "branch": "master", "commit": "606b823a57b027502a9ae00978ebf4f5d5158098" }, - "nvim-lspconfig": { "branch": "master", "commit": "e0fae251f8459940331960106d4bd9457cec23de" }, + "nvim-lspconfig": { "branch": "master", "commit": "ead0f5f342d8d323441e7d4b88f0fc436a81ad5f" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, "nvim-treesitter": { "branch": "main", "commit": "cb2cb74f3c3cbbcc17e79cada2060165d616d849" }, "nvim-treesitter-textobjects": { "branch": "main", "commit": "a0e182ae21fda68c59d1f36c9ed45600aef50311" }, @@ -32,8 +32,8 @@ "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, "precognition.nvim": { "branch": "main", "commit": "06e4bfa339ddc55a49fd1adcbb403f6e0855c43b" }, - "render-markdown.nvim": { "branch": "main", "commit": "1c958131c083c8557ea499fdb08c88b8afb05c4e" }, - "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, + "render-markdown.nvim": { "branch": "main", "commit": "1641b434bda26e0f4e3610985b3357fc213cf834" }, + "snacks.nvim": { "branch": "main", "commit": "9912042fc8bca2209105526ac7534e9a0c2071b2" }, "todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" }, "toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" }, "tokyonight.nvim": { "branch": "main", "commit": "5da1b76e64daf4c5d410f06bcb6b9cb640da7dfd" }, diff --git a/lua/config/markdown-tasks.lua b/lua/config/markdown-tasks.lua index 4a964a9..fd3ed8c 100644 --- a/lua/config/markdown-tasks.lua +++ b/lua/config/markdown-tasks.lua @@ -64,7 +64,7 @@ end -- Strips the stats suffix from a heading line, returning the bare heading. local function strip_stats(line) - return (line:gsub("%s+✅%d+ ❌%d+%s*$", "")) + return (line:gsub("%s+✅%d+/%d+%s*$", "")) end -- Counts [x] and [ ] tasks in a section starting at header_line (1-indexed). @@ -89,7 +89,7 @@ local function update_section_stats() if line:match("^## ") then local base = strip_stats(line) local done, todo = count_section_tasks(lines, i) - local new_line = base .. " ✅" .. done .. " ❌" .. todo + local new_line = base .. " ✅" .. done .. "/" .. todo if new_line ~= line then lines[i] = new_line changed = true @@ -355,35 +355,43 @@ end function M.setup() local group = vim.api.nvim_create_augroup("MarkdownTasks", { clear = true }) + + local function setup_buf(buf) + local o = function(desc) return { buffer = buf, desc = desc } end + vim.keymap.set("n", "mn", new_task, o("New task")) + vim.keymap.set("n", "mx", toggle_task, o("Toggle done")) + vim.keymap.set("n", "mf", toggle_task_format, o("Toggle task format")) + vim.keymap.set("n", "mj", jump_next_task, o("Next task")) + vim.keymap.set("n", "mk", jump_prev_task, o("Prev task")) + vim.keymap.set("n", "ml", list_tasks_in_file, o("List tasks (file)")) + vim.keymap.set("n", "ms", search_all_tasks, o("Search all tasks")) + vim.keymap.set("n", "mt", insert_date, o("Insert date header")) + vim.keymap.set("n", "mmg", move_to_general, o("Move → general")) + vim.keymap.set("n", "mmt", move_to_today, o("Move → today")) + vim.keymap.set("n", "mmT", move_to_tomorrow, o("Move → tomorrow")) + vim.keymap.set("n", "mmy", move_to_yesterday, o("Move → yesterday")) + vim.keymap.set("n", "mmd", move_to_date, o("Move → date…")) + -- Update stats after leaving insert mode (covers new_task completions). + vim.api.nvim_create_autocmd("InsertLeave", { + buffer = buf, + group = group, + callback = update_section_stats, + }) + end + vim.api.nvim_create_autocmd("FileType", { pattern = "markdown", group = group, - callback = function(ev) - local buf = ev.buf - local o = function(desc) return { buffer = buf, desc = desc } end - - vim.keymap.set("n", "mn", new_task, o("New task")) - vim.keymap.set("n", "mx", toggle_task, o("Toggle done")) - vim.keymap.set("n", "mf", toggle_task_format, o("Toggle task format")) - vim.keymap.set("n", "mj", jump_next_task, o("Next task")) - vim.keymap.set("n", "mk", jump_prev_task, o("Prev task")) - vim.keymap.set("n", "ml", list_tasks_in_file, o("List tasks (file)")) - vim.keymap.set("n", "ms", search_all_tasks, o("Search all tasks")) - vim.keymap.set("n", "mt", insert_date, o("Insert date header")) - vim.keymap.set("n", "mmg", move_to_general, o("Move → general")) - vim.keymap.set("n", "mmt", move_to_today, o("Move → today")) - vim.keymap.set("n", "mmT", move_to_tomorrow, o("Move → tomorrow")) - vim.keymap.set("n", "mmy", move_to_yesterday, o("Move → yesterday")) - vim.keymap.set("n", "mmd", move_to_date, o("Move → date…")) - - -- Update stats after leaving insert mode (covers new_task completions). - vim.api.nvim_create_autocmd("InsertLeave", { - buffer = buf, - group = group, - callback = update_section_stats, - }) - end, + callback = function(ev) setup_buf(ev.buf) end, }) + + -- VeryLazy fires after the initial buffer's FileType event, so apply + -- keymaps to any markdown buffers that are already open. + for _, buf in ipairs(vim.api.nvim_list_bufs()) do + if vim.api.nvim_buf_is_loaded(buf) and vim.bo[buf].filetype == "markdown" then + setup_buf(buf) + end + end end return M diff --git a/lua/plugins/toggle-term.lua b/lua/plugins/toggle-term.lua index 2a6975e..3e3e6dd 100644 --- a/lua/plugins/toggle-term.lua +++ b/lua/plugins/toggle-term.lua @@ -10,7 +10,7 @@ return { open_mapping = [[tt]], direction = "float", float_opts = { border = "rounded" }, - shell = vim.fn.exepath("zsh") .. " -l -i", + shell = vim.o.shell .. " -l -i", }, config = function(_, opts) diff --git a/lua/plugins/which-key.lua b/lua/plugins/which-key.lua new file mode 100644 index 0000000..723c86a --- /dev/null +++ b/lua/plugins/which-key.lua @@ -0,0 +1,9 @@ +return { + "folke/which-key.nvim", + opts = { + spec = { + { "m", group = "markdown" }, + { "mm", group = "move task" }, + }, + }, +} From 162c6cecedf407acbff4f29f2c43d09d79df2ff8 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Thu, 5 Mar 2026 23:56:42 +0100 Subject: [PATCH 35/39] mardown tasks --- .claude/settings.local.json | 4 +- lazy-lock.json | 3 +- lua/config/markdown-tasks.lua | 118 +++++++++++++++++++++++++++++----- 3 files changed, 107 insertions(+), 18 deletions(-) diff --git a/.claude/settings.local.json b/.claude/settings.local.json index 90dc654..38594f8 100644 --- a/.claude/settings.local.json +++ b/.claude/settings.local.json @@ -1,7 +1,9 @@ { "permissions": { "allow": [ - "Bash(grep -rn \"nvim_exec_autocmds\\\\|User.*ClaudeCode\\\\|ClaudeCode.*User\" /home/user/.local/share/nvim/lazy/claudecode.nvim/ --include=\"*.lua\" 2>/dev/null | grep -v test | grep -v spec)" + "Bash(grep -rn \"nvim_exec_autocmds\\\\|User.*ClaudeCode\\\\|ClaudeCode.*User\" /home/user/.local/share/nvim/lazy/claudecode.nvim/ --include=\"*.lua\" 2>/dev/null | grep -v test | grep -v spec)", + "Bash(grep:*)", + "Bash(python3:*)" ] } } diff --git a/lazy-lock.json b/lazy-lock.json index 8359819..8c7f3c7 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,10 +1,10 @@ { "CopilotChat.nvim": { "branch": "main", "commit": "743d6005fb412c85309d3f3aa45f18f3a2fb2098" }, "LazyVim": { "branch": "main", "commit": "fca0af57cc3851b14f96a795a9c9bfafc5096dd1" }, + "blink-copilot": { "branch": "main", "commit": "7ad8209b2f880a2840c94cdcd80ab4dc511d4f39" }, "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, "catppuccin": { "branch": "main", "commit": "0a5de4da015a175f416d6ef1eda84661623e0500" }, - "claudecode.nvim": { "branch": "main", "commit": "aa9a5cebebdbfa449c1c5ff229ba5d98e66bafed" }, "conform.nvim": { "branch": "master", "commit": "40dcec5555f960b0a04340d76eabdf4efe78599d" }, "copilot.lua": { "branch": "master", "commit": "00446a63cba4cc59bb24fc1e210a555a3e4acdfb" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, @@ -14,7 +14,6 @@ "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "a324581a3c83fdacdb9804b79de1cbe00ce18550" }, "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, "mini.ai": { "branch": "main", "commit": "4b0a6207341d895b6cfe9bcb1e4d3e8607bfe4f4" }, diff --git a/lua/config/markdown-tasks.lua b/lua/config/markdown-tasks.lua index fd3ed8c..609fc22 100644 --- a/lua/config/markdown-tasks.lua +++ b/lua/config/markdown-tasks.lua @@ -25,15 +25,74 @@ local function new_task() end local function toggle_task() - local line = vim.api.nvim_get_current_line() + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + local row = vim.api.nvim_win_get_cursor(0)[1] + local line = lines[row] + if not line:find("%[[ x]%]") then return end + + -- Toggle current line + local new_state if line:find("%[ %]") then - vim.api.nvim_set_current_line((line:gsub("%[ %]", "[x]", 1))) - elseif line:find("%[x%]") then - vim.api.nvim_set_current_line((line:gsub("%[x%]", "[ ]", 1))) + lines[row] = line:gsub("%[ %]", "[x]", 1) + new_state = "[x]" else - return + lines[row] = line:gsub("%[x%]", "[ ]", 1) + new_state = "[ ]" end - -- stats updated below after toggle + + local cur_indent = #(line:match("^(%s*)") or "") + + -- Cascade down: set all deeper-indented children to same state + for i = row + 1, #lines do + local l = lines[i] + if not l:match("^%s*%-") then break end + local indent = #(l:match("^(%s*)") or "") + if indent <= cur_indent then break end + if new_state == "[x]" then + lines[i] = l:gsub("%[ %]", "[x]", 1) + else + lines[i] = l:gsub("%[x%]", "[ ]", 1) + end + end + + -- Cascade up: find parent (less indent, is a task) + local parent_row + for i = row - 1, 1, -1 do + local l = lines[i] + if not l:match("^%s*%-") then break end + local indent = #(l:match("^(%s*)") or "") + if indent < cur_indent and l:find("%[[ x]%]") then + parent_row = i + break + end + end + + if parent_row then + if new_state == "[ ]" and lines[parent_row]:find("%[x%]") then + -- Unchecking child: uncheck parent + lines[parent_row] = lines[parent_row]:gsub("%[x%]", "[ ]", 1) + elseif new_state == "[x]" then + -- Checking child: check parent if all siblings are now done + local parent_indent = #(lines[parent_row]:match("^(%s*)") or "") + local all_done = true + for i = parent_row + 1, #lines do + local l = lines[i] + if not l:match("^%s*%-") then break end + local indent = #(l:match("^(%s*)") or "") + if indent <= parent_indent then break end + if indent == cur_indent and l:find("%[ %]") then + all_done = false + break + end + end + if all_done then + lines[parent_row] = lines[parent_row]:gsub("%[ %]", "[x]", 1) + end + end + end + + vim.api.nvim_buf_set_lines(0, 0, -1, false, lines) + vim.api.nvim_win_set_cursor(0, { row, vim.api.nvim_win_get_cursor(0)[2] }) local update = require("config.markdown-tasks")._update_stats if update then update() end end @@ -62,9 +121,22 @@ end -- ── Section task stats ──────────────────────────────────────────────────────── +-- Parses a "DD-MM-YYYY" string into a Unix timestamp for comparison. +local function date_to_time(s) + local d, m, y = s:match("(%d+)-(%d+)-(%d+)") + if not d then return 0 end + return os.time({ year = tonumber(y), month = tonumber(m), day = tonumber(d) }) +end + -- Strips the stats suffix from a heading line, returning the bare heading. local function strip_stats(line) - return (line:gsub("%s+✅%d+/%d+%s*$", "")) + return (line + :gsub("%s+✅ ?%d+/%d+ ?✅%s*$", "") + :gsub("%s+❌ ?%d+/%d+ ?❌%s*$", "") + :gsub("%s+📜 ?%d+/%d+ ?📜%s*$", "") + :gsub("%s+⏳ ?%d+/%d+ ?⏳%s*$", "") + :gsub("%s+📅 ?%d+/%d+ ?📅%s*$", "") + :gsub("%s+🚨 ?%d+/%d+ ?🚨%s*$", "")) end -- Counts [x] and [ ] tasks in a section starting at header_line (1-indexed). @@ -81,6 +153,19 @@ local function count_section_tasks(lines, header_line) return done, todo end +local function classify_section(base) + local date_str = base:match("^## (%d%d%-%d%d%-%d%d%d%d)$") + if not date_str then return "general" end + local section_time = date_to_time(date_str) + local today_start = date_to_time(os.date("%d-%m-%Y")) + if section_time == today_start then return "today" end + return section_time > today_start and "future" or "past" +end + +local section_icons = { + general = "📜", today = "⏳", future = "📅", past = "❌", +} + -- Updates every ## heading with a live task count suffix. local function update_section_stats() local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) @@ -89,7 +174,17 @@ local function update_section_stats() if line:match("^## ") then local base = strip_stats(line) local done, todo = count_section_tasks(lines, i) - local new_line = base .. " ✅" .. done .. "/" .. todo + local total = done + todo + local kind = classify_section(base) + local icon + if total > 0 and done == total then + icon = "✅" + elseif kind == "today" and done == 0 and total >= 2 then + icon = "🚨" + else + icon = section_icons[kind] + end + local new_line = base .. " " .. icon .. " " .. done .. "/" .. total .. " " .. icon if new_line ~= line then lines[i] = new_line changed = true @@ -166,13 +261,6 @@ local function section_end(header_line) return last end --- Parses a "DD-MM-YYYY" string into a Unix timestamp for comparison. -local function date_to_time(s) - local d, m, y = s:match("(%d+)-(%d+)-(%d+)") - if not d then return 0 end - return os.time({ year = tonumber(y), month = tonumber(m), day = tonumber(d) }) -end - -- Inserts a new "## date_str" line in descending date order (newest first). -- Blank lines are left to normalize_spacing. local function insert_date_section(date_str) From b18eedb7ca17427d753ab45260943d30001ba912 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Thu, 5 Mar 2026 23:58:46 +0100 Subject: [PATCH 36/39] toggle term shell --- lua/plugins/toggle-term.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/plugins/toggle-term.lua b/lua/plugins/toggle-term.lua index 3e3e6dd..64cdc91 100644 --- a/lua/plugins/toggle-term.lua +++ b/lua/plugins/toggle-term.lua @@ -10,7 +10,7 @@ return { open_mapping = [[tt]], direction = "float", float_opts = { border = "rounded" }, - shell = vim.o.shell .. " -l -i", + shell = vim.fn.exepath('zsh') .. " -l -i", }, config = function(_, opts) From 7b04948d5e696360724568434ab2d2a563d761ee Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 10 Mar 2026 16:27:51 +0000 Subject: [PATCH 37/39] ascii art update --- lazy-lock.json | 11 ++++++----- lua/plugins/snacks.lua | 28 +++++++++++++--------------- lua/plugins/toggle-term.lua | 2 +- 3 files changed, 20 insertions(+), 21 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 8c7f3c7..3d07c36 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -1,11 +1,12 @@ { - "CopilotChat.nvim": { "branch": "main", "commit": "743d6005fb412c85309d3f3aa45f18f3a2fb2098" }, + "CopilotChat.nvim": { "branch": "main", "commit": "ecea24a9a067c6f176b8e13eb11251c739caf055" }, "LazyVim": { "branch": "main", "commit": "fca0af57cc3851b14f96a795a9c9bfafc5096dd1" }, "blink-copilot": { "branch": "main", "commit": "7ad8209b2f880a2840c94cdcd80ab4dc511d4f39" }, "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" }, "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "catppuccin": { "branch": "main", "commit": "0a5de4da015a175f416d6ef1eda84661623e0500" }, - "conform.nvim": { "branch": "master", "commit": "40dcec5555f960b0a04340d76eabdf4efe78599d" }, + "catppuccin": { "branch": "main", "commit": "12c004cde3f36cb1d57242f1e6aac46b09a0e5b4" }, + "claudecode.nvim": { "branch": "main", "commit": "aa9a5cebebdbfa449c1c5ff229ba5d98e66bafed" }, + "conform.nvim": { "branch": "master", "commit": "086a40dc7ed8242c03be9f47fbcee68699cc2395" }, "copilot.lua": { "branch": "master", "commit": "00446a63cba4cc59bb24fc1e210a555a3e4acdfb" }, "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" }, "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, @@ -25,8 +26,8 @@ "nvim-lint": { "branch": "master", "commit": "606b823a57b027502a9ae00978ebf4f5d5158098" }, "nvim-lspconfig": { "branch": "master", "commit": "ead0f5f342d8d323441e7d4b88f0fc436a81ad5f" }, "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" }, - "nvim-treesitter": { "branch": "main", "commit": "cb2cb74f3c3cbbcc17e79cada2060165d616d849" }, - "nvim-treesitter-textobjects": { "branch": "main", "commit": "a0e182ae21fda68c59d1f36c9ed45600aef50311" }, + "nvim-treesitter": { "branch": "main", "commit": "5cb05e1b0fa3c469958a2b26f36b3fe930af221c" }, + "nvim-treesitter-textobjects": { "branch": "main", "commit": "4e91b5d0394329a229725b021a8ea217099826ef" }, "nvim-ts-autotag": { "branch": "main", "commit": "8e1c0a389f20bf7f5b0dd0e00306c1247bda2595" }, "persistence.nvim": { "branch": "main", "commit": "b20b2a7887bd39c1a356980b45e03250f3dce49c" }, "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, diff --git a/lua/plugins/snacks.lua b/lua/plugins/snacks.lua index 920451a..499cfaf 100644 --- a/lua/plugins/snacks.lua +++ b/lua/plugins/snacks.lua @@ -19,19 +19,17 @@ return { dashboard = { preset = { header = [[ + +████████╗███████╗███╗ ███╗ █████╗ ██╗ ██╗ ███████╗ +╚══██╔══╝██╔════╝████╗ ████║██╔══██╗██║ ██║ ██╔════╝ + ██║ ███████╗██╔████╔██║███████║██║ ██║ ███████╗ + ██║ ╚════██║██║╚██╔╝██║██╔══██║██║ ██║ ╚════██║ + ██║ ███████║██║ ╚═╝ ██║██║ ██║███████╗███████╗███████║ + ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚══════╝╚══════╝╚══════╝ - ███████████ █████████ ██████ ██████ █████████ █████ █████ █████████ -░█░░░███░░░████░░░░░███░░██████ ██████ ███░░░░░███░░███ ░░███ ███░░░░░███ -░ ░███ ░░███ ░░░ ░███░█████░███ ░███ ░███ ░███ ░███ ░███ ░░░ - ░███ ░░█████████ ░███░░███ ░███ ░███████████ ░███ ░███ ░░█████████ - ░███ ░░░░░░░░███ ░███ ░░░ ░███ ░███░░░░░███ ░███ ░███ ░░░░░░░░███ - ░███ ███ ░███ ░███ ░███ ░███ ░███ ░███ █░███ █ ███ ░███ - █████ ░░█████████ █████ ██████████ ███████████████████████████░░█████████ - ░░░░░ ░░░░░░░░░ ░░░░░ ░░░░░░░░░░ ░░░░░░░░░░░░░░░░░░░░░░░░░░░ ░░░░░░░░░ - - ]] - } + ]], + }, }, scroll = { enabled = false, -- Disable scrolling animations @@ -39,12 +37,12 @@ return { picker = { sources = { explorer = { - hidden = false, -- Show hidden files by default + hidden = false, -- Show hidden files by default layout = { preset = "right" }, -- Position on the right ignored = false, - git_status = true, -- Show git status - diagnostics = true, -- Show diagnostics - follow_file = true, -- Follow current file + git_status = true, -- Show git status + diagnostics = true, -- Show diagnostics + follow_file = true, -- Follow current file win = { list = { keys = { diff --git a/lua/plugins/toggle-term.lua b/lua/plugins/toggle-term.lua index 64cdc91..2a6975e 100644 --- a/lua/plugins/toggle-term.lua +++ b/lua/plugins/toggle-term.lua @@ -10,7 +10,7 @@ return { open_mapping = [[tt]], direction = "float", float_opts = { border = "rounded" }, - shell = vim.fn.exepath('zsh') .. " -l -i", + shell = vim.fn.exepath("zsh") .. " -l -i", }, config = function(_, opts) From 14ee499552c0254d48400116ea40401bf6fc0ee6 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Tue, 10 Mar 2026 17:43:02 +0100 Subject: [PATCH 38/39] toggle term shell to handle both zsh and bash --- lua/plugins/toggle-term.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/plugins/toggle-term.lua b/lua/plugins/toggle-term.lua index 2a6975e..bf0625d 100644 --- a/lua/plugins/toggle-term.lua +++ b/lua/plugins/toggle-term.lua @@ -10,7 +10,7 @@ return { open_mapping = [[tt]], direction = "float", float_opts = { border = "rounded" }, - shell = vim.fn.exepath("zsh") .. " -l -i", + shell = (os.getenv("SHELL") or vim.fn.exepath("zsh") or vim.fn.exepath("bash")) .. " -l -i", }, config = function(_, opts) From 3096d43490df70d127ab00853eb02e4a469069b1 Mon Sep 17 00:00:00 2001 From: Thomas Smallwood Date: Mon, 16 Mar 2026 09:40:49 +0100 Subject: [PATCH 39/39] markdown comment description --- lua/config/markdown-tasks.lua | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/lua/config/markdown-tasks.lua b/lua/config/markdown-tasks.lua index 609fc22..02a0133 100644 --- a/lua/config/markdown-tasks.lua +++ b/lua/config/markdown-tasks.lua @@ -3,11 +3,26 @@ -- -- File structure expected: -- # TODO Lists --- ## General Section ✅2 ❌1 +-- ## General Section 📜 1/2 📜 -- - [ ] undated task --- ## DD-MM-YYYY ✅0 ❌3 (newest date first) --- - [ ] task -- - [x] done task +-- ## DD-MM-YYYY ⏳ 0/2 ⏳ (date sections sorted newest first) +-- - [ ] task +-- - [ ] another task +-- +-- Section stat icons (auto-updated on toggle and InsertLeave): +-- ✅ all tasks done (any section) +-- 🚨 today, 0 done, ≥2 total +-- ⏳ today (default) +-- 📅 future date +-- ❌ past date +-- 📜 general (non-date heading) +-- +-- Features: +-- Toggle cascades to children; unchecking a child unchecks parent, +-- checking last sibling checks parent. Spacing is auto-normalized +-- (blank lines around headings, none between sibling tasks). +-- Tasks can be moved between date sections and a general section. local M = {}