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):

Windows 10/11 (x86_64):


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.sh and netlify.toml into it
  • Connect the repo on Netlify — build command and publish dir are picked up automatically from your netlify.toml file

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.sh fetches a Linux_x86_64 release binary, which matches the default Linux runners on all three platforms above.