
Show HN: Leader – VIM's leader key for your terminal - dhamidi
https://dhamidi.github.io/leader/
======
Annatar
It is not a good idea to use the backslash as the trigger key since it is the
traditional line continuation and escape character on UNIX.

Furthermore it is not a good idea to replace the command line with a menu
since that limits what is possible in UNIX. If we didn’t design a menu driven
system on UNIX in the past 40 years there is a reason for that:

[http://www.catb.org/esr/writings/taoup/html/](http://www.catb.org/esr/writings/taoup/html/)

~~~
dhamidi
> It is not a good idea to use the backslash as the trigger key since it is
> the traditional line continuation and escape character on UNIX.

Well it is also the default key binding for VIM's leader key and placed on the
home row on US keyboards which makes it really accessible.

What is not shown in the demo screencast is that leader detects whether the
cursor is inside a quoted string and in that case doesn't present a menu but
tells the shell to insert a literal backspace at the current cursor position.

For continuing lines on an interactive shell the user would have to press
Ctrl+V followed by a backslash to insert a literal backslash. In my experience
this is rarely necessary in an interactive terminal so the extra utility
gained by having leader on the home row outweighs the extra key press
necessary for continuing a line.

> Furthermore it is not a good idea to replace the command line with a menu
> since that limits what is possible in UNIX.

That is true. Leader is not _replacing_ the command line, the command line
still works as usual, the only difference is that you can launch a menu by
typing backslash to quickly run a command.

