rss-git

Github’s gone to shit, let’s use a normal rss feed to cheaply federate git related (social) activity!

Structure

Let’s repurpose the de-facto format of standard RSS feeds for something that can be displayed reasonably in any RSS reader, but which can also be used to build useful tooling around.

Top-level feed information

Entry information

rss-git feeds are recommended to limit the amount of entries to the latest 250, but go nuts if you want to keep it unlimited i guess :)

fork and move are basically identical but have different semantics:

Example

fav

I favourite github.com/cabal-club/cabal-cli, my rss-git feed entry for that would be:

<item>
    <title>fav: cabal-cli</title>
    <link>https://github.com/cabal-club/cabal-cli.git</link>
    <guid>1683377178000</guid>
    <description>(optional project description)</description>
    <pubDate>Fri, 06 May 2023 13:46:18 +0100</pubDate>
</item>

Note: The title starts with the action (fav) followed by the project name, and the link is directly to the git repository.

create

The repository https://github.com/cabal-club/cable-core.js.git is created.

<item>
    <title>create: cable-core.js</title>
    <link>https://github.com/cabal-club/cable-core.js.git</link>
    <guid>1683377178000</guid>
    <description>(optional project description)</description>
    <pubDate>Fri, 06 May 2023 13:46:18 +0100</pubDate>
</item>

fork

The user slatian, over at codeberg, forks the repository at https://github.com/cblgh/lieu.git to https://codeberg.org/slatian/lieu.devel-fork.git

Actions relating to the forked repo should reference the fork by setting the source: <source>https://codeberg.org/slatian/lieu.devel-fork.git</source>

<item>
    <title>fork: lieu</title>
    <link>https://codeberg.org/slatian/lieu.devel-fork.git</link>
    <source>https://github.com/cblgh/lieu.git</source>
    <guid>1683377178000</guid>
    <description>(optional project description)</description>
    <pubDate>Fri, 06 May 2023 13:46:18 +0100</pubDate>
</item>

Note: link contains the url that a repository has been forked to (not the source)

move

The repository https://github.com/slatian/lieu.git is moved to https://codeberg.org/slatian/lieu.devel-fork.git. The github source is now regarded as obsolete.

Future actions relating to the repo should use the new location as the source <source>https://codeberg.org/slatian/lieu.devel-fork.git</source>.

<item>
    <title>move: lieu</title>
    <link>https://codeberg.org/slatian/lieu.devel-fork.git</link>
    <source>https://github.com/slatian/lieu/</source>
    <guid>1683377178000</guid>
    <description>(optional project description)</description>
    <pubDate>Fri, 06 May 2023 13:46:18 +0100</pubDate>
</item>

Note: link contains the url that a repository has been moved to (not the source)

follow

<item>
    <title>follow: cblgh</title>
    <link>https://cblgh.org/rss-git.xml</link>
    <guid>1683377178000</guid>
    <description>(optional description taken verbatim from the followed feed's description)</description>
    <pubDate>Fri, 06 May 2023 13:46:18 +0100</pubDate>
</item>

Note: link contains the url to another git-rss feed!

Atom structure

Since some people prefer atom, and most RSS readers handle both atom & rss, here’s the equivalent fields for atom feeds!

Atom Examples

fav

<entry>
    <title>fav: cabal-cli</title>
    <link>https://github.com/cabal-club/cabal-cli.git</link>
    <id>1683377178000</id>
    <summary>(optional project description)</summary>
    <updated>Fri, 06 May 2023 13:46:18 +0100</updated>
</entry>

Note: The title starts with the action (fav) followed by the project name, and the link is directly to the git repository.

create

<entry>
    <title>create: cable-core.js</title>
    <link>https://github.com/cabal-club/cable-core.js.git</link>
    <id>1683377178000</id>
    <summary>(optional project description)</summary>
    <updated>Fri, 06 May 2023 13:46:18 +0100</updated>
</entry>

fork

<entry>
    <title>fork: lieu</title>
    <link>https://codeberg.org/slatian/lieu.devel-fork.git</link>
    <source>https://github.com/cblgh/lieu.git</source>
    <id>1683377178000</id>
    <summary>(optional project description)</summary>
    <updated>Fri, 06 May 2023 13:46:18 +0100</updated>
</entry>

move

<entry>
    <title>move: lieu</title>
    <link>https://codeberg.org/slatian/lieu.devel-fork.git</link>
    <source>https://github.com/slatian/lieu/</source>
    <id>1683377178000</id>
    <summary>(optional project description)</summary>
    <updated>Fri, 06 May 2023 13:46:18 +0100</updated>
</entry>

follow

<entry>
    <title>follow: cblgh</title>
    <link>https://cblgh.org/rss-git.xml</link>
    <id>1683377178000</id>
    <summary>(optional description taken verbatim from the followed feed's description)</summary>
    <updated>Fri, 06 May 2023 13:46:18 +0100</updated>
</entry>

Usage

The underlying structure can be used in many different ways:

Whatever way you want to create a git activity feed, whether it’s by hand through your static site generator, your own tool or whatever: go for it! :)