RubyMine 8.0 Help

Rails-Aware Code Completion

In this section, you can find some examples of code completion that RubyMine provides for Ruby-on-Rails.

Completing parameters of migration calls

For Ruby on Rails, RubyMine provides resolve and code completion for the parameters of the following migration calls.

  • add_column, remove_column, change_column, change_column_default, rename_column
  • create_table, change_table, drop_table, rename_table
  • add_index, remove_index
  • add_timestamps, remove_timestamps

As you enter parameters, press Ctrl+Space to show the suggestion list. Use Ctrl+P to view which parameter is required.


Completing parameters of a certain format

Some methods expect parameters of a certain type. RubyMine suggests appropriate options in the suggestion list:


Creating dynamic queries

When a variable holds a model object, RubyMine suggests suitable code completion:


Having selected the desired completion, you can create chained queries:


See Also

Last modified: 5 November 2015