Huzaifa Rasheed

Huzaifa Rasheed

Software Engineer

Email at [email protected]


Blogs

Aggregating RSS Feeds Locally with a Simple Bash Script

July 9, 2024

Quick backstory:
Many great RSS readers exist - even open source ones. But I needed something different: a lightweight, cross-platform (Unix) script that pulls content from my RSS subscriptions and turns it into a simple markdown reading checklist, synced locally with my notes.

Instead of searching endlessly, I wrote one.

But why make another tool?

I have my reasons

  • Unix tools > apps: Bash outlives every “better” reader.
  • Owning my inputs: My notes app is my brain. Feeds should flow there.
  • SaaS fatigue: RSS readers change/decay. Markdown files don’t.

Yeah I went with Bash - Here’s Why

I initially started in Python, but quickly pivoted. Bash has two advantages here:

  • No special dependencies - I wanted it to work on my Windows and Mac machines
  • Works out of the box in almost all Unix-like systems - including headless servers

It also runs clean on macOS, Linux, WSL, and Git Bash with no extra setup. That made it a better fit for this portable, no-frills script.

What does it do?

The script pulls feed content into a local file on each run, logging its work, and producing a checklist of reading items in markdown.

It uses only standard tools: xmllint, curl, date, grep - already included on most systems.

It works well even in remote cron jobs on home servers, and the output integrates seamlessly into any notes system.

One catch: the date command behaves slightly differently across Linux vs BSD/macOS. I had to handle that to ensure portable behavior.

How to use it?

  1. Create a rss_subscriptions.csv file with feeds like this:

RSS Subscriptions CSV format

1. `date_subscribed` uses ISO 8601 
2. You can add any number of feed entries
  1. Make the script executable:

    chmod +x ./rss_watchdog.sh
  2. Run it manually or via cron:

    ./rss_watchdog.sh

The output lives in:

  • ./reading-list.md: Markdown checklist of recent articles
  • ./rss_watchdog.log: Script log

You can change both output paths in the script.

What it doesn’t do

There’s no feed categorization like typical RSS apps. That was a conscious choice - I just didn’t need it.

But if you do? You could modify the CSV to include categories and generate multiple checklists accordingly. It’s a flexible base.


This script is called rss-watchdog.

It’s simple, portable, and helpful - maybe for you too. If you try it, let me know how it goes.