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

Do you know anyone who actually does this? Even die-hard vi folks I know can't get used to modes on the command line.


I use vim almost pathologically, but I gave up on set -o vi. Since there's no visual indicator of which mode you're in, it's easy to make confusing mistakes and not the right feedback. It just wasn't worth it.


You can overcome the visual indicator (at least in zsh, not sure about bash): http://unix.stackexchange.com/questions/547/make-my-zsh-prom...

I'm a recent convert. I don't like using control sequences for anything but screen management.


Sorry - I accidentally downvoted you.


I use vi mode in my shell all the time, and love it. It only took a day or so to get used to it. But then again, I am a die-hard vim user.

What I'd really like, though, would be a vim mode for the shell, not just a vi mode. Then I could use some of vim's more advanced features, which would make the mode even more useful.


If you've set -o vi, then when you're editing a command line:

esc to get into command mode.

v (just the letter v) will open the current command line in a vi or vim session (depending on your default editor).

Now vim to your heart's content.

:wq will get you out of the vi/vim session, and execute whatever you did in your vi/vim session.


There's always Conque.


For about a year or two, I've had set -o vi in my .bashrc. It is just so much easier when you work in Vim more than half the time!

The modes still trip me up sometimes, but a quick <Esc> or <Ctrl+c> fixes that!


I always use set -o vi. It's in all my .bashrc files. Wish every CLI had it.


I can only speak for myself. Give it a day or two, and it will quickly become as transparent as your editing sessions. Once you cut over, you can forget about chording and arrow keys. Just one key: <Esc>.




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

Search: