💾 Archived View for stack.tilde.cafe › gemlog › 2022-05-10.lagrange.gmi captured on 2023-09-28 at 16:17:33. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2023-09-08)
-=-=-=-=-=-=-
Imagine stringing together, with a couple of lines of script, a Lagrange renderer, a marginalia search, and an offpunk page-grabber...
As sprock points out, here:
gemini://sprock.dev/posts/the-unix-philosophy.gmi
I think it is kind to say that Lagrange does one thing: browse the alternative protocols of the Internet. But in reality there are a few things it does well! What does it do?
At the bottom, it implements a few different protocols, methods to access various kinds of sites: gopher, gemini, spartan, finger. As an end user, I am happy that it does that pretty transparently - I don't have to 'turn on gopher mode' or anything like that, I can follow links and read.
Above that, it renders the data that comes in, in a pleasing way. I prefer reading Hacker News using LaGrange here, for instance:
I does so across multiple platforms, and even it text mode which I have yet to try.
Finally, it manages the bookmarks, certificates, settings of all sorts, not to mention menus, windows, tabs and UI whatnots, uploads.
That is actually quite a few things.
Other than very simple text utilities, there are few examples of Unix philosophy that stand the test of usability. Once you have some kind of an interface that is not just invoking some batch process from a command line, the said philosophy becomes more of an idea than reality.
There are so many parts of a reasonably-sized application that are just easier to program yourself instead of interfacing with some underspecified service or library. Rolling your own built-in database for bookmarks is less tricky to write (and for the user to configure) than some generic database interface. For a user-facing application, any bugs in any sub-component or library are seen as your own!
Maybe it is possible, if done very, very carefully:
If done right, this would be a truly fantastic infrastructure for the end-user. A non-techie user sees a browser, not very different from something like Lagrange. But a power user would get something like Emacs - an ecosystem for creating anything they want using their favorite scripting language (Lisp for me; whatever works for you).
The scripting I am talking about is all local - God knows we don't want randos to execute arbitrary code on our machines. I am talking about customizing the GUI, hacking your own organizer integrated with multiple services, a device for keeping up with people's gemlogs or tinylogs, chat or bulletin-board-like applications, personal search engines/agents, and texty games like no one has seen before...
All it takes is breaking up the monolith into manageable components. None of them are complicated tech. Stringing them back together with the scripting interface is a proof that it works, and a vote of confidence for all would-be scripters (as opposed to an afterthought of an API).
A C interface, please - you can rig anything else on top of that, for any language. Minimum dependencies in the components themselves to avoid library rot and pythonic disasters. Keep personal preferences out of the core - let the user decide how to use it.
Why hasn't this been done? A few reasons. Some are purely capitalist - lock in the customers then monetize them (a browser does so indirectly, allowing third parties to do the exploitation). Others are technical - given what HTML/CSS/Javascript/whatever has become, it is not possible to separate the parts.
But in our case, we actually can. Rendering Gemtext is a pretty contained task. A single server hit brings a Spartan page. URLs still look like URLs (unless the freaky CGI-in-the-middle-of-path idea takes hold), and a bookmarking application/service is still possible.
Now, imagine stringing together, with a couple of lines of script (or a single command), a Lagrange renderer, a marginalia search, and an offpunk page-grabber.
You may say I am a dreamer. And perhaps the only one. But _that_ sounds like Unix philosophy to me.