Quick Start
Published on 2024-04-28
Installation
Download a prebuilt binary for your platform from the latest release:
MacOS
brew install anna-ssg/anna/anna
GNU/Linux (tar.gz):
- Linux (x86_64): anna_Linux_x86_64.tar.gz
tar -xzf anna_Linux_x86_64.tar.gz./anna
Windows 10/11 (x86_64):
- Download anna_Windows_x86_64.zip
- Unzip
anna_Windows_*.zip- Run
anna.exefrom the extracted folder in a terminal
Bootstrap (create a site/ directory)
If you don't already have a site/ directory, Anna can initialize one for you with a default layout.
# will ask to download the default site layout when config is missing
./anna
Usage
Basic render
Render the site found at site/ (default):
anna
Specify a path:
anna -p ./site
Serve with live reload
anna -s
Version and debug
Show the version (includes embedded commit when present):
anna -v
Show usage and all flags:
anna -h
Deploy Your Site
Anna ships as a single static binary, so most hosts deploy it the same way: fetch the anna release binary, run it to generate site/rendered, then publish that folder. No Go toolchain needed on the host's end.
Netlify
- Push a repo containing your
site/directory - Copy
deploy.shandnetlify.tomlinto it - Connect the repo on Netlify — build command and publish dir are picked up automatically from your
netlify.tomlfile
Cloudflare Pages
- Connect your repo on Cloudflare Pages
- Build command:
bash deploy.sh - Build output directory:
site/rendered
GitHub Pages
- Settings → Pages → Source: GitHub Actions
- Look at the Build and Deploy workflow from our Actions tab
deploy.shfetches aLinux_x86_64release binary, which matches the default Linux runners on all three platforms above.
