Bat v0.26.0

by indentiton 10/20/2025, 6:49 AMwith 74 comments

by oneeyedpigeonon 10/20/2025, 9:13 AM

The `--pager=builtin` change is interesting; first time I've heard of minus.

> Traditional pagers like more or less weren't made for integrating into other applications. They were meant to be standalone binaries that are executed directly by users. However most applications don't adhere to this and exploit these pagers' functionality by calling them as external programs and passing the data through the standard input.

Do people widely agree with this? That sounds less like 'exploitation' to me and more like 'the way Unix works'.

> This method worked for Unix and other Unix-like OSs like Linux and MacOS because they already came with any of these pagers installed. But it wasn't this easy on Windows; it required shipping the pager binary along with the applications. Since these programs were originally designed for Unix and Unix-like OSs, distributing these binaries meant shipping an entire environment like MinGW or Cygwin so that these can run properly on Windows.

So, to support Windows, we have to:

- Abandon (maybe bypass) the core Unix principle of composing programs to carry out more complex tasks - Reimplement a pager library in every language

Is that really the best approach? Even if so, I would have thought a minimal pager would be best, but the feature list of this pager library is fairly extensive: https://github.com/AMythicDev/minus?tab=readme-ov-file#featu...

by hoistbypetardon 10/20/2025, 7:14 AM

When I saw this, I was hoping that [The Bat!](https://www.ritlabs.com/en/products/thebat/) had been released as FOSS. This is still pretty cool.

by sundarurfriendon 10/20/2025, 9:16 AM

bat is one of the few "new wave" tools that I install without hesitation, with no worries about stability issues or silent downsides. It has great defaults that make it feel like it always does the right thing for the context, just an unambiguous enhancement to my terminal experience.

by bargainbinon 10/20/2025, 9:11 AM

One of the first programs I install in any new setup. Just having the line numbers in your snippets, when all your communication is over asynchronous platforms with UX features designed by the Greatest Minds at Microsoft, streamlines discussions do much.

by foofoo12on 10/20/2025, 12:35 PM

The guy's brilliant. Check out his other projects too: https://github.com/sharkdp?tab=repositories

by Moosturmon 10/20/2025, 8:29 AM

I love "bat". It just give readability in the terminal a boost.

by kI3ROon 10/21/2025, 3:48 AM

The builtin pager doesn't have an END shortcut...

it's useless without such a small thing.

edit: [n] G Go to the very bottom of the output. If n is present, goes to that line

Oh capital G. What an intuitive keyword source:https://docs.rs/minus/latest/minus/#standard-actions

by ctippetton 10/20/2025, 4:53 PM

Has anyone had any luck compiling bat for WebAssembly? I tried recently to get a version I could run on a-Shell[1] on iOS, but ran into issues with some of its dependencies.

[1]: https://github.com/holzschu/a-shell

by pkilgoreon 10/20/2025, 2:22 PM

bat is part of my extended posix "Must Installs", nicely extensible, glad to see it get love.

by jansanon 10/20/2025, 7:19 AM

What is it? It says it is a cat clone, but what is cat?

by lprovenon 10/20/2025, 12:00 PM

TIL: Bat != .bat != The Bat.

https://en.wikipedia.org/wiki/Batch_file

https://www.ritlabs.com/en/products/thebat/

Expanded...

I have 2 mental definitions of "bat" as a term in computing. Only one can be interpreted as a standalone piece of software that has a version number. And this isn't it.