copilot.lua
copilot.lua copied to clipboard
suggestion.lua executes an assignment *only* with 0.10.x but not 0.11.0+ ?
I was reading the title module in order to understand what the config's suggestion.enabled actually controls, and I encountered near the top:
local _, has_nvim_0_10_x = pcall(function()
return vim.version().minor == 10
end)
then down below the sole reference to has_nvim_0_10_x:
local cursor_keys = "<End>"
if has_nvim_0_10_x then
cursor_keys = string.rep("<Down>", #vim.split(newText, "\n", { plain = true }) - 1) .. cursor_keys
end
Now, I am pretty ignorant, so I have to allow for the possibility that the call to string.rep should be made only with 0.10.0. But I worry.