-
Notifications
You must be signed in to change notification settings - Fork 1
Build Workflow
How to rebuild and publish the whole site, for whoever is operating this project end to end. For one language's translation workflow, see Translator Workflow instead. For any individual script's exact command syntax and flags, see Script Reference. This page is about the order scripts run in and how they compose, not their full option list.
./pull_upstream_docs.shUpstream is the source of truth for the English end-user docs, not a
locally-maintained copy: this syncs content/en/chapters/ and
content/en/images/ from the official
phpbb/documentation repo,
overwriting local changes. Only en is affected; every other
language's content/<lang>/ is generated from PO catalogs instead (see
Translator Workflow), not synced from upstream directly.
Run this before step 2 so the build reflects current upstream content.
proteus_doc_<lang>.xml's <bookinfo> is hand-maintained separately,
not synced by this script.
./phpbbdocs_hugo.sh allTransforms every proteus_doc_<lang>.xml into Hugo Markdown, copies
images, then runs hugo. This is the step that actually invokes
hugo; none of the other scripts below do.
One line covers every language here, unlike step 3 below, because
content/<lang>/chapters/*.xml (this step's source) is a committed,
tracked file: a git pull already brings it up to date for whatever's
translated so far, so there's nothing to regenerate per language first.
site/content/<lang>/development/ (step 3's target) is the opposite:
entirely gitignored, never committed, so it exists only once
devdocs-build actually runs for that language.
./translations.sh devdocs-build en site/content/en/development
./translations.sh devdocs-build da site/content/da/development
./translations.sh devdocs-build fr site/content/fr/development
./translations.sh devdocs-build de_x_sie site/content/de_x_sie/development
./translations.sh devdocs-build de site/content/de/development
./translations.sh devdocs-build it site/content/it/developmentReconstructs translated dev-docs Markdown for one language at a time,
directly into the site content tree. Each devdocs-build assumes
that language's PO catalogs already exist and are up to date: run
./translations.sh devdocs-check <lang> first if unsure. Doesn't run
hugo itself; follow with step 2 again to fold the result into a real
build.
./fill_translation_fallbacks.sh en da fr de_x_sie de itFor every page one language has that another doesn't, copies the
source page over verbatim, flagged fallback: true, so the language
switcher still links to something rather than nothing. Run this
last, after whichever of steps 2–3 you just ran. It only fills gaps in
whatever's already on disk.
Full site, all languages, from scratch:
./pull_upstream_docs.sh # syncs content/en/ from upstream
./phpbbdocs_hugo.sh all
./translations.sh devdocs-build en site/content/en/development
./translations.sh devdocs-build da site/content/da/development
./translations.sh devdocs-build fr site/content/fr/development
./translations.sh devdocs-build de_x_sie site/content/de_x_sie/development
./translations.sh devdocs-build de site/content/de/development
./translations.sh devdocs-build it site/content/it/development
./fill_translation_fallbacks.sh en da fr de_x_sie de it
./phpbbdocs_hugo.sh all # rebuild once more so the fallback/dev-docs pages are in the built siteJust want the latest end-user docs content?
./pull_upstream_docs.sh && ./phpbbdocs_hugo.sh allThe sync pulls current upstream chapters/images into content/en/,
then the build picks them up. Follow with
./fill_translation_fallbacks.sh en da fr de_x_sie de it && ./phpbbdocs_hugo.sh all
if the sync introduced pages a translation doesn't have yet.
Just want the latest developer docs?
./translations.sh devdocs-build en site/content/en/development(and the same per other language you want refreshed) followed by
./phpbbdocs_hugo.sh all to fold it into a real build. A fresh English
upstream pull doesn't automatically update translated catalogs; that's
./translations.sh devdocs-update <lang>, a separate step.
That's a translator task, not a rebuild task: see
Translator Workflow for the full walkthrough
(both content families, from init/devdocs-init through to a
committed PR).