| modified | Monday 4 May 2026 |
|---|
Static site generator for digital gardening written in Go. Serves and edits markdown files with extension system.
cmd/xlog/xlog.go (imports all extensions via extensions/all)extensions/ loaded via blank importsmarkdown/ contains vendored goldmark parser (excluded from linting)xlog.Start(context.Background()) in mainTo add/remove extensions, modify extensions/all/all.go import list.
1# Run tests (standard)
2go test ./...
3
4# Run tests with race detector (CI also runs this)
5go test -race ./...
6
7# Lint (exact CI command)
8golangci-lint run
9
10# Run the server locally
11go run ./cmd/xlog
12
13# Build binary
14go build -o xlog ./cmd/xlog
15
16# Build static site
17go run ./cmd/xlog -build <output-dir>
page_test.go:19-36 for example)t.TempDir() and os.Chdir() patternsetupTestEnv(t) returns cleanup func (see extension tests).golangci.yml excludes markdown/ directory (vendored goldmark)gosec, errcheckgolangci-lint-action@v6 with latest versionmasterghcr.io/emad-elsaid/xlog, serves on port 3000, mounts ~/.xlog:/filesMost extensions add their own flags. Check with go run ./cmd/xlog -h.
Notable core flags:
-bind: server address (default 127.0.0.1:3000)-build <dir>: generate static site-source <dir>: markdown files location (default .)v* triggers multi-platform binary builds (Linux/Windows/Darwin, 386/amd64/arm64)./cmd/xlog