Where is GoTo matching brace/do-end?

Hi,

I'm looking for a Go To matching brace or the other end of a do/end block. I can't seem to find one nor did I find one via google. Is there one? I know this exists in NetBeans and emacs so I would expect it be in RubyMine. Thanks for any help!

-Edwin

5 comments
Comment actions Permalink

Nevermind, a co-worker pointed me at this http://www.jetbrains.com/ruby/docs/RubyMine_ReferenceCard_Mac.pdf which says ctrl-a, ctrl-e.

0
Comment actions Permalink

edwingo wrote:

Nevermind, a co-worker pointed me at this http://www.jetbrains.com/ruby/docs/RubyMine_ReferenceCard_Mac.pdf which says ctrl-a, ctrl-e.

Actually, ctrl-a and ctrl-e is similar but not the same thing. It would be nice to have a keystroke that will go to a matching parenthesis/brace/bracket. As far as I can tell, there isn't such a thing. The closest I've been able to figure out is to use ctrl-w to select an expression, which often does not do what I want, or to use the mouse as a fallback.

0
Comment actions Permalink

Hello Edwin,

there is Move Caret to the start/end of code block action with Cmd+[ and Cmd+] shortcuts. By the way, you can search for action with Cmd+Shift+A:
http://f.cl.ly/items/3e0Z2y2x0m2W082J2w2D/Screen%20Shot%202012-03-14%20at%2012.20.29%20PM.png

0
Comment actions Permalink

Thanks for the reply. "Find Action..." is useful. Is there the reverse: given a keystroke, what is the Action bound to it? For example, ^[ and ^A seem to perform the same action, "Move Caret to Code Block Start", but I am unsure. (BTW, it's Control and not Command.)

Also, I was actually looking for something like "Move Caret to Matching <symbol> with Selection" where <symbol> can be '(){}[]<>' which is already highlighted in the editor. There doesn't appear do be such an action even though the editor and user know what will be selected. The action "Move Caret to Next Word with Selection" is a useful workaround but it requires more thinking. When I use emacs, I often want to select such a region and there are keystrokes for that, so my brain is wired that way ;-).

0
Comment actions Permalink
"Find Action..." is useful. Is there the reverse: given a keystroke, what is the Action bound to it?

Settings | Keymap --> click on "funnel" icon (next to "bin" one -- on the right hand side).

0

Please sign in to leave a comment.