The problem here is, that this mechanism includes some script that adds some complexity to the maintenance of the gemini capsule. As bacardi55 writes:
I do know that asking capsule owners to deploy a script will be the biggest concern here, but I guess there is always a "price to pay" … Yes it will require a CGI script, but it should be doable even with a small bash script to not add too much complexity in maintaining a capsule.
I agree that some kind of programming and scripting will be necessary to get notified. However I think that we can do it at least without a CGI-script. Here is the way I think I have found.
And he goes on to implement a scheme that adds complexity to the configuration of the server,
plus the issues with scheduling a program to scan the logfiles for Gemini requests.
I've done the logfile scanning for “Project: Wolowizard” and “Project: Lumbergh” and it was not any easy thing to set up.
in my case,
it was checking the logs in real time to see if messages got logged as part of testing,
but that aside,
checking the logs for requests might not be straightforward.
In this case,
it soulds like he has easy access to the log files—but that is not always the case.
There have been plenty of systems I've come across where normal users just don't have access to the logs
(and I find it annoying,
but that's a rant for another time).
Then there's scheduling a script to run at a regular schedule.
In the past,
this would be
cron and the bizarre syntax it uses,
but I'm not sure what the new hipster Linux
systemd way is these days
(which itself is a whole bag of worms).
And it's not like the CGI script has to be all difficult. Here's a script that should work (it's somewhat untested—I have the concept tested and running on my Gemini server, as an an extension to my Gemini server and the CGI script below is based upon that extension):
#!/usr/bin/env lua query = os.getenv("QUERY_STRING") if query == "" then io.stdout:write("10 URL to send\r\n") else query = query:gsub("%%%x%x", -- decode URL encoded data function(c) return string.char(tonumber(c:sub(2),16)) end) mail = io.popen("/usr/sbin/sendmail me") -- send email if mail then mail:write(string.fomrmat([[ From: <me> (replace with real email address) To: <me> Subject: Mention, sir! %s ]],query) io.stdout:write("20 text/plain\r\nIt has been accepted.\r\n") end os.exit(0)
this relies upon the email recipient to check the URI has the proper link,
but it's simple and to the point.
The only issue here is getting the Gemini server to run this script when
/.well-known/mention is requested,
and I feel that is easier than dealing with scanning logfiles and running
but that's me.
As far as the actual proposal itself, I don't have much to comment about it, except to say I don't like the mandated text it uses in the link. I think just finding the link should be good enough. Even better in my mind would be two links, much like webmention uses, but that doesn't seem to be a popular opinion.