Pular para o conteúdo

Build Commands

The site generator CLI supports many commands for different build scenarios.

Full Builds

build-pages

Generates all static pages including scopes, topics, and city pages. Also copies static assets.

Terminal window
cd site && go run . build-pages

Options:

  • --process-notfound — Process the 404 CSV and generate missing pages
  • --notfound-csv=../Table.csv — Path to the 404 CSV file

build-static

Copies JS/CSS/images only. Fast, no city pages.

Terminal window
cd site && go run . build-static

Single Page Builds

build-page

Build one or more specific pages.

./deploy-single.sh
cd site && go run . build-page home # Home page only
cd site && go run . build-page chat # Chat page only
cd site && go run . build-page single # All single pages (~15)
cd site && go run . build-page scope:energia-solar # One scope only
cd site && go run . build-page topic:iptu # One topic only
cd site && go run . build-page --sitemap home # Home + sitemap

List all available page types:

Terminal window
cd site && go run . build-page --list

404 Resolution

generate-notfound

Generate missing pages from a 404 report CSV.

Terminal window
cd site && go run . generate-notfound --csv=../Table.csv --generate

Sitemap

generate-sitemap

Rebuild the sitemap to include newly generated pages.

Terminal window
cd site && go run . generate-sitemap

Help

The CLI includes a custom help viewer, but it does not list every available command. The following commands exist and work even though they may not appear in help --all:

CommandHow to Verify
build-pagecd site && go run . build-page --list
build-staticcd site && go run . build-static
daily-updatecd site && go run . daily-update --help

If a command is not found by go run . help [command], try running it directly with --help.