RubyMine 2018.1 Help

Running Rake Tasks

Use Run Rake Task command on the Tools menu, and select the desired task from the list.

To run a Rake task

  1. On the main menu, choose Tools | Run Rake Task, or press Ctrl+Alt+R.
    ruby runRakeTask
  2. In the pop-up window, start typing the task name, or its part. RubyMine shows the list of matching Rake tasks. If you want to see all the available tasks, including those without description, select the checkbox Include undocumented.
    ruby runRakeTaskPopup
  3. Select the desired task from the suggestion list, and press Enter.
  4. In the Execute '<Rake task>' dialog box, specify the script arguments, if any, and select the desired environment from the drop-down list.

    If necessary, enable the --trace option by selecting the Full backtrace checkbox. This option is the same as in the Rake run/debug configuration; as soon as this option is set in the run configuration dialog box, it is also set in the Run Rake Task dialog box, and vice versa.

    This behavior is common for the majority of Rake tasks. However, the migration tasks behave differently. Instead of the list of arguments, one should specify the migration version. By default, RubyMine suggests the latest migration version, while all the other migrations that exist in project, are available in the suggestion list.

    For the following migration tasks

    • db:migrate:up
    • db:migrate:down

    depending on the context where they are invoked, RubyMine suggests by default the migration that is currently selected in the Project tool window, or open in the editor. So doing, the editor has the priority: if a certain migration is selected in the Project tool window, and another one is open in the editor, and the editor gets the focus, the default migration version will be the one in the editor .

  5. Click OK.
Last modified: 1 August 2018

See Also