Alternatives to bat

Like cat, but with syntax highlighting, line numbers, Git markers and a pager when the file is long. The listings below can replace it for an important use case. Each note says what changes if you switch.

The original

Replacements

Listings that take over the same core job as bat.

  • Glow

    Reads Markdown files in a terminal with proper formatting, and finds them for you in the current directory or git repository.

    Glow formats only Markdown files in the terminal, so it suits READMEs and notes but lacks bat's syntax highlighting for source code and Git margin markers.

  • ov

    Read long command output with a configurable terminal pager.

    ov is a configurable pager with search, column views and file-following modes, but it does not offer bat's syntax highlighting or Git integration.

Similar software

Related functionality, not a direct replacement.