awesome-repositories.com
Blog
MCP
awesome-repositories.com

Discover the best open-source repositories with AI-powered search.

ExploreCurated searchesOpen-source alternativesSelf-hosted softwareBlogSitemap
ProjectMCP serverAboutHow we rankPress
LegalPrivacyTerms
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
rust-lang-nursery avatar

rust-lang-nursery/rustfmt

0
View on GitHub↗
rust-lang.github.io/rustfmt↗

Rustfmt

rustfmt is a tool that automatically rewrites Rust source code to adhere to a consistent and standardized style guide. It functions as both a code formatter for transforming source files and a style linter used to verify if code matches required formatting rules.

The system is configurable, allowing for the definition of custom formatting rules and language editions through configuration files to override default styles. It also supports selective formatting by using dedicated skip markers to prevent specific blocks of code from being modified.

The tool provides capabilities for both source code rewriting across project directories and style compliance verification to identify non-compliant source during automated builds.

AI search

Explore more awesome repositories

Describe what you need in plain English — the AI ranks thousands of curated open-source projects by relevance.

Start searching with AI

Features

  • Source Code Rewriting - Automatically rewrites Rust source code to adhere to a consistent style guide across project directories.
  • Source Code Formatters - Preventing specific blocks of Rust code from being modified by the formatter using dedicated skip markers.
  • Automatic Code Formatters - Automatically rewrites Rust source code to adhere to a consistent and standardized style guide.
  • Coding Style Tools - Includes a verification utility to check if source code matches the required style guide for automated builds.
  • Formatting Configurations - Allows customization of formatting behavior and language editions via a configuration file.
  • Formatting Engines - Provides a rule-based engine that determines the final layout of tokens and whitespace based on configuration.
  • Style Compliance Tools - Verifies that Rust code matches required style guidelines to prevent errors during CI processes.
  • Style Linters - Verifies if Rust code matches required formatting rules and returns errors for non-compliant source.
  • Formatter Configurations - Utilizes external configuration files to define formatting rules and file exclusion patterns.
  • Formatting Exclusion Directives - Provides mechanisms to selectively disable code formatting for specific blocks using skip markers.
  • Formatting Exclusion Markers - Identifies specific attributes or comments in the source to skip the transformation process for those code segments.
  • Token Stream Preservation - Maintains a mapping of original tokens to ensure comments and attributes remain attached to their related expressions.
  • Idempotency Patterns - Employs an idempotent formatting cycle to ensure stable and consistent style application through repeated processing.
  • Language-Specific Formatting Overrides - Supports defining specific formatting overrides and language editions for Rust projects.
  • Recursive Tree Transformers - Uses a recursive tree transformer to walk the syntax tree and apply indentation and line-breaking rules.
  • Developer Tools - Tool for enforcing consistent code formatting.
6,877 stars·1,020 forks·Rust·Apache-2.0·15 views

Star history

Star history chart for rust-lang-nursery/rustfmtStar history chart for rust-lang-nursery/rustfmt

How this analysis was created: This summary and feature list are AI-generated from collected project material and can contain mistakes. Stars, license and language are imported from GitHub. Inclusion does not mean that we have tested or audited this project. Check the source documentation for any feature you depend on. Learn more on our About page.

Frequently asked questions

What does rust-lang-nursery/rustfmt do?

rustfmt is a tool that automatically rewrites Rust source code to adhere to a consistent and standardized style guide. It functions as both a code formatter for transforming source files and a style linter used to verify if code matches required formatting rules.

What are the main features of rust-lang-nursery/rustfmt?

The main features of rust-lang-nursery/rustfmt are: Source Code Rewriting, Source Code Formatters, Automatic Code Formatters, Coding Style Tools, Formatting Configurations, Formatting Engines, Style Compliance Tools, Style Linters.

Which projects share features with rust-lang-nursery/rustfmt?

Projects with overlapping indexed features include: google/google-java-format — google-java-format is a Java code formatter and style enforcement tool. It reformats Java source code to adhere to a… rust-lang/rust-clippy — This project is a static analysis linter, code quality tool, and language auditor for Rust. It functions as an… beautify-web/js-beautify — js-beautify is a web language beautifier and code formatter designed to standardize the layout and structure of… standard/standard — Standard is a suite of static analysis tools for JavaScript, comprising a linter, formatter, and a predefined style… rubocop/rubocop — RuboCop is a static code analyzer, linter, and formatter for the Ruby language. It identifies style violations,… rust-lang/rustfmt — rustfmt is a Rust code formatter that operates as a Cargo subcommand, applying consistent formatting to Rust source…

Projects sharing features with Rustfmt

These projects share indexed features with Rustfmt. Shared tags can include platform or build tooling; verify the primary use case before treating a result as a replacement.
  • google/google-java-formatgoogle avatar

    google/google-java-format

    6,145View on GitHub↗

    google-java-format is a Java code formatter and style enforcement tool. It reformats Java source code to adhere to a standardized style guide, ensuring consistent layout and indentation across entire projects or individual files. The project functions as a build pipeline linting tool for continuous integration workflows and as an IDE formatting plugin to replace native editor formatting. It can be embedded as a formatting library within code generation software to ensure machine-written output remains human-readable. The tool provides capabilities for reorganizing source code indentation and

    Java
    View on GitHub↗6,145
  • rust-lang/rust-clippyrust-lang avatar

    rust-lang/rust-clippy

    13,309View on GitHub↗

    This project is a static analysis linter, code quality tool, and language auditor for Rust. It functions as an automated refactoring system designed to identify common mistakes and suggest idiomatic improvements for Rust source code. The tool identifies non-idiomatic patterns, performance bottlenecks, and code smells to improve the overall correctness and quality of the code. It specifically audits memory safety by flagging suspicious use of unsafe blocks and pointer manipulations and detects inefficient operations to optimize execution speed. The analysis surface covers coding style enforce

    Rustlintrust
    View on GitHub↗13,309
  • beautify-web/js-beautifybeautify-web avatar

    beautify-web/js-beautify

    8,973View on GitHub↗

    js-beautify is a web language beautifier and code formatter designed to standardize the layout and structure of JavaScript, HTML, and CSS files. It reorganizes source code into a consistent, readable style by applying configurable indentation and spacing rules. The project includes a utility for unpacking minified scripts, which transforms compressed or obfuscated JavaScript into a human-readable format. It provides a command-line interface for executing bulk code reformatting across multiple files. The tool supports customizable formatting rules and language-specific overrides, which can be

    JavaScript
    View on GitHub↗8,973
  • rubocop/rubocoprubocop avatar

    rubocop/rubocop

    12,879View on GitHub↗

    RuboCop is a static code analyzer, linter, and formatter for the Ruby language. It identifies style violations, smells, and errors in source code to ensure consistency and maintainability based on community guidelines. The project provides automatic source code formatting to rewrite files according to defined stylistic standards. It also functions as a language server protocol implementation, surfacing violations and suggested fixes directly within code editors. The tool covers code complexity monitoring to track the size of classes and methods and employs non-inclusive language detection to

    Rubycode-formatterhacktoberfestlinter
    View on GitHub↗12,879
  • Compare all 30 related projects→