Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

If you're a vi user, edit ~/.inputrc and add:

   set editing-mode vi
   set keymap vi-command
This changes readline behavior from emacs to vi. This, along with "set -o vi" in bash, are really handy (though can be frustrating for others if you ever share a keyboard pair programming).


In Zsh, it will set the editing mode to whatever your $EDITOR is set to. So if $EDITOR == vim, readline will be set to vim mode.

I’m a vim person, but I feel like the modal workflow does not work well at all in a shell.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: