oh-my-zsh overrides default Meta-. behavior #497

akahn opened this Issue Jul 25, 2011 · 12 comments


None yet
10 participants

akahn commented Jul 25, 2011

In bash and zsh Meta-. ("meta-dot") inserts arguments from previous commands into the current command line. It's kind of like !$, but more interactive because it cycles through older arguments as you continue pressing the keybinding.

In oh-my-zsh, this same key combination does the equivalent of cd ... Is it intentional that oh-my-zsh overrides this built-in shell feature?

Here is the place in the code that sets this binding: https://github.com/robbyrussell/oh-my-zsh/blob/master/lib/key-bindings.zsh#L6

I'm quite bothered by this. Many shells implement this feature, so it works everywhere and I'm quite used to that.


gwjo commented Aug 3, 2011

Looking at the history this seems like a day 1 behavior, I guess @robbyrussell would need to answer if this is intentional or not.

That said, the insert-last-word widget (that does implements this) is also bound to ESC-_ ("escape-underscore") in emacs mode, so you could use that as an alternative. Or you could always set the keybinding back to the way you like it with

bindkey '\e.' insert-last-word

akahn commented Nov 14, 2011

I've patched this over on https://github.com/akahn/oh-my-zsh/compare/fix-alt-dot. Pinging @robbyrussell again so he can weigh in on the fate of this behavior.

reinh commented Mar 29, 2012


reinh commented Mar 29, 2012

Also, #1019 is a duplicate :)


matschaffer commented Apr 2, 2012

+1, although this stuff ultimately led me to roll my own zsh config.

reorx commented Apr 28, 2012

+1, this feature nearly stop me using zsh


andrewtch commented Apr 28, 2012

+1, the default behaiviour is much more handy.

ckrailo commented May 2, 2012

+1 (mostly for the clobber pull request)

+1, just like @reorx, this feature nearly stop me using zsh


matschaffer commented May 29, 2012

Zsh itself is good. My response to this problem was
https://github.com/matschaffer/zundle maybe it'll work for you too.

On May 29, 2012, at 12:43 AM, fanweixiao

+1, just like @reorx, this feature nearly stop me using zsh

Reply to this email directly or view it on GitHub:
#497 (comment)


robbyrussell commented Jun 13, 2012

Believe this is now resolved! update away folks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment