=> Re: "I have a Gemini capsule as well as a gopherhole that run on..." | In: s/Gemini
For converting absolute links to other servers to gopher format, you will have to do it differently depending on the scheme (due to historical reasons). If it is "gopher" then it must be parsed and converted to a gopher menu item. If it is "telnet" then it should be converted to a type "8" menu item. Otherwise, use a type "h" menu item, put your own host/port, and the selector string is "URL:" followed by the URL. If your server receives such a request, it should return a HTML file containing a link and/or redirect to the target URL (but clients that understand this convention will not need to request the HTML file from your server, so it is OK if the client doesn't implement HTML).
=> ๐ฆ zzo38
10 hours ago
=> ๐ clseibold ยท 3 hours ago:
This may not be exactly relevant for your question, but I'll talk about trying to proxy a gemini server to gopher. I've tried dealing with converting gemtext documents to gophermaps in SIS when proxying gemini to gopher, and it's actually pretty awful for a couple of reasons:
So here's what SIS does when it converts/proxies gemtext documents to gophermaps:
First, if the resource ends in a "/", it's going to get converted into a gophermap by the proxy, so all links that end in "/" will be itemtype 1.
Second, look at the extension at the end of the URL, and convert the extension to its proper gopher itemtype. If no extension is provided, then you have to assume it's a text document because there's no other way of knowing without making a request to that resource on the server.
Lastly, if it's a link to a static file on your own server (that you are proxying), then look at the file (or route) to get the filetype.
If you add in zzo38's method above as well, then you'll get very close to having something that works at least 75% of the time, lol.
If people know of other better tricks for this, I'd definitely be happy to hear them.
I have a Gemini capsule as well as a gopherhole that run on separate servers, and I don't use a proxy. I like to keep the content on both the same, which is fairly easy to do for the most part as converting from gemtext to plaintext is very simple. The issue I have is with the gophermaps. In the past I have taken the links on my Gemini index pages and manually typed out the Gopher versions into gophermaps, but this is incredibly tedious to do. Is there some way to more easily and simply convert...
=> ๐ฌ Arkholt ยท 5 comments ยท 19 hours ago This content has been proxied by September (ba2dc).Proxy Information
text/gemini; charset=utf-8