mrjones2014 / smart-splits.nvim

🧠 Smart, seamless, directional navigation and resizing of Neovim + terminal multiplexer splits. Supports tmux, Wezterm, and Kitty. Think about splits in terms of "up/down/left/right".
MIT License
831 stars 33 forks source link

feat(mux): Support splitting Kitty multiplexer panes #206

Closed mochouaaaaa closed 2 months ago

mochouaaaaa commented 2 months ago

Fixes #205

How to test

Ensure you've run post-install hooks for kitty; I think you can do this via :Lazy sync<cr>

  1. Use following config in a Kitty multiplexer session:
-- the actual keys `<M-C-k>` can be whatever you'd like
vim.keymap.set("n", "<M-C-k>", function()
    mux.split_pane("up")
end)
vim.keymap.set("n", "<M-C-j>", function()
    mux.split_pane("down")
end)
vim.keymap.set("n", "<M-C-h>", function()
    mux.split_pane("left")
end)
vim.keymap.set("n", "<M-C-l>", function()
    mux.split_pane("right")
end)
  1. Use the keymaps, they should create kitty splits
mrjones2014 commented 2 months ago

Looks like there is one Luacheck warning that needs to be resolved, but looks good other than that. https://github.com/mrjones2014/smart-splits.nvim/actions/runs/9360568332/job/25782345774?pr=206#step:6:15