A Gemini capsule directory zipped up would make an excellent eBook format. .ePub is just zipped up xHtml and is an absolute nightmare to parse.

Follow

well, it looks like I'm actually going to make this: oppen.digital/memex/gempub/

@oppen Oh, looks cool.

I just wish .gmi had italics since I use them so often.

@oppen Will be very happy to contribute to this in any way I can.

Maybe I will write a little reader in C for the cli once you get things fully formalized.

@oppen I'm working on ZIP archive support in Lagrange, so I gave this a try. 😊

My UI could use some navigation assistance (next/prev chapter) but it works pretty nicely as-is.

My experimental .gpubs:
gemini://skyjake.fi/lagrange_u
gemini://skyjake.fi/media/skyj

@oppen Quick and shoddy. :)

Is it a valid use case to zip up a static capsule (like my "skyjake's_capsule.gpub") and expect it to work?

Lagrange's ZIP archive viewer automatically looks for index.gmi in any directory, and relative URLs are resolved like on normal Gemini pages. That seems to be all that's needed to make it work.

Also, would be nice to allow any type of file to be included inside the .gpub? Client can always handle unknown formats via external apps.

@jk yeah, that sounds like a sane fallback. I'll add a note.

@jk what I'll do is add an optional value that specifies the start index.gmi, in the absence of that implementations would use the first index.gmi they come across. Will also lose the capsule/ dir requirement, it was cute, but unnecessary.

@oppen 👍 Yeah capsule/ can go...

It might be wise to avoid undefined behavior by requiring that if there isn't an /index.gmi, then the metadata must say which file to use as the index page.

@oppen fine
You should have distinct keyword for language and charset

language: en or en-UK
charset: iso-8859-1 or UTF-8

@adele I'll get that in, optional with UTF-8 default I think.

@oppen , yes default to UTF-8 is a good idea.

About I've written, I don't know if en-UK is really a language, it's a locale. Maybe an "en" is enough ??
Thinking about virtual gpub libraries, a standardized language code is very well. You should specify to use an ISO 639-1 code for language

@adele yes, that's in already: 639-1 or 639-2 as they can coexist nicely

@oppen oh, sorry, I'm stupid... when I saw ISO-639 in your specs, I thought it was a charset (many start with iso-...)
That's why I asked you to separate language and charset 😢 I hate me when I do this kind of things

@oppen I like the idea... mostly because existing gemini clients don't keep track of scroll position in their bookmarks. Funny to see this pop up before any submissions to booksin.space.

Also, does "gpubVersion: 1.0.0" open the door too much to future extensibility? (Maybe inline notes using .patch files?)

Sign in to participate in the conversation
Merveilles

Merveilles is a community project aimed at the establishment of new ways of speaking, seeing and organizing information — A culture that seeks augmentation through the arts of engineering and design. A warm welcome to any like-minded people who feel these ideals resonate with them.