Has anyone generated an RSS feed from TiddlyWiki?

OK I found the time to have a quick go at trying to extract the RSS bits and resolving non-core dependencies, hopefully I got everything: feeds.json

The main tiddler is $:/plugins/sq/feeds/templates/rss, there are config tiddlers for customizing the title, what tiddlers to include etc. I think everything is configurable now as opposed to the hardcoded first incarnation. I don’t recall how far I got in the refactoring process last time around that I worked on this, so I recommend validating the output to make sure all the fields are there and correctly formatted.

For a single file wiki at the path my-wiki.html:

tiddlywiki.js --load my-wiki.html --render "[[$:/plugins/sq/feeds/templates/rss]]" "feed.xml" "text/plain" "$:/core/templates/wikified-tiddler"

For node.js folder wiki at the path mywiki/:

tiddlywiki.js mywiki/ --render "[[$:/plugins/sq/feeds/templates/rss]]" "feed.xml" "text/plain" "$:/core/templates/wikified-tiddler"

Hope this helps. If you run into errors, or find things that need correcting, let me know.

Thanks! Will run through it and document!

Here is a fun little extra (very minimally tested):

Using the excerpts from the Feeds plugin that I shared, you can also save an RSS feed along with your wiki using the Fission or Github uploader with the FileUploads plugin.

Example RSS feed saved with Fission uploader.

In order to get this working, you need a custom save wiki button to save the RSS feed along with the wiki (assumes auto save is turned off) and a custom filter for the FileUploads plugin as seen here: Saq's wiki — a non-linear personal web notebook

This is the sort of thing that hopefully will eventually become a core capability with the intended savers and syncers work as discussed on the community call.

3 Likes

Awesome. I’ll test this on my TW Groceries, too.

I’m currently messing about with filters and documenting my walk through of set up.

e.g. The default filter at $:/config/feeds/filter is basically everything that isn’t a system tiddler:

[!is[system]limit{$:/config/feeds/maxItems}]

For me, this is my filter of non system tiddlers tagged with Notes or Journal in reverse chronological order:

[!is[system] [tag[Notes]] [tag[Journal]] +[limit[25]] +[!sort[created]]

I have this filter pulled out into a tiddler for experimenting, the limit is at $:/config/feeds/maxItems

As always, I’m basically a TW filter noob, so don’t look too closely at my filters :stuck_out_tongue:

1 Like

I believe it has been done. I can’t recall the name of the individual who made this but I believe Tobias Beer picked up on it and you can see one use of it in his (incredible) tb5 site - note the RSS symbol next to the wiki subtitle.

Googling “TiddlyWiki RSS” might give a few clues…

Assume that I searched and found nothing :wink:

Thanks for pointing out the RSS link on Tobias’ site.

Saq’s template above works well, I’m just documenting and implementing it for my use case and will share a walk through once done.

There is also the option to use the commits messages (if applicable) as a RSS feed, now that tiddlywiki allows to wikify the commit.

For github hosted wiki, the feed url looks like this :

https://github.com/Telumire/TiddlyTweaks/commits/main.atom

The downside is that we cant put links or images inside, only plain text (AFAIK) :confused:

Here it is:

https://tiddlywiki.narkive.com/7Imfd94p/tw-tw5-generating-an-atom-feed-for-a-static-site

Atom feed by “dullroar” / Jim Lehmer

1 Like

Uploading an RSS feed with the FileUploads plugin involves three steps:

  1. Generating an RSS feed from the template and saving it in a tiddler with an appropriate title: e.g rss.xml
  2. Having the FileUploads filter configured to upload that tiddler.
  3. Having a separate button to generate the RSS feed in step 1, triggering its upload, or a custom save button that saves the wiki and generates the RSS feed.

Now with the latest version of the FileUploads plugin you can avoid customizing the filter in step 2 and just use the same button that generates the RSS feed to also upload it directly using the tm-upload-tiddlers message, example:

<$action-sendmessage $message="tm-upload-tiddlers" $param="rss.xml"/>

On the off chance that you haven’t seen this already, there is a ‘howto’ of sorts on techlifeweb dot com (have to do this as I’m only allowed one link in a post, apparently :-)). I’ve written up the way I’ve done it based on the information from there on my site, including the relevant links to the pages on techlifeweb.

https://radar231.com/RSS%2520Feed%2520for%2520Tiddlywiki%2520SSG%2520Website.html

@saqimtiaz This plugin is so great, thank you so much !

@boris I’ve managed to make a RSS feed generator using the file upload plugin thanks to the very useful tips from this thread, here it is :

RSS.tid (4.3 KB)

No commands needed :slight_smile:
Enjoy !

PS : You dont need the base64 plugin from tobibeer with the github uploader, it’s only needed for the PUT uploader (it wouldnt upload text file otherwise).

EDIT: @rmorrow wow this is much cleaner than what I’ve come up with :o

That is a bug, you shouldn’t need anything extra. I’ll push an update when I get the chance to test properly.

Thank you! The “discoverfeed” is an excellent add on so that various tools can auto find feeds in the header.

A post was merged into an existing topic: File Uploads plugin: updates

I’ve read your article, this was very informative, thanks you !
There is another way to make a feed reachable for feed reader : simply add a tag $:/tags/RawMarkup

With this the content of the tiddler is embeded in the head of the document and become reachable :slight_smile:

Here’s a demo

@saqimtiaz in a similar application I used the filter that you would use to generate the items for the RSS feed, as the conditions for displaying a button to do the upload (in my case to print a PDF).

However if RSS entries are related to a date, the act of triggering the upload can also record the “last” upload. Subsequently the button can test if fresh content is available for upload. Basically a version of the “dirty” indicator.

Alternatively clicking save button on a “post” could trigger an action to test if an RSS file upload is required.

I hope someone can publish a “Finished” solution addressing this thread;

Generate an RSS feed from TiddlyWiki?

Great example of collaboration in this thread.

This bug has now been fixed and an update for the FileUploads plugin (and the PUT uploader) is available.

1 Like

Awesome, thanks ! :smiley:

I’ve found another plugin to generate RSS feeds :
https://sycom.gitlab.io/TiddlyWiki-Plugins/#Atom%20feed%20plugin

1 Like

Linked from that is GitHub - dullroar/TW5-atomfeed: TiddlyWiki5 plugin to generate ATOM feed.