Closed krstp closed 2 years ago
Does this plugin works with regular Vim installed from another source?
Please, Test with Vim 9 if possible
The copilot plugin is only compatible with Neovim.
from https://github.com/github/copilot.vim "Copilot.vim is a Vim plugin for GitHub Copilot. For now, it requires Neovim 0.6 (for virtual lines support) and a Node.js installation." Agree, Not an macvim issue from what I see.
Yeah MacVim is a fork of Vim, not Neovim. You would need to use a Neovim GUI instead, e.g. Neovide, VimR, etc (I haven't used each much so can't really comment on their qualities).
Looking through the plugin, seems like they are saying they need Neovim for the virtual text support. I would imagine they could have supported regular Vim via popup windows (released in 8.2) if they wanted to, but may not have decided to spend the time. Looking through their code seems like they essentially only call nvim_buf_set_extmark
and nvim_buf_del_extmark
, and can easily replace those calls with Vim popup's. However, I don't have a subscription and will not be willing to pay for it to try it out so that's the extent of my digging (they say it is free for popular open-source software maintainers but MacVim is not considered as popular enough).
I would suggest just submitting a pull request to their plugin to add popup support (it actually seems quite manageable given the small amount of Neovim dependency they use) or just file a feedback. I would imagine they have incentives to support Vim if they want to compete with the likes of Tabnine.
Appreciate the insight. Much helpful. When I have time I will look into it more as well. Thanks!
The latest patch(+patch 9.0.0162) of vim9 already support the virtual text
feature, and Copilot.vim has also supported it in v1.5.0.
Well to be fair Vim's support for virtual text is not considered to ready for prime time yet as far as I understand.
Steps to reproduce
:Copilot enable
:Copilot status
, which should reportenabled and online
, instead it reports back theghost text required neovim v.0.6
, which is not exactly accurate. The same instance of underlyingnvim
(@0.7.2) in terminal window works with copilot as desired.Expected behaviour
Functional GitHub Copilot within MacVim. Currently when typing the Copilot instead of displaying proposed code, instead reports
function: syntax error
Version of Vim and architecture
VIM - Vi IMproved 8.2; NVIM v0.7.2
Environment
OS: MacOS Shell: zsh $TERM: xterm-256color Terminal: iTerm
How MacVim was installed
Binary download
Logs and stack traces
No response
Vim configuration where issue is reproducable
No response
Issue has been tested with given configuration
Issue has been tested with no configuration
mvim --clean
(orgvim
, supplied by MacVim distribution)vim --clean
(in terminal, supplied by MacVim distribution)vim --clean
(in terminal, other suppliers, e.g. /usr/bin/vim)Other conditions