cbfmt
« Back to VersTracker
Description:
Format codeblocks inside markdown and org documents
Type: Formula  |  Latest Version: 0.2.0@0  |  Tracked Since: Dec 17, 2025
Links: Homepage  |  formulae.brew.sh
Category: Developer tools
Tags: markdown formatting developer-tools documentation cli
Install: brew install cbfmt
About:
cbfmt is a command-line tool designed to automatically format code blocks within Markdown and Org-mode documents. It integrates with language formatters like Prettier or Black to ensure code snippets are consistently styled. This helps maintain clean, readable documentation without manual formatting effort.
Key Features:
  • Supports Markdown and Org-mode file formats
  • Uses external language formatters (e.g., prettier, black) via configuration
  • Can be used as a standalone CLI tool or integrated with text editors
  • Preserves document structure while updating only code blocks
Use Cases:
  • Standardizing code examples in technical documentation
  • Pre-commit hooks to enforce code block formatting in READMEs
  • Maintaining consistent style in blog posts or academic papers containing code
Alternatives:
  • prettier – Prettier is a general code formatter that can handle Markdown, but cbfmt is specialized for using multiple external formatters specifically on code blocks.
  • mdformat – mdformat focuses on the Markdown structure itself, whereas cbfmt focuses on the content inside the code fences.
License: MIT
Bottles available for: arm64_tahoe, arm64_sequoia, arm64_sonoma, arm64_ventura, sonoma, ventura, arm64_linux, x86_64_linux
Version History
Detected Version Rev Change Commit
Sep 13, 2025 6:51am 0 VERSION_BUMP 594a613d