News for hackers. Stuff that matters.
Re:Tim O'Reilly: I am really starting to hate Mac OS X. by ahlatimer on Saturday November 12, 2011 @02:06PM (#3228560)
iTerm != Terminal. The alt-arrows works in Lion's Terminal; I just checked (although I use iTerm, where it doesn't work). iTerm appears to be the only app that doesn't respond to ctrl/alt-arrows. I use them quite frequently, and it always trips me up that iTerm works differently than essentially every other app.
Re:Tim O'Reilly: I am really starting to hate Mac OS X. by __david__ on Saturday November 12, 2011 @05:11PM (#3229071)
That's because alt-arrow isn't a ANSI control sequence. What should it map to? You can see what your terminal is sending with this command:

    stty -icanon -echo; od -c
Hit your key sequence then hit return a bunch of times until the line comes out. You'll see some sort of ESC sequence.

When done, control-c then type "stty sane" (it will not echo).

For iTerm I get "\e[1;9D". Terminal, interestingly is giving me "\e\eD". When I turn off my "Use option as meta key" preference in Terminal it gives me "\eD". Which is the same as plain left arrow.

Also, neither of those escape sequences does anything in bash for me.

Re:Tim O'Reilly: I am really starting to hate Mac OS X. by mgkimsal on Sunday November 13, 2011 @10:59AM (#3230989)
You're right, in that they're not the same - I use the terms interchangeably sometimes and shouldn't. That said, my snow leaopard Terminal doesn't have those keystrokes working either. :/

I typically use iterm2 now, and I mapped option/left and option/right to ESC-b and ESC-f, and all is well for me. Hope that helps someone else.