-- Scratch terminal for running arbitrary shell commands, toggled like -- claude-code.nvim's own - open/close (not kill) a persistent split. return { "akinsho/toggleterm.nvim", lazy = false, -- global toggle must work from any window, not just after some trigger event opts = { open_mapping = [[]], -- registers n, t (terminal_mappings) and i (insert_mappings) mode maps automatically direction = "vertical", -- toggleterm's vertical direction always opens via "botright vsplit" internally, -- so this already matches claude-code.nvim's right-side placement without -- touching 'splitright'. size = function(term) if term.direction == "vertical" then return math.floor(vim.o.columns * 0.3) -- matches claude-code.nvim's window.position ratio end end, }, }