-- Leo's gemini proxy

-- Connecting to kwiecien.us:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini

Twtxt Over Gemini

Author: Ben <benk@tilde.team>

Wed Jan 19 04:41:37 PM +0330 2022


Using Antenna


The first time I heard of Twtxt was when ew0k/BW added it to his Antenna aggregator. You can ee the result here:


gemini://warmedal.se/~antenna/twtxt.gmi


Excited by the idea, I went ahead and created a simple feed of my own on my capsule, found here:


gemini://kwiecien.us/twtxt.txt


Adding entries to it required nothing more than a simple Unix command, and even manually authoring replies was easy because you can copy-paste the reference right from the Antenna page.


In order to publish your own feed/posts to Antenna, you simply need some kind of Gemini utility that will allow you to query his Gemini server in order to submit the URI of your feed. As a Diohsc user, I naturally use Diohsc for this, but I admit it is not the most simple or lightweight solution. You might find another utility that suits you better, but the command I use to trigger Antenna is as follows:


`diohsc -g -d ~/.diohsc-static -e "'as?gemini://kwiecien.us/twtxt.txt"`


Now, what the heck is all that? I wrote about this on my gemlog before, but for the sake of this post, the -g option runs Diohsc in "ghost" mode, which causes it not to write anything to the disk. Essentially, it runs in read-only. The -d option tells it to use a custom directory I created for the purpose of such queries. The sole reason for this is that when Diohsc connects to a Gemini server, it saves its TLS certificate in its own directory. If no certificate exists, it auto-accepts it, but if it sees that there is a missmatch, it will ask the user what to do. However, running Diohsc non-interactively will cause the connection simply to fail, as auto-accept isn't an option here. This workaround makes it so the connection is accepted no matter what.


The -e option of course tells Ddiohsc what to execute, and what you see in quotes is telling it to submit what comes after the question mark as a query string to 'as, which is a bookmark that points to:


gemini://warmedal.se/~antenna/submit


I didn't have to use the bookmark... it just makes the command slightly shorter.


Well, that would be all you need to use Twtxt on Gemini, and I do recommend any users out there submit their feeds to Antenna. It serves as a gathering point to foster a budding microblogging community, and it helps me discover new people to followw.


Using Twet


As I mentioned in my last gemcast, I was introduced by jdtron himself to a custom fork of Twet, a Twtxt client written in Go. The client is very simple, straightforward, and easy to use. Jdtrons fork is located here:


https://github.com/jdtron/twet


You have to know how to work Git in order to compile it, but it was easy enough for me. (You just have to be sure to switch to the "gemini" branch after cloning the repo.) Thanks to being written in Go, building it is pretty much foolproof.


Of course, to use Twet you need to write a simple config file. A helpful example is included in the repo, and I also wanted to note that for Antenna compatiility, you can include whatever command or script you use to submit to Antenna in the "post:" (post-processing) field under the "hooks:" section in the config file. I had no problem getting this to work.


Conclusion


I hope that the availability of this software and resources will inspire an initiative to form a Twtxt community specifically on Gemini. I know that it was originally meant to function over HTTP, and that's where the Twtxt community is mainly located, but I find this to be something that would make an excellent addition to the Gemini ecosystem, providing a native alternative on our network to things like the Fediverse, or even centralized microblogging services like Station (which, of course, is not bad).

-- Response ended

-- Page fetched on Fri May 17 05:00:04 2024