3 ms·
Bat: A cat(1) clone with wings
- Sir_Cmpwn 8y agoNo no no, just open your text editor. vipe[1] will soak up a pipe, open your editor, and write the final file to stdout. Something like bat is the opposite of Unix. [1] https://joeyh.name/code/moreutils/ https://joeyh.name/code/moreutils/ If this was just "pipe text into me and I'll print it out with syntax highlighted ANSI codes" then I'd be all for it. As a cat replacement this is nonsense.
- splatzone 8y agoI could see this being really handy for viewing source files on remote servers (I prefer to use Sublime normally) What do you mean when you say this the opposite of unix, and why is it a bad thing?
- spiffistan 8y agoSee: https://en.wikipedia.org/wiki/Unix_philosophy https://en.wikipedia.org/wiki/Unix_philosophy
- splatzone 8y agoThanks, I am aware of the unix philosophy but I’m not sure how bat contravenes it; it seems like you can use it non-interactively and use its output with other programs, and it performs one task (outputting files with syntax highlighting). Am I missing something?
- mdekkers 8y agoNo? Looks neat and very useful to me.
- empath75 8y agoI like bat because it works fine for what cat is supposed to be used for but it’s better than cat for what most people use it for.
- bb88 8y agoI tend to use vi or less for that, because of the handy searching/scrolling commands. Having used cat for 30 years, I only use cat for scripting typically. If bat was described as an advanced syntax diff tool, I'd probably be more interested in it. But "cat with wings" seems pointless, because cat does everything I need it to.
- dagenix 8y agoIts great to see modern takes on classic UNIX tools, such as this, ripgrep, and others. I'm very curious to see if anyone ever gets around to writing a new twist of `dd`.
- sevensor 8y agoI was hoping this was written in Python as a reference to the travel agent sketch. "A cat?" "No, a bat."
- aequitas 8y ago> bat can pipe its own output to less if the output is too large for one screen. Please don't do this by default. Systemd commands have this habit as well. I understand it is for usability. But it makes viewing output unpredictable as now I might end up in the pager (or not, you can't tell beforehand unless you know the content, which you are going to look at) that I have to exit before typing the next command.