akinsho / akinsho/toggleterm.nvim

[BUG] Cursor jumping issue with editable-term.nvim

Đang mở
#640 2 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Lua
Star
5.6k
Fork
206
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

### Is there an existing issue for this?

- [x] I have searched the existing issues

### Current Behavior

I'm having an issue where the cursor jumps to the last line in the terminal when doing `diw` from normal mode when using [editable-term.nvim](https://github.com/xb-bx/editable-term.nvim).

[According to the author](https://github.com/xb-bx/editable-term.nvim/issues/5#issuecomment-2809728849) this is an issue with toggleterm.nvim, and not editable-term.nvim.

### Expected Behavior

Cursor stays on the same line efter doing `diw`.

### Steps To Reproduce

Minimal config:

```lua
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({
"git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
"--branch=stable",
lazypath,
})
end
vim.opt.rtp:prepend(lazypath)

require("lazy").setup({
{ "akinsho/toggleterm.nvim", version = "*", config = true },
{
"xb-bx/editable-term.nvim",
opts = {
promts = {
["> "] = {}, -- TODO: Input your shell's prompt here
},
},
},
})
```

1. `nvim -u path/to/config/above -c ToggleTerm`
2. Type `foo`
3. Move to normal mode with ``
4. Press `diw`
5. Cursor jumps to last line in the buffer

### Environment

```Markdown
- OS: EndeavourOS
- neovim version: v0.11.0
- Shell: Zsh
```

### Anything else?

_No response_

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.