Skip to content

Commit 1d6911f

Browse files
authored
fix: add back sticky loading on opening window (#1210)
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
1 parent 4c80c0b commit 1d6911f

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

lua/CopilotChat/init.lua

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -729,6 +729,19 @@ function M.open(config)
729729
utils.return_to_normal_mode()
730730

731731
M.chat:open(config)
732+
733+
local message = M.chat:get_message('user')
734+
if message then
735+
local prompt = insert_sticky(message.content, config)
736+
if prompt then
737+
M.chat:add_message({
738+
role = 'user',
739+
content = '\n' .. prompt,
740+
}, true)
741+
M.chat:finish()
742+
end
743+
end
744+
732745
M.chat:follow()
733746
M.chat:focus()
734747
end

0 commit comments

Comments
 (0)