This document is a WORK IN PROGRESS.
This is just a quick personal cheat sheet: treat its contents with caution!
bat¶
A cat clone with syntax highlighting and Git integration.
Reference(s)
Table of contents¶
Install¶
Config¶
$ vi $HOME/.bashrc # or ${ZDOTDIR:-${HOME}}/.zshrc or wherever
> ...
+ >
+ > # cat/bat
+ > #
+ > # prerequisite:
+ > # * bat: https://repology.org/project/bat/versions
+ > #
+ > export BAT_THEME="ansi" # change bat theme
+ > #export MANPAGER="sh -c 'col -bx | bat -l man -p'" # colorize pager for man, DEPRECATED
+ > alias cat="bat"
+ > alias fh="find . -exec bat {} +" # "find here" with bat preview
+ > alias fr="find / -exec bat {} +" # "find root" with bat preview
$ source $HOME/.bashrc # or ${ZDOTDIR:-${HOME}}/.zshrc or wherever
TODO: * https://github.com/eth-p/bat-extras/blob/master/doc/batgrep.md * https://github.com/eth-p/bat-extras/blob/master/doc/batman.md * https://github.com/eth-p/bat-extras/blob/master/doc/prettybat.md
Use¶
If this cheat sheet has been useful to you, then please consider leaving a star here.