Re:Cool Unix Hacks For Fun and Productivity
by qworty on Sunday November 03, 2013 @09:01AM
(#6663201)
Actually if you really like the vim keybindings you can set your bash to vi mode. That way with escape shift+i you get to the start of the line.
Or if you like to keep the emacs keybindings in your terminal (yep emacs). you could always do ctrl+x e this opens op your $EDITOR with the current text of the command line. Exit the editor and the text will be piped to bash. (Maybe not the correct terminology, but it gets executed by bash)
Re:Cool Unix Hacks For Fun and Productivity
by zenlikethat on Sunday November 03, 2013 @06:05PM
(#6665560)
Ah yes, these can be quite useful. For most use-cases, however, I prefer the emacs keybindings as that's just how I learned (and the lack of a NORMAL-INSERT-VISUAL mode indicator can be a bit confusing).
Re:Cool Unix Hacks For Fun and Productivity
by tsahyt on Sunday November 03, 2013 @01:39PM
(#6664403)
You can also add this line to .inputrc which will give you vim keybindings in everything that uses the readline library (for instance, ghci, ipython or gdb). However, I found that it breaks a few things in gdb though.
Or if you like to keep the emacs keybindings in your terminal (yep emacs). you could always do ctrl+x e this opens op your $EDITOR with the current text of the command line. Exit the editor and the text will be piped to bash. (Maybe not the correct terminology, but it gets executed by bash)
add this to your ~/.bashrc set -o vi
I love CTRL-X CTRL-E!
Thanks for your feedback!