This Post is Written in Lisp
¶ I launch my IDE (well, actually, it's Emacs with SLY), open up a Lisp file, start up the console (we call it REPL here) side-by-side with the code, and start programming. I pick tab completions, add more procedures, and iterate over the data. Occasionally, some syntax error pops at me—some stray comma or misspelled keyword. It compiles, memory consumption, and code complexity is bearable. A neat piece, I'd say.
¶ Okay, that's a good blog post! Let's publish it. Maybe program some project afterward: I've got some time left before sunset.
¶ So yes, this post (and other posts on this blog) are written in Lisp. Most of it is regular Lisp syntax:
- and sometimes strings.
¶ Having these, I get a fancy blog post generated from raw s-expressions, needing just a couple of syntax quirks to resolve. Here's how it works:
- I load Spinneret (a library using Lisp macros to construct HTML) into the running Lisp image.
- Then comes my boilerplate macros collection:
- To generate all the tags, favicons, and styles.
- To create linkable sections.
- To generate linkable plaintext paragraphs from raw Lisp code (you've seen these pilcrow signs after the previous paragraph.)
- To shorten the overly verbose list and table markup (including this list you're reading.)
- To generate anchor tags from the shortest possible links and text.
- Load Lisp files with these macros in them and save the generated HTML.
- If something doesn't compile (usually due to unescaped comma or colon)—fix and reload.
- Push the files to the repository where CI will deploy them to the website.
¶ So here I am, bored before my IDE and uncertain about what to do next because my blog posts are already done compiling and deploying. Maybe write some more?
¶ Update December 2023: I switched to C preprocessor for website generation.