Files
dotfiles-public/private_dot_config/nvim/lua/plugins/claudecode.lua
T
bcherb2 0aaaf51421 feat: nvim config tracks the live tree
Port the live ~/.config/nvim working tree (bcherb2/nvim master plus its
uncommitted git.lua and minimap.lua edits): adds claudecode, eslint, lsp,
typescript, meow-yarn and refactoring-fix specs, drops the files the live
repo deleted, and takes live for everything else.

Kept from public: lazy.lua with luarocks disabled, the ai_assist cond
guard (nvim-ai-assist is not anonymously clonable, so a fresh box only
gets it from the private clone list), and the scrubbed endpoint comment
in place of live's LAN address.
2026-11-18 01:32:57 -05:00

31 lines
999 B
Lua

-- LazyVim's ai.claudecode extra maps "<leader>a" (group) and "<leader>as" (Send to
-- Claude) with mode "v", which also covers Select mode. A space typed over a
-- Shift+arrow selection (selectmode=key) then waits 'timeoutlen' for the rest of
-- a <leader> map instead of replacing the selection at once. Keep those maps in
-- Visual mode only ("x"); Visual <leader>as behaves exactly as before.
return {
{
"coder/claudecode.nvim",
optional = true,
keys = function(_, keys)
local function visual_only(mode)
if mode == "v" then
return "x"
end
if type(mode) == "table" then
return vim.tbl_map(function(m)
return m == "v" and "x" or m
end, mode)
end
return mode
end
return vim.tbl_map(function(k)
if type(k) ~= "table" or k.mode == nil then
return k
end
return vim.tbl_extend("force", k, { mode = visual_only(k.mode) })
end, keys)
end,
},
}