RubyMine 5.4.0 Web Help

1.1+

In RubyMine, you can define several Ruby SDKs. So doing, you can choose the one to be used in your project, from the list of the Ruby interpreters available on your machine. RubyMine enables you to specify the standard Ruby interpreter, as well as MacRuby and IronRuby interpreters.

Ruby SDKs can be configured on the following levels:

To configure Ruby SDK for the current project
  1. Open the Project Settings dialog for the current project, and click Ruby SDK and Gems.
  2. If all the desired Ruby interpreters are already installed and added to your project, select one from the Ruby interpreter drop-down list.

    If the desired Ruby SDK is missing from the drop-down list of available interpreters, click Add SDK.

    Note

    • 2.0.2+For the *nix platforms, select from the available rvm SDK's and their gem sets, which enables you to switch between the various independent sandboxes. To do that, select the desired interpreter - gem set pair from the Ruby interpreter drop-down list. Refer to RVM Support for the details of creating the interpreter - gem set pairs, and to the descriptions of *nix-specific controls.

      3.2+For the non-*nix platforms, choose from the Select Interpreter Path list, which shows the SDKs that are included in the PATH variable, but has not yet been added to your project.

      ruby_non_rvm

      If you still cannot see the desired SDK in the list, choose Specify Other, and locate the Ruby interpreter file in the dialog that opens.

    • The name of the Ruby interpreter should contain ruby or ir substring. Otherwise, the selected file will not be recognized as the proper Ruby SDK, and RubyMine will display the following error message:
      "The selected file is not a valid home for Ruby SDK."
  3. If you are using JRuby, select version from the Language level drop-down list:

    ruby_configureSDK.png

    Tip

    Special note for JRuby users:jruby.bat is no longer supported, since it causes erratic behaviour for tools, that try to spawn new ruby instance (e.g. Rake)

  4. In the Installed Gems section, RubyMine displays the list of gems that are currently installed on your computer. For each of the installed gems, you can view its version and description.

    Note that RubyMine smartly renders gems' documentation:

    ruby_installGems2.png

    If some gems are missing, or outdated, click Install Gems / Update gems buttons.

    Refer to the section Resolving Rereferences to Missing Gems.

  5. Apply changes.

See Also

Concepts:

Language and Framework-Specific Guidelines:

Reference:

External Links:

Web Resources: