Skip to content

Auto-generate nav & branch preview docs#84

Merged
ssestak merged 4 commits intomainfrom
feature/auto-generate-nav
Feb 23, 2026
Merged

Auto-generate nav & branch preview docs#84
ssestak merged 4 commits intomainfrom
feature/auto-generate-nav

Conversation

@ssestak
Copy link
Contributor

@ssestak ssestak commented Feb 20, 2026

Summary

Auto-generate the mkdocs nav section from workflow/action metadata instead of maintaining it by hand, and enable per-branch preview deploys that are automatically cleaned up when the branch is deleted.

Changes

  • Add nav_generator.py that builds the nav tree from the config registry, with title derivation, acronym handling, and duplicate disambiguation
  • Integrate nav generation into generate-docs.py so the nav section in mkdocs.yml stays in sync with registered workflows/actions
  • Add nav_title override support in config.py for entries that need custom sidebar names
  • Deploy docs workflow now creates a Mike version named after the branch (slashes sanitized to dashes) on workflow_dispatch
  • New cleanup-preview job removes the branch preview from gh-pages on branch deletion
  • Concurrency group is now per-ref so branch deploys don't cancel main deploys

Diagram

View diagram
flowchart TD
    A[Event Trigger] --> B{Event type?}
    B -->|push / workflow_dispatch| C[deploy job]
    B -->|delete| D[cleanup-preview job]

    C --> E{Ref type?}
    E -->|tag| F["mike deploy v1.0 + alias latest"]
    E -->|branch| G["mike deploy branch-name\n(slashes to dashes)"]

    D --> H{branch != main?}
    H -->|yes| I["mike delete branch-name"]
    H -->|no| J[skip]
Loading

Šimon Šesták and others added 4 commits February 20, 2026 15:20
Add nav_generator.py that builds the mkdocs nav section automatically
from the workflow and action configs, keeping entries sorted
alphabetically and using nav_title overrides where needed.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Deploy docs to a per-branch Mike version on workflow_dispatch, and
automatically remove the preview when the branch is deleted.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace slashes with dashes in branch names since Mike does not accept
slashes in version identifiers (e.g. feature/foo becomes feature-foo).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copy link
Member

@jmarek41 jmarek41 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏

@ssestak ssestak merged commit c09950c into main Feb 23, 2026
2 checks passed
@ssestak ssestak deleted the feature/auto-generate-nav branch February 23, 2026 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants