sync-main

Sync documentation and infrastructure changes from dev to main without a package release.

1|Updated Aug 24, 2026
One-click install
npx skills add https://github.com/yamcodes/the-hat --skill sync-main-yamcodes
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: sync-main
Source: https://github.com/yamcodes/the-hat/tree/main/skills/sync-main
Command: npx skills add https://github.com/yamcodes/the-hat --skill sync-main-yamcodes

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Documentation fixes merged into the dev branch normally wait for the next npm package release before reaching production. This Skill deploys doc and infrastructure changes to main immediately while keeping the dev and main branches in a clean, compatible git state. ## Core Features & Use Cases - Change Classification: Analyzes the diff between dev and main to categorize the sync as doc-only, infra-only, or code changes, each with its own safe workflow. - Workflow Dispatch: Triggers the sync-main GitHub Actions workflow directly via the gh CLI, including the force_override flag for infra-only changes. - Cherry-Pick Rescue: Extracts isolated doc commits onto main using a helper script, then reconciles main back into dev to prevent branch drift. - Use Case: A typo fix in the docs is merged to dev but the library code on dev is not ready for release. Use this Skill to cherry-pick only the doc commit to main so the production docs update immediately. ## Quick Start Ask the assistant to sync the latest documentation changes from dev to main and deploy them to production now.

Frequently Asked Questions about sync-main

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I deploy documentation changes without releasing the npm package?▼

Run the sync-main workflow to promote doc-only changes from dev directly to main, which deploys production docs immediately. The Skill classifies the diff first and triggers the workflow via gh workflow run sync-main.yml --ref dev.

How to cherry-pick doc commits from dev to main in git?▼

Identify the commit hashes containing the doc changes, then run ./scripts/sync-main.sh rescue with those hashes to cherry-pick them onto a branch from origin/main and open a PR. After merging, run the reconcile command to merge main back into dev.

Why does the sync-main workflow block my changes?▼

The workflow's safety check blocks syncs that touch workflows, scripts, or skills directories even when no package code changed. For these infra-only changes, rerun the workflow with the force_override checkbox enabled or pass -f force_override=true via the gh CLI.

What happens if doc fixes are mixed with unreleased code in one commit?▼

Tangled commits cannot be cherry-picked safely. The recommended approach is to manually recreate the doc fix directly against the main branch using code editing tools, leaving the unreleased package code on dev.

When should I wait for a release instead of syncing docs to main?▼

Wait for the natural release cycle when the doc fix is not urgent and dev already contains unreleased package code. This avoids cherry-picking overhead and keeps the branch topology simple.