Skip to content

ci: migrate docs-sync to reusable workflow in dojoengine/book#2572

Merged
tarrencev merged 1 commit intomainfrom
ci/docs-sync-reusable
Apr 24, 2026
Merged

ci: migrate docs-sync to reusable workflow in dojoengine/book#2572
tarrencev merged 1 commit intomainfrom
ci/docs-sync-reusable

Conversation

@kronosapiens
Copy link
Copy Markdown
Contributor

Replaces the in-tree docs-sync workflow with a minimal stub that invokes the shared reusable workflow hosted in dojoengine/book.

Why

The docs-sync logic has been duplicated across 10+ source repos (dojo, katana, torii, torii-core, saya, dojo.js, dojo.c, dojo.unity, dojo.unreal, dojo.bevy, and this one). Any improvement to prompt rules, diff handling, or PR creation had to be applied in 11 places. This migration consolidates the pipeline into a single reusable workflow (dojoengine/book/.github/workflows/docs-sync.yml) and leaves each caller with a ~30-line stub.

Cross-org reuse works

dojoengine/book is public, so cartridge-gg/controller can invoke uses: dojoengine/book/.github/workflows/docs-sync.yml@main with no access-setting changes. Controller keeps its own CREATE_PR_TOKEN and ANTHROPIC_API_KEY; they're forwarded to the reusable workflow via secrets: inherit.

What changed

  • .github/workflows/docs-sync.yml shrinks from ~180 lines to ~20.
  • All pipeline logic (diff computation, DOCS_PATTERNS filter, claude-code-action invocation, docs-PR branch/commit/auto-merge) moves to the reusable workflow. Behavior is unchanged.
  • Per-repo variation passed via with::
    • target-docs-repo: cartridge-gg/docs
    • source-repo-slug: cartridge-gg/controller
    • diff-globs, docs-patterns, canonical-desc, docs-structure-desc

Merge order

Requires dojoengine/book#504 to land first — that PR adds the reusable workflow this stub references. Merging this before that means the uses: ref won't resolve at trigger time.

Related

Companion stubs across the dojoengine ecosystem:

Replaces the in-tree docs-sync workflow with a minimal stub that invokes the shared reusable workflow hosted at dojoengine/book/.github/workflows/docs-sync.yml@main. Cross-org reuse works because dojoengine/book is public; controller forwards its own CREATE_PR_TOKEN and ANTHROPIC_API_KEY via 'secrets: inherit'.

All prompt rules and pipeline steps are now shared across dojoengine and cartridge-gg source repos. Per-repo variation (diff globs, DOCS_PATTERNS, canonical docs path, target docs repo) is passed as workflow inputs.
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 24, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
controller-example-next Ready Ready Preview Apr 24, 2026 1:33pm
keychain Ready Ready Preview Apr 24, 2026 1:33pm
keychain-storybook Ready Ready Preview Apr 24, 2026 1:33pm

Request Review

Comment thread .github/workflows/docs-sync.yml Dismissed
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.

3 participants