

Discover more from hrbrmstr's Daily Drop
We're back at the CLI, today, with two resources riffing from Monday's Drop, and one that shows the power of opens source development.
TL;DR
This is an AI-generated summary of today's Drop. (See Drop #327 — if I link to it, Substack will put a giant preview in here and nobody wants that if this is your first TL;DR.)
Mastering curl: The blog post discusses a 3.5-hour workshop, Mastering the curl command line, by curl's creator Daniel Stenberg, and a shorter, interactive, text version with live examples created by Anton Zhiyanov on his codeapi playground.
repgrep: Callum Oz's repgrep is an interactive command-line tool that extends ripgrep, making find and replace tasks easy with a basic interface to see replacements in real-time and conditionally replace matches.
rsstail: The post introduces rsstail, a minimalist CLI tool that monitors an RSS feed and emits output only when new entries are detected, providing a command-line alternative to RSS GUI readers.
Mastering curl
On Monday, we took a look at a recent update to Wget2 — a modern successor to the venerable wget
utility. As noted in the post, Wget2 is very focused, unlike it's 800 lb (ca. 363 kg) gorilla cousin, curl
, which supports a bonkers list of protocols, ranging from HTTP, FTP and TELNET to IMAP, LDAP and GOPHER. Curl runs on 90+ operating systems and has 20+ billion installations across the galaxy
I suspect many readers — including me — largely use the very basics of curl
, and often in a cut/paste, or scripted scenario. It can do much more than that.
Daniel Stenberg, curl's progenitor, has a 3.5-hour workshop Mastering the curl command line available. It will turn you into quite the expert on curl if you can make it all the way through (3.5 hours is a precious amount of time to dedicate to something).
Anton Zhiyanov recently worked through the tutorial, and created a shorter, interactive, text version. Said version has live examples you can run and see the output of via his own codeapi playground, which you can also grab a copy of and self-host, play with, and extend.
This text version is a bit more compressed/thin than Daniel's 210-minute Marvel-superhero movie length creation, but it will only take a few minutes to work through, and you will almost certainly learn one new thing.
Anton closes out the post with am homage to the 418
🫖 (curl http://httpbin/status/418
).
While you're on the site, check out his guide on “Writing an interactive API”.
repgrep
Open-source projects can be fun, informative, massively useful, full of drama, or lone solo endeavours. Without them, we would not have most of the tech we rely on and enjoy using today.
A foundational aspect of open-source projects is the ability to take a creation and extend it, to either add functionality or just bend it to your will.
Callum Oz did all three things to ripgrep, the defacto replacement to the grep
tool. Despite 2023 being the year of “no assumptions” in the Drop, I am 100% going to make the assumption that (a) everyone knows what grep
is, and (b) y'all use ripgrep
. Drop me a note if that's a bad assumption.
Their repgrep utility is an interactive command line tool to make find and replacement easy. It uses ripgrep
to find bits, and then provides us with a basic interface to see the replacements in real-time and conditionally replace matches. This makes your terminal feel a bit more like a full-on text editor, except across the filesystem where you did searches.
I use Sublime Text to perform similar actions across a project, but repgrep
makes super quick work of that task right at the CLI. Much like ripgrep
is usually installed and accessible as rg
, repgrep
also has a shorthand CLI name of rgr
, so it gains the advantage of your muscle memory and finger positioning.
This nascent tool is 100% going in the “default” install lists/scripts, and the examples in the GH repo are solid enough to warrant shunting you there vs. attempting to re-create here.
rsstail
In Monday's edition, we tapped into a very new, minimalist, cross-platform RSS GUI “reader” (Collie).
Today, we poke a bit at the minimalist polar opposite of it with rsstail, a CLI tool that monitors an RSS-feed, emitting output only when new entries are detected (think of it as the RSS version of tail -F
).
Linux folks can do the apt
dance to get it. However, macOS folk should likely use the modified Homebrew formula I made, given that the one in Homebrew-proper is marked as disabled because it has an incorrect upstream git repo in its config:
$ wget2 https://rud.is/dl/rsstail.rb
$ # EDIT IT TO MAKE SURE I'M NOT PWNING YOU
$ brew install --build-from-source ./rsstail.rb
$ # The `./` prefix in the filename is SUPER important
I asked Perplexity to help macOS folk out with the commented “step 2”, above. It is far from perfect or comprehensive, but it should be a fair enough guide that anyone can follow to keep safe from random homebrew links on the internet.
Here's an example rsstail
in action, doing a one-off look at the last three posts of the Drop:
$ rsstail -Hldpa1u https://dailyfinds.hrbrmstr.dev/feed -n 3
Title: Drop #328 (2023-09-05): Typography Tuesday
Link: https://dailyfinds.hrbrmstr.dev/p/drop-328-2023-09-05-typography-tuesday
Description: If You're 👀 This It's Day 100; Bad 🍎; The 👁️ing Game
Pub.date: Tue, 05 Sep 2023 13:11:08 GMT
Title: Drop #327 (2023-09-04): Back In The Saddle
Link: https://dailyfinds.hrbrmstr.dev/p/drop-327-2023-09-04-back-in-the-saddle
Description: Wget2 2.1; gitwatch; Collie
Pub.date: Mon, 04 Sep 2023 13:11:13 GMT
Title: Bonus Drop #23 (2023-08-27): [Observable] Plot Twisting
Link: https://dailyfinds.hrbrmstr.dev/p/bonus-drop-23-2023-08-27-observable
Description: A look behind the OJS Plot curtain
Pub.date: Sun, 27 Aug 2023 12:13:14 GMT
I kind of think this would be super-fun to re-create this in Go/Rust/your fav language.
The author notes that there's an rsstail
plugin for multitail, a utility that lets you view one or multiple files like the original tail
program. The difference being that it creates multiple “windows” on your console (with ncurses
).
This looks to be super-handy for doing one-off checks of RSS feeds, and may be of use in Git/GitHub actions.
FIN
This is a neat, short post on Maslow’s Subscription Pyramid, which succinctly and cleverly describes the “subscription Hades” most of us are in, right now. ☮
more than a few spacecraft, satellites, and rovers run some form of linux and I gotta believe curl's running on something that's on Mars
Drop #329 (2023-09-056): Seek And Ye Shall Find
Here is a level 5 of the pyramid