Skip to main content

A conduit for pushing changes in a feed to the rest of the IndieWeb

Project description

Pushl

A simple tool that parses content feeds and sends out appropriate push notifications (WebSub, Webmention, etc.) when they change.

See http://publ.beesbuzz.biz/blog/113-Some-thoughts-on-WebMention for the motivation.

Usage

Setup

First, you'll want to have your Atom (or RSS) feed implement the WebSub protocol. The short version is that you should have a <link rel="hub" href="http://path/to/hub" /> in your feed's top-level element.

There are a number of WebSub hubs available; I use Superfeedr.

For WebMentions, configure your site templates with the various microformats; by default, Pushl will use the following tags as the top-level entry container, in descending order of priority:

  • Anything with a class of h-entry
  • An <article> tag
  • Anything with a class of entry

For more information on how to configure your templates, see the microformats h-entry specification.23

Sending notifications

pip install pushl
pushl -c cache_dir http://example.com/feed.xml

If your feed implements RFC 5005, the -a flag will scan past entries for WebMention as well.

Advanced configuration

TODO: whitelist/blacklist for rel links for outgoing WebMentions

My setup

I use pipenv to keep my Python environments separate.

On my server I created the directory $(HOME)/pushl and in it I ran the command:

pipenv install pushl

and created this script as $(HOME)/pushl/run.sh:

#!/bin/sh

cd $(dirname "$0")
LOG=$(date +%Y%m%d.log)
flock -n .lockfile pipenv run pushl -rvc cache http://beesbuzz.biz/feed http://publ.beesbuzz.biz/feed >> "$LOG" 2>&1

Then I have a cron job:

*/15 * * * * $(HOME)/pushl/run.sh

which runs it every 15 minutes.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Pushl-0.1.1.tar.gz (8.1 kB view hashes)

Uploaded Source

Built Distribution

Pushl-0.1.1-py3-none-any.whl (10.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page