Skip to content

Latest commit

 

History

History
36 lines (30 loc) · 1.2 KB

fd-bat-quick-document-review.md

File metadata and controls

36 lines (30 loc) · 1.2 KB
title date tags
fd + xargs + bat = quick document review
2024-02-25
xargs
fd
bat
cli
automation
shell
selkouutiset-archive

output

I've been on vacation this week, and part of what I've been up to is fixing up the Selkouutiset Archive. Like most of my websites these days, SA is powered by Hugo, which means handling a lot of Markdown documents, which means I opted to use an intermediate Git repo as a submodule to actually store the custom-processed documents.

After a few tweaks here and there, I found myself wanting to quickly flip through all of the Markdown documents I had generated for each news day. I wasn't exactly sure what I was looking for, just that I would know it when I saw it. So:

fd '.fi.md$' | xargs -I _ -- batcat --paging=always _

In the associated GIF, I don't find anything, but several times earlier this week it helped me find .md files where my html2md pipeline broke in some subtle way. Neat!