Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# The documentation site (mkdocs.yml, built with Zensical from docs/): built on every pull request and push that touches it, so a
# broken link or a page missing from the build fails here (--strict); published to GitHub Pages from main.
# Pages must be switched on for this repository (Settings > Pages > Source: GitHub Actions) before the deploy job can run.
# This repository's GitHub Pages site: only redirects. The documentation is published on the LabConstrictor website, which fetches
# docs/; every address of the old docs site (https://cellmigrationlab.github.io/LabConstrictor-Tools/<PAGE>/) leads to the page's new
# home (scripts/build_redirect_site.py). Built on pull requests that touch it (a docs page without a destination fails the build);
# published from main.
name: docs

on:
push:
branches: [main]
paths: [docs/**, overrides/**, mkdocs.yml, requirements-docs.txt, .github/workflows/docs.yml]
paths: [docs/**, scripts/build_redirect_site.py, .github/workflows/docs.yml]
pull_request:
paths: [docs/**, overrides/**, mkdocs.yml, requirements-docs.txt, .github/workflows/docs.yml]
paths: [docs/**, scripts/build_redirect_site.py, .github/workflows/docs.yml]
workflow_dispatch:

permissions:
Expand All @@ -28,17 +29,14 @@ jobs:
- uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.12"
cache: pip
cache-dependency-path: requirements-docs.txt
- run: pip install -r requirements-docs.txt
- name: Build the site (warnings, e.g. a broken link, fail the build)
run: zensical build --strict --clean
- name: Build the redirect pages (a docs page with no destination fails the build)
run: python scripts/build_redirect_site.py --out site

- name: Upload preview (pull requests)
if: github.event_name == 'pull_request'
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
name: docs-preview
name: redirect-site-preview
path: site/
retention-days: 14
- name: Upload site for GitHub Pages
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ mutants/
.hypothesis/
htmlcov/

# documentation site build output (mkdocs.yml)
# GitHub Pages build output (scripts/build_redirect_site.py)
site/
25 changes: 16 additions & 9 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,21 @@ Notes for people and coding agents who change this repository.

Each topic of the LabConstrictor documentation has one owner page; every other page links to it instead of copying it. The table of owners is in LabConstrictor-Site's `AGENTS.md`, section "Sources of truth" (<https://github.com/CellMigrationLab/LabConstrictor-Site/blob/main/AGENTS.md#sources-of-truth>).

This repository owns these pages. LabConstrictor-Site fetches them and publishes them, so links in them must be absolute:

| Page | On the LabConstrictor website |
|---|---|
| `docs/user-guide.md`, "Use apps inside napari, Fiji and QuPath" | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/image-software/> |
| `docs/CAPABILITIES.md`, "What works where" | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/capabilities/> |
| `docs/PUBLISHING.md`, "Publish the plugins and apps" | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/publishing/> |
| `docs/AUTHORING.md`, "Writing tools" | the "Build an app" track (being added) |
This repository owns these pages. LabConstrictor-Site fetches them and publishes them. Their first heading is the menu title on the site. Relative links are fine: the site resolves them (a link to another published page becomes that page, a link to any other file becomes the file on GitHub).

| Page | Track | On the LabConstrictor website |
|---|---|---|
| `docs/user-guide.md`, "Use apps inside napari, Fiji and QuPath" | Use an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/image-software/> |
| `docs/CAPABILITIES.md`, "What works where" | Use an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/capabilities/> |
| `docs/AUTHORING.md`, "Writing tools" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/writing-tools/> |
| `docs/MANIFEST.md`, "Tool markers" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/tool-markers/> |
| `docs/HOST_FEATURES.md`, "What each host does with each feature" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/host-features/> |
| `docs/INSTALL.md`, "Install LabConstrictor Tools" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/tools-install/> |
| `docs/OPERATIONS.md`, "Operations: shared installs, security, troubleshooting" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/tools-operations/> |
| `docs/PUBLISHING.md`, "Publish the plugins and apps" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/publishing/> |
| `docs/REPOSITORIES.md`, "Where the LabConstrictor tools live" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/repositories/> |
| `docs/LABCONSTRICTOR_INTEGRATION.md`, "How the template registers an app's tools" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/template-registration/> |
| `docs/PROTOCOL.md`, "Protocol reference" | Connect an app | <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/protocol/> |

It also owns the developer topics: the protocol, the manifest, what each host does with each feature, testing, releases and tags, shared and network installs, security, and the install of `labconstrictor-tools` itself.

Expand All @@ -23,4 +30,4 @@ Pages owned elsewhere, which pages here link to and never copy:
- Install and open each plugin (commands, menu paths, current release): `docs/user-guide.md` of LabConstrictor-napari, LabConstrictor-Fiji and LabConstrictor-QuPath, at <https://cellmigrationlab.github.io/LabConstrictor-Site/guides/napari/>, `/guides/fiji/` and `/guides/qupath/`.
- The Tools tag that app installers pin: `LC_TOOLS_PIN` in the template's `app/bash_bat_scripts/post_install.sh` and `post_install.bat`.

This repository's own docs site (<https://cellmigrationlab.github.io/LabConstrictor-Tools/>, built from `mkdocs.yml`) is the developer reference only. Pages for people who use apps live on LabConstrictor-Site.
Every page a user or a tool author needs is on LabConstrictor-Site; maintainers' material (TESTING.md, REGRESSION_LEDGER.md, SPEC_WRONG_SCIENCE.md, CONFORMANCE.md) stays on GitHub. This repository's GitHub Pages site (<https://cellmigrationlab.github.io/LabConstrictor-Tools/>) is only redirects: `scripts/build_redirect_site.py` sends each address of the old docs site to the page's new home (keeping a `#section`). A new page in docs/ needs a line there (its website address, or `NOT_PUBLISHED` for a maintainers' page), or that build fails.
Loading
Loading