An Emacs major mode for editing Rust code, providing syntax highlighting, indentation, and integration with Cargo, rustfmt, and Clippy.
rust-mode is the official Emacs major mode for editing Rust code, providing essential features like syntax highlighting, indentation, and integration with Rust's toolchain (Cargo, rustfmt, Clippy). It solves the problem of efficiently writing and managing Rust projects within the Emacs editor by offering a tailored environment that supports Rust's conventions and workflows.
Rust developers who use Emacs as their primary editor and want a stable, feature-rich mode for Rust development with seamless tool integration.
Developers choose rust-mode because it's the standard, well-maintained Emacs mode for Rust, offering reliable core functionality, official support from the Rust project, and extensibility through a rich ecosystem of Emacs packages.
Emacs configuration for Rust
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Seamlessly integrates with Rust's core tools like Cargo for running, testing, and compiling, and rustfmt for code formatting, with dedicated commands and key bindings as detailed in the feature guide.
Focuses on essential editing features like syntax highlighting and indentation, providing a reliable base that avoids bloat and is maintained by the Rust project, ensuring long-term compatibility.
Compatible with LSP clients like eglot and lsp-mode, and supports optional tree-sitter mode for improved parsing, allowing users to add advanced functionality without modifying the core package.
Includes commands like rust-dbg-wrap-or-unwrap for quickly adding or removing dbg!() wrappers, streamlining debugging workflows directly from the editor.
Does not provide auto-completion, code navigation, or refactoring tools natively, requiring setup with external packages like LSP clients, which the README explicitly acknowledges as not included.
Can suffer from severe lag when editing larger files with certain Emacs modes, such as rust-syntax-propertize with adaptive-wrap-prefix-mode, as documented in the known issues section.
Achieving a full IDE experience necessitates manual installation and configuration of additional packages for LSP, auto-completion, and other features, adding to initial setup time and complexity.