zbirenbaum / copilot.lua

Fully featured & enhanced replacement for copilot.vim complete with API for interacting with Github Copilot
MIT License
2.43k stars 64 forks source link

Errors after adding Lua plugin snippets to init.lua config file #264

Closed b9Joker108 closed 5 months ago

b9Joker108 commented 5 months ago

Hi

First, thank you so much for your work on this plugin. I am really thankful for it.

Second, I am such a noobs, sorry.

Third, I added the two Lua code snippets, the recommend snippet to lazy load Copilot, and the default configuration snippet.

Fourth, I ran the file through Luacheck and there was no error.

Fifth, I execute nvim in Termux.

Sixth, I get the following error:

Error detected while processing /data/data/com.termux/files/home/.config/nvim/init.lua:
E5113: Error while calling lua chunk: /data/data/com.termux/files/home/.config/nvim/init.lua:689: attempt to call
global 'use' (a nil value)
stack traceback:
/data/data/com.termux/files/home/.config/nvim/init.lua:689: in main chunk

Note: I did this at the command-line and got this version output:

~node --version
v20.2.0

I don't understand what this means and could really do with some assistance resolving this matter.

Thanking you in anticipation Beauford

MunifTanjim commented 5 months ago

The example script in README.md is for https://github.com/wbthomason/packer.nvim.

If you're using a different plugin manager, you should change it accordingly.