Unclear how accept diffs supposed to work #117
-
I have everything working perfectly fine, except for accepting diffs in the Copilot window. Showing diffs works though; it does show the diffs. As I understand it, it must replace the existing code with the code suggested by Copilot. For me, C-Y scrolls by one line, as per the default behavior in Nvim. I have tried remapping C-Y to , but it still does not do anything in the Copilot buffer. I tried with and without specifying mappings = {} in my copilot_chat = require("CopilotChat") copilot_chat.setup({}) It is unclear whether it is supposed to work in any mode, or if it is supported by only a specific mode, like inline chat. Also, I did not understand what complete_after_slash is supposed to do. By the way, maybe it's worth expanding the section about keybindings inside the Copilot window. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
Im assuming this is on canary branch right. The keybindings should work in any mode as the "modes" are just layout of the window anyway. Can you check output of Its possible you have c-y remapped somewhere and its conflicting with the keymap. For complete after slash, its basically just press tab after / in insert mode, I have the description slightly improved in currently open pull request for embeddings so should be tad more explanatory: |
Beta Was this translation helpful? Give feedback.
Oh also for more context, acccepting diffs only works with
visual
andbuffer
andline
selectors. it do not works withunnamed
selecctor (e.g yank). Because it needs to know the original position and that one is stored for visual selection etc but it is not stored for yanking (for obvious reasons as the unnamed register can have anything in it really)