biscuit icon indicating copy to clipboard operation
biscuit copied to clipboard

Vim mode

Open tomlin7 opened this issue 1 year ago • 0 comments

Feature

As many code editors now come with built-in Vim mode, it would be a great enhancement to add this feature to Biscuit. This issue will address only the basic steps of implementing Vim mode.

🚧 As this is a large feature, individual issues/pr shall be opened for individual parts of this feature.

Suggestions needed on following

We aim to create something bit different from existing vim mode plugins of editors

  • where to show the current mode? status bar, title bar, or somewhere else?
  • where to show the command line?

TODO

  • [ ] toggle vim mode via settings, keyboard shortcut, welcome page, or command palette
  • [ ] normal, insert, visual, and command modes indicator

Normal mode

  • [ ] h, j, k, l for navigation
  • [ ] beginning of the file: gg, end of file G
  • [ ] dd (delete line), yy (yank line), p (paste)
  • [ ] u (undo), ctrl-r (redo)
  • [ ] x (delete), dw (delete from cursor to word end), diw (delete word under cursor), cw (cut from cursor to word end), ciw (cut word under cursor)

Visual mode

  • [ ] select text with v or mouse
  • [ ] line selection with V

Insert mode

  • [ ] i (insert), I (insert at line start), a (insert after cursor), A (insert at line end), o (insert in new line), O (insert in new line above)
  • [ ] esc to go back to normal mode.

Command Mode (:)

  • [ ] :w (save), :q (quit), :wq (save and quit)
  • [ ] goto line :64

tomlin7 avatar Oct 10 '24 10:10 tomlin7