Artifact f19630509e536b24e89ad26e84fb4ab33ee3723daf96e2c300779fa8e8228b2f:
- File
wrangler.jsonc
— part of check-in
[ab1e500bc4]
at
2026-04-26 15:20:11
on branch trunk
— feat(landing): inject version from latest git tag at build time (#13)
Replace the three hardcoded "0.4.2" strings in the landing layout with {{ .Site.Params.version }} template directives. Add scripts/sync-version.sh that reads the latest git tag via 'git describe --tags --abbrev=0' and rewrites hugo.yaml's params.version line. Wire it into wrangler.jsonc's build command so Cloudflare's git-integrated build picks up new tags automatically — push a commit to main with a fresh tag, CF rebuilds, the landing shows the new version with no PR required to bump strings.
Footer year switched to {{ now.Year }} so 2027 doesn't surprise anyone.
Local fallback: when no tags are reachable (very early dev), the script exits cleanly and the layout's 'default' filter falls back to the value already in hugo.yaml. (user: [email protected], size: 524) [annotate] [blame] [check-ins using]
{ "$schema": "node_modules/wrangler/config-schema.json", "name": "libfossil-docs", "compatibility_date": "2026-04-25", "observability": { "enabled": true }, "assets": { "directory": "./docs/site/public" }, "build": { "command": "curl -sSL https://github.com/gohugoio/hugo/releases/download/v0.160.0/hugo_extended_0.160.0_linux-amd64.tar.gz | tar xz hugo && bash scripts/sync-version.sh && bash scripts/gen-llms-txt.sh && cd docs/site && ../../hugo --minify" }, "compatibility_flags": ["nodejs_compat"] }