Hardscrabble 🍫

By Max Jacobson

See also: the archives and an RSS feed

managing your Instapaper bookmarks from the command line

March 22, 2015

I’ve previously written about extracting a gem from a web app called Layabout, but I neglected to mention that I later open sourced Layabout as well:

Today I have the opportunity to write about it, because I finished a kind of fun new feature: a command line interface for efficiently managing your bookmarks. Using it requires cloning the codebase and requesting API credentials, so it’s not a super accessible tool, but for power users it might be worth it. Here’s a quick demo:

bin/rake explore demo

Here’s the code for the CLI as of this moment: https://github.com/maxjacobson/layabout/blob/255eed15be2e55de804083bfdcf8651538af7bb0/lib/tasks/explore.rake

(I like linking to the code as of a certain commit, because who knows, maybe I’ll rename the file later, and then the link to the file on master branch won’t actually work?)

I think it’s kind of interesting code. Each action is an object that describes its help text, the commands it can handle, and how it can handle them.

Note: I don't have comments or analytics on this website, so it's hard to tell if people are reading or enjoying it. Please feel free to share any feedback or thoughts by shooting me an email or tagging me in a post on Mastodon @maxjacobson@mastodon.online.