From cc9c488b23dacc748139dcf5a2cef4996db2a5c3 Mon Sep 17 00:00:00 2001 From: Tomas Slusny Date: Sun, 9 Mar 2025 18:35:31 +0100 Subject: [PATCH] fix: properly split chat horizonatally/vertically when existing splits are open Signed-off-by: Tomas Slusny --- lua/CopilotChat/ui/chat.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lua/CopilotChat/ui/chat.lua b/lua/CopilotChat/ui/chat.lua index 8b4b934c..b51a1915 100644 --- a/lua/CopilotChat/ui/chat.lua +++ b/lua/CopilotChat/ui/chat.lua @@ -310,6 +310,7 @@ function Chat:open(config) if width ~= 0 then cmd = width .. cmd end + cmd = 'botright ' .. cmd vim.cmd(cmd) self.winnr = vim.api.nvim_get_current_win() vim.api.nvim_set_current_win(orig) @@ -319,6 +320,7 @@ function Chat:open(config) if height ~= 0 then cmd = height .. cmd end + cmd = 'botright ' .. cmd vim.cmd(cmd) self.winnr = vim.api.nvim_get_current_win() vim.api.nvim_set_current_win(orig)