Releases RubyMine

RubyMine 2023.3: Generally Available AI Assistant, Improved Project Indexing, New Supported Libraries and Technologies

RubyMine 2023.3 is now available!

As we announced in our previous blog post, the latest version of our popular Ruby and Rails IDE comes complete with RubyMine’s improved project indexing. 

We also identified and resolved several problems that had been causing low memory performance and freezes when running larger test suites with the profiler in RubyMine.

Starting from this release, RubyMine introduces support for popular libraries and technologies. This includes running RuboCop in server mode automatically, Brakeman code inspections, working with parameterized table specs using the rspec-parameterized gem, and much more!

Below is a brief overview of the most notable features. For a detailed description of this update, please visit our What’s New page.

You can get the new build from our website or via the free Toolbox App.

AI Assistant is now generally available

This summer we announced our new AI Assistant, which integrates the power of LLM into the daily workflows of developers. Since then, AI Assistant has been in the technical preview stage and available only to a limited number of people. In RubyMine 2023.3 it’s available to everyone with a JetBrains AI subscription as a supplemental feature. Please refer to our JetBrains AI page in case you have any questions.

Support for AI-generated name suggestions

You can now enable AI-generated name suggestions for local variables and parameters in your Ruby code. This action is available when you use the Rename refactoring inline.

To enable name suggestions, select the Provide AI-generated name suggestions checkbox in Settings | Tools | AI Assistant.

Improved Ruby contexts

We are consistently enhancing Ruby contexts and refining the manner in which LLMs analyze your codebase. These modifications impact how the AI Assistant generates documentation, elucidates your Ruby code, identifies file contents, and more.

Unit test generation

With AI Assistant, you can effortlessly generate tests for public methods in your Ruby or Rails application.

Select the method you want to cover with tests, and press ⌥ + Enter on macOS or Alt + Enter on Windows. From the context menu, select AI Actions and then Generate Unit Tests.

Custom paths for Rails applications and engines

RubyMine recognizes when you use custom paths in your Rails applications and engines. In addition to the default paths, such as app, app/controllers, and app/models, the IDE recognizes any other locations in your project when the project structure is configured. This enables you to redefine the default structure and still benefit from RubyMine’s code insight features. 

To set up custom paths, navigate to Settings | Languages & Frameworks | Rails | Paths.

Auto-import of Rails paths

We implemented a new option to automatically detect custom paths within your Rails application. Every time you open your project, RubyMine attempts to import the Rails paths configuration in the background.

Code insight for models, controllers, and mailers stored outside of their default locations

All of your favorite code insight features, such as navigation and type support, will now work with models, controllers, and mailers, even if they are outside of their default directories.

Сode insight for Rails 7.1 strict locals

RubyMine now supports resolution, completion, Find Usages, Rename, and navigation features for strict locals.

Type provision for custom self-types inside blocks

RubyMine now has support for customizing the self-type of blocks from RBS to Ruby. This feature is beneficial for DSLs and will help RubyMine recognize them, enhancing code insight.

Custom annotation to specify the self-type of blocks

Now, by utilizing a YARD-like comment, you can explicitly state the self-type of blocks directly within them.

Support for extra declarations from RBS

We’ve implemented basic support to recognize extra declarations from RBS when they are absent in your Ruby files. This is particularly beneficial for projects that extensively use reflection, as it allows for these declarations to still be present in completion and other RubyMine features. The feature is available for classes, modules, constants, methods, and variables.

RuboCop in server mode

RubyMine supports running RuboCop in server mode automatically. For this functionality to work, make sure the following requirements are met:

  • Linux or MacOS
  • Local Ruby MRI 2.3 or later
  • RuboCop 1.31 or later

Brakeman code inspections

Now, you can conveniently see Brakeman’s insights within RubyMine in a user-friendly format. Tackle security issues promptly, with easy access to Brakeman’s documentation, confidence indicators, and more.

Make sure that you have the brakeman gem installed, and then go to Code | Analyze Code | Run inspection by name and launch the analysis.

Parameterized specs with rspec-parameterized

RubyMine provides comprehensive support for theRSpec::Parameterized syntax, including recognition, resolution, and completion suggestions.

We’ve also implemented run/debug configurations to enhance your testing experience.

Fixture declarations with let_it_be

We’ve added support for fixture declarations in RSpec tests using let_it_be blocks. This includes features such as variable resolution, syntax highlighting, automatic handling of do block insertion for before_all, and more.

To enable the functionality, you need to install the test-prof gem.

To learn about the newest features as they come out, please follow RubyMine on Twitter. We post product news and tips several times a week.

We invite you to share your thoughts in the comments below and to suggest and vote for new features in the issue tracker.

Happy developing!

The RubyMine team

image description