@phthalo
43M

I think the easiest and quickest way to generate an atom feed is by using a simple tool like gemfeed. It’s convenient to include in scripts :)

no Hugo needed

here is my guide also on RPI gemini://gemini.bbbhltz.space/gemlog/2021-02-10-howto-agate-on-pi.gmi

Adding an Atom feed with Gemfeed ⭐

There are a few prequisites for this to work:

python3-pip
feedgen
python3-urllib3

Here are the commands you will need to run on your Pi:

$ sudo apt-get install python3-pip python3-urllib3 $ pip install feedgen

Go to where you want to put the gemfeed file, like ~/bin and wget it:

$ wget https://tildegit.org/solderpunk/gemfeed/raw/branch/master/gemfeed.py $ chmod +x gemfeed.py

Now you get to run that sucker!

$ ./gemfeed.py -b YOURDOMAIN/gemlog -d /home/pi/gemini/gemlog/ -a YOURNAME -t ‘A TITLE FOR YOUR GEMLOG’

It should spit out an atom.xml file:

Generating feed “YOURTITLE”, which should be served from gemini://YOURDOMAIN/gemlog/atom.xml

That’s all! Make note of that address. Whenever you add a new post, run the command and presto!

You can add that link to GUS or CAPCOM if you want.

To generate RSS/Atom feeds you need some kind of static site generator. hugo has really good gemini support.

Comments can be achieved in many ways:

  • if you have a website for your capsule, webmention and other indieweb tech can federate replies from other websites (i don’t know of an equivalent gemini-based tech)
  • ActivityPub is an other web-based protocol for that kind of stuff
  • maybe you have a mailbox a bot can poll for replies to be integrated into your gemlog?
  • maybe you can pull tickets/issues from one or more software forges (Github, Gitea…) where the source of your blog is hosted?

In any case don’t forget to sanitize user input so you don’t end up serving 3rd party images (those can be replaced on the go with a local copy on your server), scripts and whatnot.

Happy hacking

https://gemini.circumlunar.space/

Gemini is a new internet protocol which:

Is heavier than gopher
Is lighter than the web
Will not replace either
Strives for maximum power to weight ratio
Takes user privacy very seriously
  • 0 users online
  • 6 users / day
  • 6 users / week
  • 13 users / month
  • 47 users / 6 months
  • 154 subscribers
  • 68 Posts
  • 101 Comments
  • Modlog