bat
A 'cat' replacement that adds syntax highlighting, git change indicators, and automatic paging when you print a file to the terminal.
🔗 Visit batDescription
Printing a file with 'cat' gives you plain, unstyled text — fine for a quick peek, but not great for actually reading code, since there's no color to distinguish keywords from strings from comments. bat solves that by highlighting the syntax of whatever you're viewing, the same way a code editor would, directly in your terminal, plus showing you which lines have changed if the file is in a git repository.
bat provides syntax highlighting for 200+ languages, git integration with change indicators in the margin, automatic paging for long output, and can display non-printable characters. It integrates well with tools like fzf, ripgrep and git, supports custom syntax definitions and themes, and is written in Rust. It's free and dual-licensed under MIT or Apache 2.0, with 60.2k GitHub stars and very active development (4,000+ commits).
💬 Our review
The short version: bat is what 'cat' would look like if it were built today — same job of printing a file, but with syntax highlighting and git awareness that make it genuinely nicer to read code without opening an editor.
Against plain cat, the entire value is readability: syntax-colored output for 200+ languages and inline git change markers turn a quick file dump into something closer to a code review view. Against less/more, which are built for paging through long files, bat actually pages automatically for long output too, so it covers that case as well while adding the highlighting less/more don't have. A few rough edges exist — files containing raw ANSI escape codes can render oddly, and on some Debian/Ubuntu systems it's packaged as 'batcat' instead of 'bat', which trips up first-time users. None of that outweighs how often it's genuinely useful, and being free with 60k+ stars, it's one of the most widely adopted terminal upgrades available.
💰 Pricing
📊 Global score
🤖 AI-enriched data
Projet open source (double licence MIT/Apache 2.0), aucune offre payante
Pros
Coloration syntaxique pour 200+ langages
Indicateurs de changements git dans la marge
Pagination automatique pour les longues sorties
S'intègre bien avec fzf, ripgrep et git
60 200+ étoiles, développement très actif
Cons
Rendu parfois perturbé par des séquences ANSI brutes dans les fichiers
Support d'encodage limité à UTF-8/UTF-16
Packagé sous le nom batcat sur certains systèmes Debian/Ubuntu, ce qui déroute au premier abord
