---
name: "batman"
section: "1"
platform: "linux"
package: "bat-extras"
version: "2024.08.24-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/batman"
---

# batman(1)

Read system manual pages (man) using bat as the manual page formatter.

## NAME

batman - Read system manual pages (*man*) using *bat* as the manual page formatter.

## DESCRIPTION

Gone are the days of losing your place while reading through monotone manual pages. With *bat* and *batman*, you can read *man ifconfig* with beautiful 24-bit color and syntax higlighting.

If you have *fzf* installed, you can even use *batman* to search through manual pages!

## USAGE

    batman \[SECTION\] \[ENTRY\]

### As a Replacement for Man

With bash:

*bash*\
 *eval "$(batman --export-env)"*\

*With fish:*

*fish*\
 *batman --export-env \| source*\

## ENVIRONMENT

| | |
| --- | --- |
| **Variable** | **Description** |
|
| *MANPAGER* | Changes the pager used for *batman*. This is treated like *BAT\_PAGER*, but only affects this command. |

## CUSTOMIZATION

### Changing the Theme

*You can change the syntax highlighting theme for batman* by setting the *BAT\_THEME* environment variable before calling *batman*. The following wrapper function will change the theme to *Solarized (dark)* without affecting any other *bat* command.

*bash*\
 *batman() {*\
\
     *BAT\_THEME="Solarized (dark)" batman "$@"*\
\
     *return $?*\
 *}*\

## CAVEATS

**Flags aren't highlighted:**

\- This happens when you change *bat*'s theme through *bat*'s config file or the *BAT\_THEME* environment variable. Not all themes provide colours for flags, and it's a known issue.\
 \- You can overriding the theme for *batman* by wrapping it in a function that sets *BAT\_THEME*.\
 \- The following themes support manpage highlighting:\
\
   \- *Monokai Extended* / Monokai Extended Light\
\
   *- Solarized (dark)* / *Solarized (light)*

## ACKNOWLEDGEMENTS

Thanks to @sharkdp and @LunarLambda for debugging how to make this work properly in certain environments.
