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

Copilot should allow enable even if the filetypes are disabled by default. #248

Closed fishman closed 6 months ago

fishman commented 6 months ago

For security reasons it should be possible to only toggle it for the current file even if all filetypes are set to disable.

Copilot enable does not currently enable copilot in that case but should.

fishman commented 6 months ago

I guess it's possible to do that with Copilot! enable. The problem is that when that option is used it will force enable it for all subsequent files as well.

This isn't the behaviour of the normal plugin. You can enable it per file, but it will still honour the filetype settings for subsequent files.

MunifTanjim commented 6 months ago

I guess it's possible to do that with Copilot! enable. The problem is that when that option is used it will force enable it for all subsequent files as well.

Where did you find that behavior?

MunifTanjim commented 6 months ago

Use :Copilot! attach for force attaching copilot to the current buffer.