Skip to content
@cmakefmt

cmakefmt

cmakefmt

cmakefmt is a fast, workflow-first CMake formatter built in Rust.

It exists to replace the aging Python cmake-format tool with a single native binary that is easy to install, fast enough for pre-commit and CI, and capable enough for real project use.

What You Will Find Here

Why cmakefmt?

  • Fast enough for editor-on-save, pre-commit hooks, and CI
  • Distributed as one native binary, with no Python environment to manage
  • Designed around real workflows: --check, --diff, --staged, --changed, machine-readable reports, and config introspection
  • Aware of custom command signatures, so project-specific macros and functions format sensibly
  • Built to preserve comments, support formatter disable regions, and behave predictably across whole repositories

Quick Start

brew install cmakefmt/cmakefmt/cmakefmt
cmakefmt --version
cmakefmt --check .
cmakefmt --in-place .

Rust users can also install via:

cargo install cmakefmt-rust

Start Here

Status

cmakefmt is actively maintained and already usable on real projects. It is still pre-1.0, so formatter behavior and packaging details may continue to evolve as the tool matures.

Contributing

Issues, bug reports, regression cases, and pull requests are welcome in cmakefmt/cmakefmt.

Pinned Loading

  1. cmakefmt cmakefmt Public

    A lightning-fast CMake file formatter.

    Rust 3

  2. cmakefmt-action cmakefmt-action Public

    A lightning-fast CMake file formatter powered by cmakefmt.

    TypeScript

  3. vscode-cmakefmt vscode-cmakefmt Public

    A VS Code extension for cmakefmt

    TypeScript 1

  4. homebrew-cmakefmt homebrew-cmakefmt Public

    This tap for the official Homebrew formula for cmakefmt

    Ruby

Repositories

Showing 5 of 5 repositories

People

This organization has no public members. You must be a member to see who’s a part of this organization.

Top languages

Loading…

Most used topics

Loading…