Prime the docs for GitHub Pages serving

The gh-pages deploy workflow already exists (build on PR + main,
deploy on main push via `actions/deploy-pages`); wire up the sphinx
side,

- `sphinx.ext.githubpages`: emits a `.nojekyll` so Pages serves the
  `_static/` + `_images/` dirs (Jekyll otherwise drops `_`-prefixed
  paths, breaking every asset),
- `html_baseurl`: the canonical site root
  (`https://goodboy.github.io/tractor/`) for the `<link
  rel="canonical">` + `og:url` tags.

The one remaining (one-time, manual) step is the repo setting:
Settings -> Pages -> Source = "GitHub Actions".

(this patch was generated in some part by [`claude-code`][claude-code-gh])
[claude-code-gh]: https://github.com/anthropics/claude-code
docs_vibed_for_serious
Gud Boi 2026-06-27 20:26:19 -04:00
parent 46197f00c3
commit d688eaba84
1 changed files with 7 additions and 0 deletions

View File

@ -41,6 +41,10 @@ extensions = [
'sphinx.ext.intersphinx', 'sphinx.ext.intersphinx',
'sphinx.ext.viewcode', 'sphinx.ext.viewcode',
'sphinx.ext.todo', 'sphinx.ext.todo',
# emit a `.nojekyll` so GitHub Pages serves the `_static/`
# + `_images/` dirs (Jekyll would otherwise drop `_`-prefixed
# paths and break all styling/assets).
'sphinx.ext.githubpages',
'sphinx_design', 'sphinx_design',
'sphinx_copybutton', 'sphinx_copybutton',
'sphinxext.opengraph', 'sphinxext.opengraph',
@ -93,6 +97,9 @@ intersphinx_mapping = {
html_theme = 'pydata_sphinx_theme' html_theme = 'pydata_sphinx_theme'
html_title = 'tractor' html_title = 'tractor'
# canonical site root (GitHub Pages); drives <link rel=canonical>,
# og:url + any future sitemap. Update if a custom domain is added.
html_baseurl = 'https://goodboy.github.io/tractor/'
html_logo = '_static/tractor_logo_side.svg' html_logo = '_static/tractor_logo_side.svg'
html_favicon = '_static/tractor_logo_side.svg' html_favicon = '_static/tractor_logo_side.svg'
html_static_path = ['_static'] html_static_path = ['_static']