SkillHub

sync

Reconcile installed skills with the resolved subscription set — apply adds, updates, and removes within declared ranges, and verify hashes.

skillhub sync reconciles the skills installed in a scope with the resolved subscription set — the skillsets and registries you're subscribed to. It applies adds, updates, and removes within your declared version ranges and verifies content hashes.

Use --frozen in CI to fail if the lockfile would drift, and --prune to drop skills the subscription set no longer contains.

Synopsis

skillhub sync [--global] [--dry-run] [--frozen] [--prune]

Flags

FlagDescription
--global, -gSync the machine-global scope
--dry-runShow what would change without touching anything
--frozenCI mode: fail (exit 1) if the lockfile would change; never write
--pruneRemove skills the resolved subscription set no longer contains

Examples

skillhub sync
skillhub sync --frozen   # CI: fail if lockfile drifts
skillhub sync --prune

JSON output

With --json, the data object contains:

  • scope, plus the booleans dryRun, frozen, offline, upToDate.
  • added[], updated[], removed[], unchanged[], orphaned[] — each { ref, name, version, previousVersion? }.
  • copyMode[], agents[].
  • gitignore (schema-optional) — { action: extended | unchanged | skipped, reason?: no-managed-block | malformed-block | not-a-git-repo | global-scope | dry-run, added[] }: when a fan-out reaches an agent directory the managed .gitignore block does not yet cover, sync appends it. Purely additive, and refused outright when there is no well-formed block to extend. See install.

On this page