jackMort / ChatGPT.nvim

ChatGPT Neovim Plugin: Effortless Natural Language Generation with OpenAI's ChatGPT API
Apache License 2.0
3.75k stars 312 forks source link

[feature request]: Add some events for autocmd to the plugin #189

Open shutils opened 1 year ago

shutils commented 1 year ago

Hello everyone.

How about adding some events for autocmd to the events (open, close, etc.) of this plugin? This will allow users to have more versatile settings. For example, the following GIF is my use case.

for_chatgpt

In this example, I'm using the popup feature of tmux and using neovim as an interface for ChatGPT. I'm using an event to close neovim when ChatGPT finishes. This way, I can easily access ChatGPT even during non-coding work (in my case, server maintenance). Of course, some users might come up with even better ways to use it.

This time, I added events only to the part where the chat window closes, but there may be other useful events as well. I would like to hear everyone's opinions on this matter.

Gauserr commented 1 year ago

Awesome idea