lem icon indicating copy to clipboard operation
lem copied to clipboard

vi-mode: `dd` and `dG` don't work properly with a blank line at the end of buffer

Open DefaultGen opened this issue 2 years ago • 1 comments

These don't work as expected when vi-mode is enabled and the last line of the buffer is blank:

  1. If you dd the last line, that line should be deleted and the cursor moved up one line. In lem, the cursor stays on the blank line.
  2. dG from an arbitrary line should delete everything to the end of the buffer and move the cursor up one line. In lem, it doesn't remove the blank last line and moves the cursor there.
  3. If you use dG on the blank last line of a buffer, it incorrectly deletes previous line (and keeps the blank line). It should just delete the blank line.

DefaultGen avatar May 24 '24 19:05 DefaultGen

merge with https://github.com/lem-project/lem/issues/278

cxxxr avatar Jul 15 '24 09:07 cxxxr