# How this site is built

One hand-written HTML file, one pinned Zola binary, and a build script that refuses to leak.

Published: 2026-08-26
Canonical: https://sanchay.sh/blog/how-this-site-is-built/


The homepage of this site is a single hand-written HTML file. No framework, inline
CSS, a few dozen lines of vanilla JS. I wanted to keep it that way and still have a
place to write, so the blog is built by [Zola](https://www.getzola.org/), a static
site generator that ships as one binary.

## The rules

- The deploy output is a closed allowlist. If the build produces a file the script
  does not expect, the deploy fails.
- The homepage never passes through a build tool. The build script copies it into
  the output directory after Zola runs, byte for byte.
- Syntax highlighting happens at build time.

## The build

The whole pipeline is a short shell script:

```bash
rm -rf dist
zola --root site build --output-dir "$PWD/dist"
cp index.html 404.html dist/
cp -R assets dist/assets
```

Posts are markdown files with TOML front matter. A post is a draft until the
`draft = true` line is deleted, and drafts never reach production builds. The feed
lives at [/blog/atom.xml](/blog/atom.xml).
