Skip to content

Commit f622d26

Browse files
committed
feat: bump to copilot.vim 1.11.0
1 parent 3b7bf91 commit f622d26

File tree

3 files changed

+5
-7
lines changed

3 files changed

+5
-7
lines changed

lua/copilot/client.lua

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ function M.get_node_version()
5656

5757
local node_version = string.match(cmd_output, "^v(%S+)") or ""
5858
local node_version_major = tonumber(string.match(node_version, "^(%d+)%.")) or 0
59+
local node_version_minor = tonumber(string.match(node_version, "^%d+%.(%d+)%.")) or 0
5960

6061
if node_version_major == 0 then
6162
local err = "[Copilot] Could not determine Node.js version"
@@ -72,8 +73,8 @@ function M.get_node_version()
7273
"MoreMsg",
7374
},
7475
}, true, {})
75-
elseif node_version_major < 16 then
76-
local err = string.format("[Copilot] Node.js version 16.x or newer required but found %s", node_version)
76+
elseif node_version_major < 16 or (node_version_major == 16 and node_version_minor < 14) then
77+
local err = string.format("[Copilot] Node.js version 18.x or newer required but found %s", node_version)
7778
vim.notify(err, vim.log.levels.WARN)
7879
end
7980

@@ -193,9 +194,6 @@ local function prepare_client_config(overrides)
193194
vim.schedule(function()
194195
---@type copilot_set_editor_info_params
195196
local set_editor_info_params = util.get_editor_info()
196-
set_editor_info_params.editorInfo.version = set_editor_info_params.editorInfo.version
197-
.. " + Node.js "
198-
.. M.get_node_version()
199197
set_editor_info_params.editorConfiguration = util.get_editor_configuration()
200198
set_editor_info_params.networkProxy = util.get_network_proxy()
201199
api.set_editor_info(client, set_editor_info_params, function(err)

lua/copilot/config.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ local default_config = {
2121
suggestion = {
2222
enabled = true,
2323
auto_trigger = false,
24-
debounce = 75,
24+
debounce = 15,
2525
---@type table<'accept'|'accept_word'|'accept_line'|'next'|'prev'|'dismiss', false|string>
2626
keymap = {
2727
accept = "<M-l>",

lua/copilot/util.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ function M.get_editor_info()
2020
editorPluginInfo = {
2121
name = "copilot.lua",
2222
-- reflects version of github/copilot.vim
23-
version = "1.10.3",
23+
version = "1.11.0",
2424
},
2525
}
2626
return info

0 commit comments

Comments
 (0)