bat
bat copied to clipboard
How do I display the filename in the footer
What I want is the behavior from less -M
, but when I set export BAT_PAGER="less -RFM"
in my .bashrc, bat somehow ignores the filename. This would be super handy if you compare many files in different windows, that you can see the filename for every file in the footer.
Unfortunately, less
isn't aware of the file that bat
is reading. It would be possible to manually add the file name to the less
prompt, though:
less -M -PM'some_file\.txt %lt-%lb' some_file.txt
Just checking in that this is still not possible, because I would love it too. For long files, it is a pain to have to move back up to the header to see the filename. Ideally would be a shortcut like =
in less
which toggles the desired data to be displayed in the footer.