-- Leo's gemini proxy

-- Connecting to gemini.bunburya.eu:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini

Comment by DarkChyper on 29/04/2023 at 08:38 UTC

1 upvotes, 1 direct replies (showing 1)

View submission: A simple Git-based blogging platform and SSG that lets you dual-host on Gemini and the Web


That's funny that most of people who create a gemlog create a script that make both Gemini capsules and static html page. I do the same with php, https://gitlab.com/DarkChyper/gemblog[1] ant it's directly inspired of another blog/gemlog made with Python. gemini://ploum.net


1: https://gitlab.com/DarkChyper/gemblog


I'm curious how you did it in bash ! I will read your repository :)



Replies


Comment by SnooDingos2835 at 29/04/2023 at 13:43 UTC

1 upvotes, 0 direct replies


It was actually quite trivial to create a Gemtext parser in Bash. At it's core the script is just a loop that iterates over every line in a gmi file and matches the first few characters to find Gemtext elements. From there it inserts equivalent HTML tags into a corresponding HTML file.


Most of the magic happens in the CSS. Without that, the generated site would look and feel very plain.


-- Response ended

-- Page fetched on Fri May 17 11:43:17 2024