From b4e53d160ac67ed61e656139812ad21453fe9919 Mon Sep 17 00:00:00 2001 From: Prad Nukala Date: Tue, 13 Oct 2026 09:07:58 -0400 Subject: [PATCH] feat(plugins): add codediff, tv, vellum plugins and drop overseer support --- lua/plugins/astrocore.lua | 4 ---- lua/plugins/codediff.lua | 13 +++++++++++ lua/plugins/overseer.lua | 23 -------------------- lua/plugins/pane-nav.lua | 2 ++ lua/plugins/tv.lua | 45 +++++++++++++++++++++++++++++++++++++++ lua/plugins/vellum.lua | 19 +++++++++++++++++ 6 files changed, 79 insertions(+), 27 deletions(-) create mode 100644 lua/plugins/codediff.lua delete mode 100644 lua/plugins/overseer.lua create mode 100644 lua/plugins/tv.lua create mode 100644 lua/plugins/vellum.lua diff --git a/lua/plugins/astrocore.lua b/lua/plugins/astrocore.lua index d1fdc4b..54ef8ac 100644 --- a/lua/plugins/astrocore.lua +++ b/lua/plugins/astrocore.lua @@ -375,10 +375,6 @@ return { function() require("config.templates").pick() end, desc = "Find templates", }, - -- NOTE: and are likewise the same key, so Enter in normal - -- mode runs overseer. Buffers with their own (quickfix, help, - -- neo-tree, overseer's task list) keep theirs via buffer-local maps. - [""] = { "OverseerRun", desc = "Run overseer task" }, ["w"] = { function() require("fff").live_grep() end, desc = "Live grep", diff --git a/lua/plugins/codediff.lua b/lua/plugins/codediff.lua new file mode 100644 index 0000000..52b1ea4 --- /dev/null +++ b/lua/plugins/codediff.lua @@ -0,0 +1,13 @@ +--- codediff.nvim: VSCode-style diff review workspace (explorer + side-by-side) +--- `:CodeDiff` reviews the working tree; `q` closes the review tab. +--- @module plugins.codediff + +---@type LazySpec +return { + "esmuellert/codediff.nvim", + cmd = "CodeDiff", + keys = { + { "", "CodeDiff", desc = "Review changes (CodeDiff)" }, + }, + opts = {}, +} diff --git a/lua/plugins/overseer.lua b/lua/plugins/overseer.lua deleted file mode 100644 index 377fd55..0000000 --- a/lua/plugins/overseer.lua +++ /dev/null @@ -1,23 +0,0 @@ ---- overseer.nvim: task output in a Snacks bottom window ---- ---- The astrocommunity pack (community.lua) owns the plugin spec and the ---- M* maps; this layers the `snacks_output` component ---- (lua/overseer/component/snacks_output.lua) onto the default component ---- set so every task shows its terminal buffer in a 24-row window docked at ---- the bottom. / Enter runs a task, see plugins/astrocore.lua. ---- @module plugins.overseer - -return { - "stevearc/overseer.nvim", - ---@type overseer.SetupOpts - opts = { - component_aliases = { - default = { - "on_exit_set_status", - "on_complete_notify", - { "on_complete_dispose", require_view = { "SUCCESS", "FAILURE" } }, - { "snacks_output", height = 24 }, - }, - }, - }, -} diff --git a/lua/plugins/pane-nav.lua b/lua/plugins/pane-nav.lua index edd79db..83f6aee 100644 --- a/lua/plugins/pane-nav.lua +++ b/lua/plugins/pane-nav.lua @@ -20,9 +20,11 @@ return { "AstroNvim/astrocore", opts = function(_, opts) local maps = opts.mappings + maps.x = maps.x or {} for key, dir in pairs(moves) do local desc = ("Move %s a split (%s aware)"):format(dir, nav.env()) maps.n[key] = { function() nav.navigate(dir) end, desc = desc } + maps.x[key] = maps.n[key] maps.t[key] = { nav.terminal(dir), desc = desc } end end, diff --git a/lua/plugins/tv.lua b/lua/plugins/tv.lua new file mode 100644 index 0000000..8fb7c37 --- /dev/null +++ b/lua/plugins/tv.lua @@ -0,0 +1,45 @@ +--- tv.nvim: television channels in a floating terminal +--- picks from the file/editor cable channels in the dotfiles +--- (~/.config/television/cable) only. Their cable `enter` actions would spawn +--- an editor inside the float, so each gets Neovim-side handlers: tv.nvim +--- passes handler keys as `--expect`, which wins over cable keybindings. +--- `:Tv ` still reaches any channel. +--- @module plugins.tv + +local OPEN = { "files", "git-files", "recent-files", "dotfiles", "git-diff" } +local GREP = { "text", "todo-comments" } + +---@type LazySpec +return { + "alexpasmantier/tv.nvim", + cmd = "Tv", + keys = { + { + "", + function() + vim.ui.select(vim.list_extend(vim.list_extend({}, OPEN), GREP), { prompt = "Television" }, function(choice) + if choice then require("tv").tv_channel(choice) end + end) + end, + desc = "Television file channels", + }, + }, + config = function() + local h = require("tv").handlers + local channels = {} + -- no /: tv uses them for cycle_sources / the action picker + for _, name in ipairs(OPEN) do + channels[name] = { + handlers = { [""] = h.open_as_files, [""] = h.send_to_quickfix, [""] = h.open_in_vsplit }, + } + end + for _, name in ipairs(GREP) do + channels[name] = { handlers = { [""] = h.open_at_line, [""] = h.send_to_quickfix } } + end + + require("tv").setup { + global_keybindings = { channels = false }, -- lives in `keys` above + channels = channels, + } + end, +} diff --git a/lua/plugins/vellum.lua b/lua/plugins/vellum.lua new file mode 100644 index 0000000..e9fb2a2 --- /dev/null +++ b/lua/plugins/vellum.lua @@ -0,0 +1,19 @@ +--- vellum.nvim: live GitHub-markdown preview in a split, mermaid/math as images +--- `:Vellum` toggles it, `:Vellum export [file.pdf|file.html]` exports. +--- +--- Runs from the prdlk fork's `mdx` branch until blackhat-7/vellum.nvim#4 +--- merges: upstream only accepts filetype `markdown`, so `markdown.mdx` +--- buffers could not export, take over the preview or be followed by links, +--- and their import/export lines and {/* comments */} rendered as text. +--- @module plugins.vellum + +---@type LazySpec +return { + "prdlk/vellum.nvim", + branch = "mdx", + -- `markdown.mdx` is the mdx pack's filetype; a dotted filetype only matches + -- a pattern that spells it out + ft = { "markdown", "markdown.mdx" }, + cmd = "Vellum", + opts = {}, +}