Macro can't executes a inserted `<del>` that deletes the newline character
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.2k
- Forks
- 1.5k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 6
Description
Describe the bug
In insert mode, I usually press <del> to delete the newline character (so the last line above will concat the current line). Although this could be recorded by neovim, the vim extension could not record it correctly even if I enabled the neovim setting.
To Reproduce
Steps to reproduce the behavior:
- move the cursor to any lines except the first line.
- press 'q2' to record to q.
- record these:
0i<del><esc>- press
0to move to the head. - press
ito switch to insert mode. - press
<del>to delete the newline character. - press
<esc>to switch to normal mode.
- press
- press '@2' to execute the recorded macro.
Sample
line1
line2
line3
Expected behavior
The insert mode actions should be executed correctly.
Environment (please complete the following information):
- Extension version: 1.25.2
- VS Code version: Code 1.80.1 (74f6148eb9ea00507ec113ec51c489d6ffb4b771, 2023-07-12T17:20:58.115Z)
- OS version: Darwin arm64 22.5.0
Additional context
I tested this on a VSCode profile that installs vim extension only and has no custom settings.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue in the VS Code Vim extension with the recorded 0i<del><esc> macro and compare direct execution with replay via @2. Trace the macro recording and execution paths for insert-mode <del> handling; done means the macro joins the lines by deleting the newline when replayed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript, vscode
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100