From 14b6054946960825092d39811d6d03b22a1a9337 Mon Sep 17 00:00:00 2001 From: Catalin Mititiuc Date: Sat, 24 May 2025 13:18:30 -0700 Subject: [PATCH] Clean up --- Dockerfile | 1 - about.html | 5 ---- command.moon | 69 ---------------------------------------------------- site.moon | 1 + 4 files changed, 1 insertion(+), 75 deletions(-) delete mode 100644 about.html delete mode 100644 command.moon diff --git a/Dockerfile b/Dockerfile index 5e58cd3..008bcbf 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,7 +3,6 @@ FROM openresty/openresty:1.27.1.2-0-bookworm-buildpack WORKDIR /opt/app RUN apt-get update && apt-get install -y python3-pygments pandoc lua-inotify -RUN opm get DevonStrawn/lua-resty-route RUN luarocks install sitegen RUN luarocks install inotify INOTIFY_INCDIR=/usr/include/x86_64-linux-gnu/ diff --git a/about.html b/about.html deleted file mode 100644 index ff407a0..0000000 --- a/about.html +++ /dev/null @@ -1,5 +0,0 @@ -$some[[

$one and then $two

]] - -$if{ true, target = 'World' }[[ Hello $target! ]], [[ Hi $target! ]] - -$each{ { thing = "bye" }, { thing = "hello" } }[[$thing]] diff --git a/command.moon b/command.moon deleted file mode 100644 index 44d6827..0000000 --- a/command.moon +++ /dev/null @@ -1,69 +0,0 @@ --- ========================================================================= --- capture output of a system command --- ========================================================================= --- handle = io.popen "ls" --- result = handle\read("*a") --- print result --- handle\close! - --- ========================================================================= --- how changing the config in the Site class works --- ========================================================================= --- f = class Site, config: { "one" } -- simulate `f = require "sitegen.site"` --- f.config = { "two" } - --- simulate `n = require "sitegen.site"` --- n = f -- because it has already been required, it returns the existing `f` --- n! - --- { v } = n.config --- print v - --- ========================================================================= --- markdown link pseudo-protocols --- ========================================================================= --- [what-is-this](class:asdf) --- --- [reference link][blah] --- --- [blah]: "titlehere" --- --- [App Platform](id:doesthiswork>) --- --- > %class-one% --- > --- > Lorem ipsum... --- --- [postoffice](class:caps "asdf") --- --- [postoffice][caps] --- --- [caps]: class:caps 'ALL UPPER CASE, ALL THE TIME' - --- md = require "sitegen.renderers.markdown" --- require("moon").p md - --- file = "docs/2023-08-03-recursively-list-all-files-in-a-directory-with-elixir.md" --- --- Path = require "sitegen.path" --- result = Path.join("/two", "one") --- --- require("moon").p result - --- some_instance_method = (...) => @@ ... --- --- blah = => @@var1 --- --- class Blah --- @var1: "var1" --- @var2 = "var2" --- var3: "var3" --- var4 = "var4" --- --- meth1: => --- -- @var1 --- blah! --- --- b = Blah! --- -- require("moon").p Blah.meth1! --- require("moon").p b\meth1! diff --git a/site.moon b/site.moon index 371be91..129bbb1 100644 --- a/site.moon +++ b/site.moon @@ -16,6 +16,7 @@ Site.config.out_dir = "html/" -- Configure the command our custom renderer uses to convert markdown to html rend = "renderers.markdown" require(rend).cmd = "pandoc --mathjax >" +-- require(rend).cmd = "pandoc --mathjax -f json >" -- Insert custom renderer in the first position so it will be preferred table.insert Site.default_renderers, 1, rend