File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -586,7 +586,7 @@ function M.resolve_prompt(prompt, config)
586586 .. vim .trim (require (' CopilotChat.instructions.edit_file_block' ))
587587 end
588588
589- config .system_prompt = config .system_prompt :gsub (' {OS_NAME}' , jit . os )
589+ config .system_prompt = config .system_prompt :gsub (' {OS_NAME}' , vim . uv . os_uname (). sysname )
590590 config .system_prompt = config .system_prompt :gsub (' {LANGUAGE}' , config .language )
591591 config .system_prompt = config .system_prompt :gsub (' {DIR}' , state .source .cwd ())
592592 end
Original file line number Diff line number Diff line change @@ -6,13 +6,14 @@ local class = require('CopilotChat.utils.class')
66--- Get the library extension based on the operating system
77--- @return string
88local function get_lib_extension ()
9- if jit .os :lower () == ' mac' or jit .os :lower () == ' osx' then
9+ local os_name = vim .uv .os_uname ().sysname :lower ()
10+ if os_name :find (' darwin' ) then
1011 return ' .dylib'
11- end
12- if jit .os :lower () == ' windows' then
12+ elseif os_name :find (' windows' ) then
1313 return ' .dll'
14+ else
15+ return ' .so'
1416 end
15- return ' .so'
1617end
1718
1819--- Load tiktoken data from cache or download it
You can’t perform that action at this time.
0 commit comments