OK, I think I finally have a good version of my #gopher server which serves a wiki as a gopher site and allows people to edit pages. Of course no gopher client currently supports that, but this page now shows how to achieve that using nc, for example.
@aeonofdiscord It reads until the stream closes (I think: the library docs just talk about a "chunk"). The reason I'm not looking for the dot as a terminator is because I want to upload images as well and didn't want to have two item types, one for text files and one for binary files.
@kensanata @JTE if the protocol included control signals/metadata (so you didn't have to rely on closing the port to indicate the end of a binary file), then I'd say keeping the connection open might be worth it. It seems like the typical use case is to 'explore' a single server for a while; eliminating the slight delay every time the user reconnects might make menu browsing a bit nicer
@aeonofdiscord what, who, hey, cat's awake. I have no particular say over what goes into gopher protocols though? I should read up on what's in the protocol and see if there's any client/server "supported feature list" header type thingies to see if it can be reasonably added without breaking backwards compatibility with three decades of gopher clients though. That's where cat would start, anyway. Maybe it does exist!
@JTE oh shit sorry I was trying to reply to a thread and clicked on your (adjacent) toot by accident; I thought I'd corrected it but somehow still tagged you anyway?
(also, yeah, unfortunately it's a little out of scope for the protocol as it stands; in theory it'd be possible to add it but backwards compatibility is a fuck)
@aeonofdiscord Yeah. Unless you wanted to add a new item type for binary files that included a length number before sending the bytes. But I guess I'd still be fine with connections closing after binaries.
That final dot is still weird. And the need to dot-quote all other single dots because of it is also annoying.
And more, gopher clients like lynx will actually show you that final dot. What for?