RubyMine 7.0.1 Web Help

The Smart Enter completion enables you to create syntactically correct code constructs.

To automatically complete a statement
  • Start typing a statement, and press Ctrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterShift+⌘+EnterShift ⌘ EnterShift ⌘ EnterShift ⌘ EnterShift ⌘ Enter. The closing punctuation is added, and the caret moves to the next editing position.

For example, start typing a method declaration, and press Ctrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterShift+⌘+EnterShift ⌘ EnterShift ⌘ EnterShift ⌘ EnterShift ⌘ Enter after the opening parenthesis:

ruby_completePunctuation1.png

This will create the entire construct of a method, the caret resting inside the method body:

ruby_completePunctuation2.png

Start typing a code construct:

ruby_completePunctuation3.png

After pressing Ctrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterCtrl+Shift+EnterShift+⌘+EnterShift ⌘ EnterShift ⌘ EnterShift ⌘ EnterShift ⌘ Enter, the construct is completed, and the caret is placed at the next editing position:

ruby_completePunctuation4.png

See Also

Reference:

Web Resources: