From 3956e96e748b1e89b7a717f39a244a6946c82511 Mon Sep 17 00:00:00 2001 From: Attila Gonda Date: Wed, 8 Jul 2020 17:36:55 +0200 Subject: [PATCH] Add clarification about how the indentation works --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index 3dae3d8e..8c5fd05f 100644 --- a/README.md +++ b/README.md @@ -444,6 +444,16 @@ If you want to enable mouse-wheel scrolling on older versions of `less`, you can in the example above, this will disable the quit-if-one-screen feature). For less 530 or newer, it should work out of the box. +### Indentation + +`bat` expands tabs to 4 spaces by itself, not relying on the pager. To change this, simply add the +`--tabs` argument with the number of spaces you want to be displayed. + +**Note**: Defining tab stops for the pager (via the `--pager` argument by `bat`, or via the `LESS` +environment variable for `less`) won't be taken into account because the pager will already get +expanded spaces instead of tabs. This behaviour is added to avoid indentation issues caused by the +sidebar. Calling `bat` with `--tabs=0` will override it and let tabs be consumed by the pager. + ### Dark mode If you make use of the dark mode feature in macOS, you might want to configure `bat` to use a different