💾 Archived View for voidcruiser.nl › log › 2021-02-05.gmi captured on 2024-05-26 at 14:50:57. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2024-03-21)
-=-=-=-=-=-=-
For a first post I thought it would be neat to talk a little bit about the semi-automatic listing of new log entries.
As I am an idiot when it comes to automating things, I have no idea how I should do this properly. But as a posix shell novice, I thought it would be a neat challenge to write a little script that goes through the directory where I keep these files.
Also, its seven lines total.
First thing it does it print the title of the gemlog list.
Then it goes through the gemlog directory, listing out each file using find and adding the necessary characters in front of them to make gemini interpret them as URLs.
Then it reads out the first line of each file, removes the hash symbol and adds it after the fine name and path with a little dash in order to make the title show on the list of gemlog entries.
All I have to do now is run the script and redirect its output to the log.gmi file.
All in all, I am sure it could be done a lot more efficiently, but I am quite happy with how it turned out.