Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CLI] Refact chat in Neovim #351

Open
olegklimov opened this issue Oct 7, 2024 · 0 comments
Open

[CLI] Refact chat in Neovim #351

olegklimov opened this issue Oct 7, 2024 · 0 comments

Comments

@olegklimov
Copy link
Contributor

We already have code completion support for Neovim here:

https://github.com/smallcloudai/refact-neovim

It's possible to integrate chat to Neovim as well, using toggleterm:

local Terminal  = require('toggleterm.terminal').Terminal
local refact = Terminal:new({ cmd="refact .", direction="float", hidden=true })

function _refact_toggle()
  refact:toggle()
end

vim.api.nvim_set_keymap("n", "<A-e>", "<cmd>lua _refact_toggle()<CR>", {noremap = true, silent = true})
vim.api.nvim_set_keymap("t", "<A-e>", "<cmd>lua _refact_toggle()<CR>", {noremap = true, silent = true})

Questions:

  1. Does it really work for you?
  2. Any improvements you would like to see?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants