summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEthan P <32112321+eth-p@users.noreply.github.com>2020-11-21 10:13:28 -0800
committerGitHub <noreply@github.com>2020-11-21 10:13:28 -0800
commit6d75540d4e95c57ba89d5810d271bc687761763e (patch)
tree46725fe2fd01fadeca1d9c0d34a2df22fcd4693d
parent2b82203041e0a4242659b95a4fa2ae6454497637 (diff)
parentba5cbe208ff7d9397950be42e9f11f2051d57966 (diff)
Merge pull request #1389 from nstickney/master
explain how to use bat as cat (no paging) (closes #1383)
-rw-r--r--README.md12
1 files changed, 6 insertions, 6 deletions
diff --git a/README.md b/README.md
index f04e6a1c..8a51a8e8 100644
--- a/README.md
+++ b/README.md
@@ -38,14 +38,14 @@ characters:
### Automatic paging
-`bat` can pipe its own output to a pager (e.g `less`) if the output is too large for one screen.
+By default, `bat` pipes its own output to a pager (e.g `less`) if the output is too large for one screen.
+If you would rather `bat` work like `cat` all the time (never page output), you can set `--paging=never` as an option, either on the command line or in your configuration file.
+If you intend to alias `cat` to `bat` in your shell configuration, you can use `alias cat='bat --paging=never'` to preserve the default behavior.
-### File concatenation
+#### File concatenation
-Oh.. you can also use it to concatenate files :wink:. Whenever
-`bat` detects a non-interactive terminal (i.e. when you pipe into another process
-or into a file), `bat` will act as a drop-in replacement for `cat` and
-fall back to printing the plain file contents.
+Even with a pager set, you can still use `bat` to concatenate files :wink:.
+Whenever `bat` detects a non-interactive terminal (i.e. when you pipe into another process or into a file), `bat` will act as a drop-in replacement for `cat` and fall back to printing the plain file contents, regardless of the `--pager` option's value.
## How to use