Rust is a popular programming language that offers high performance, reliability, and memory safety. Rust is widely used for system programming, web development, embedded systems, and more. However, Rust also has a steep learning curve and requires a lot of tooling and configuration to get started. This is where an integrated development environment (IDE) can help.
JetBrains is a well-known company that produces many popular IDEs for various languages and technologies, such as IntelliJ IDEA for Java, PyCharm for Python, CLion for C/C++, and WebStorm for web development. JetBrains has recently announced the preview of RustRover, a standalone IDE for Rust that aims to provide a full-fledged Rust development environment with smart coding assistance, seamless toolchain management, and team collaboration.
I will review RustRover based on the following criteria:
- Installation and setup
- User interface and usability
- Features and functionality
- Performance and stability
- Pricing and licensing
Installation and setup
To install RustRover, you can visit the JetBrains website and download the installer for your operating system (Windows, macOS, or Linux). The installation process is straightforward and does not require any additional steps or configurations. You can also install RustRover as a plugin in IntelliJ IDEA Ultimate or CLion if you prefer.
To start using RustRover, you need to have the Rust toolchain installed on your machine. RustRover can detect the existing toolchain or help you install it if you don’t have one. You can also choose which toolchain version (stable, beta, or nightly) you want to use for your projects.
To create a new project in RustRover, you can use the built-in wizard that guides you through the process. You can choose from various project templates based on Cargo, the official package manager and build system for Rust. You can also import an existing project from a local directory or a version control system such as Git or GitHub.
User interface and usability
RustRover has a user interface that is similar to other JetBrains IDEs. It has a main editor area where you can write and edit your code, a project explorer where you can browse your files and folders, a toolbar where you can access various actions and commands, and several tool windows where you can view additional information and tools such as Cargo commands, run configurations, test results, debug console, terminal, etc.
RustRover has a dark theme by default, but you can change it to a light theme or customize it according to your preferences. You can also adjust the font size, color scheme, editor layout, keymap, plugins, and other settings in the preferences menu.
RustRover has a high usability level as it provides many features and tools that make the coding experience easier and faster. For example, you can use keyboard shortcuts to perform common tasks such as running or debugging your code, formatting or refactoring your code
Some examples of how the IDE is used for quick development are:
- Creating a new project from a template: RustRover provides various project templates based on Cargo, the official package manager and build system for Rust. You can choose from templates such as Binary, Library, WebAssembly, or Custom. RustRover will automatically generate the necessary files and configurations for your project, such as Cargo.toml, src/main.rs, or src/lib.rs. You can also import an existing project from a local directory or a version control system.
- Writing and editing code with smart assistance: RustRover provides many features and tools that make the coding experience easier and faster. For example, you can use code completion, syntax highlighting, inlined hints, macro expansion, quick documentation, quick definition, and more. RustRover also provides code analysis and error reporting, which can detect and fix problems in your code. You can also use code formatting, refactoring, and generation to improve the quality and structure of your code.
- Running and debugging code with ease: RustRover allows you to run and debug your code with just one click or shortcut. You can use the Run tool window to view the output of your program, or the Debug tool window to inspect the state of your program. You can also use breakpoints, stepping, watches, evaluations, and more to control the execution flow and examine the variables and expressions. RustRover also supports debugging tests, benchmarks, and WebAssembly modules.
- Testing and profiling code with confidence: RustRover supports testing and profiling your code using various tools and frameworks. You can use the Test Runner to run and debug your tests, view the test results, filter and sort the tests, and create test configurations. You can also use the Code Coverage tool to measure how much of your code is covered by tests. RustRover also integrates with external profilers such as perf or Valgrind to help you analyze the performance and memory usage of your code.
- Working with version control systems and remote development: RustRover supports working with various version control systems such as Git or GitHub. You can use the Version Control tool window to view the history, branches, commits, changes, and conflicts of your project. You can also use the VCS operations popup to perform common actions such as commit, push, pull, merge, rebase, etc. RustRover also supports remote development using SSH or WSL. You can connect to a remote server and code, run, debug, and deploy your projects remotely
Features of RustRover
RustRover aims to simplify the Rust coding experience while unlocking the language’s full potential. Some of the features of RustRover are:
- Syntax highlighting: RustRover highlights all elements of your Rust code, including inferred types and macros, cfg blocks, and unsafe code usages.
- On-the-fly analysis: RustRover analyzes your code as you type and suggests quick fixes to resolve the problems automatically.
- Macro expansion: RustRover’s macro expansion engine makes macros transparent to code insight and easier for you to explore. You can select a declarative macro and call either a one-step or a full expansion view.
- Code generation: RustRover helps you save time on typing by generating code for you. You can add missing fields and impl blocks, import unresolved symbols, or insert the code templates you use frequently.
- Completion: RustRover provides relevant completion suggestions everywhere in your code, even inside a macro call or #[derive].
- Navigation & Search: RustRover helps you navigate through code structures and hierarchies with various Go-To actions, accessible via shortcuts and gutter icons. For example, Go to Implementation lets you quickly switch between traits, types, and impls. You can also use Find Usages to track all the occurrences of a symbol in your code.
- Cargo support: RustRover fully integrates with Cargo, the official package manager for Rust. The IDE extracts project information from your Cargo.toml files and provides a wizard to create new Cargo-based projects. You can also call Cargo commands right from the IDE, and the dedicated tool window will help you manage the entire workspace.
- Testing: RustRover makes it easy to start tests and explore the results. You can call cargo test or use the gutter menu, and the IDE will use its own test runner to show you the process. After the tests are finished, you will see a tree view of the results. You can sort it, export test data, and jump back to the code.
- Run, Debug, Analyze: You can get full IDE debugging for your Rust applications in RustRover. You can set breakpoints, step through your code, inspect raw memory, and use many other debug essentials. The IDE’s native type renderers build tree-view representations for most of the Rust types, including strings, structs, enums, vectors, and other standard library types. You can also use Run Targets to run or debug your applications on different platforms or environments, such as Docker containers or remote hosts. Additionally, you can use Code Coverage to measure how much of your code is covered by tests.
- HTTP Client: RustRover comes with a built-in HTTP client that lets you analyze requests and responses for your web applications. You can write HTTP requests in a dedicated scratch file or in any file that supports injections. You can then run them from the editor or from the HTTP Requests tool window. The IDE will show you the response status code, headers, body, cookies, and timings. You can also compare responses or save them for later use.
- Code With Me: RustRover supports Code With Me, a service that allows you to share your project with others and collaborate on it in real-time. You can invite your teammates or clients to join your session via a link or an email invitation. You can then work on the same codebase simultaneously, chat with each other via audio or video calls or text messages, share your local servers or terminals, and debug together.
Performance of RustRover
RustRover is designed to be fast and responsive even for large and complex projects. The IDE uses incremental compilation and caching to speed up the build process and reduce resource consumption. The IDE also leverages the power of the IntelliJ platform’s indexing mechanism to provide fast and accurate code analysis and navigation. RustRover also supports the experimental rust-analyzer engine, which is a new language server implementation for Rust that aims to provide better performance and scalability.
Pricing of RustRover
RustRover is currently in preview and is free to use during the public preview period. The license model and the pricing will be finalized closer to the date of the commercial release, which is expected to be before September 2024. JetBrains plans to offer RustRover as a standalone commercial IDE or as part of the All Products Pack, which includes access to all JetBrains IDEs and tools. They say that the development of the currently available Rust plugin for CLion and IntelliJ IDEs has ceased and this tool will not be actively supported going forward, being replaced by commercial RustRover IDE. JetBrains also offers discounts and free licenses for students, teachers, open-source contributors, startups, and non-commercial organizations.
Conclusion
RustRover is a new IDE for Rust developers that offers a comprehensive and integrated development environment. RustRover simplifies the Rust coding experience with features such as smart coding assistance, seamless Cargo support, a built-in test runner, and code coverage tooling. RustRover also provides advanced functionality such as debugging, run targets, HTTP client, and “code with me”. RustRover is based on the IntelliJ platform and inherits many features from other JetBrains IDEs.
If you are interested in trying out RustRover, you can download it from the official website or from the JetBrains Toolbox App. You can also read more about RustRover on the IntelliJ Rust blog or watch the video introduction. You can also join the RustRover Early Access Program (EAP) and give your feedback and suggestions to help shape the product. You can report issues or feature requests on the issue tracker or on the forum. You can also follow RustRover on Twitter for the latest news and updates.
We hope you enjoy using RustRover and find it useful for your Rust development needs. Happy coding!