From forge-core
Provenance tracking and sync for inherited rules, skills, and agents. USE WHEN drift, sync, publish prompts, inheritance, upstream, propagate, adapt rules, check provenance.
npx claudepluginhub n4m3z/forge-coreThis skill uses the workspace's default tool permissions.
Track inheritance of rules, skills, and agents between forge modules and downstream company repos. Detects which files came from upstream, what's been adapted, and what upstream changes are available.
Guides Next.js Cache Components and Partial Prerendering (PPR): 'use cache' directives, cacheLife(), cacheTag(), revalidateTag() for caching, invalidation, static/dynamic optimization. Auto-activates on cacheComponents: true.
Processes PDFs: extracts text/tables/images, merges/splits/rotates pages, adds watermarks, creates/fills forms, encrypts/decrypts, OCRs scans. Activates on PDF mentions or output requests.
Share bugs, ideas, or general feedback.
Track inheritance of rules, skills, and agents between forge modules and downstream company repos. Detects which files came from upstream, what's been adapted, and what upstream changes are available.
publish-prompts.sh is a read-only drift reporter. It scans installed content against upstream module sources and reports provenance state. Manifests are written by the forge install command during make install.
bash Modules/forge-core/skills/PublishPrompts/publish-prompts.sh --type all --modules-dir Modules
For downstream repos (e.g., proton-agents):
bash skills/PublishPrompts/publish-prompts.sh --type all --modules-dir /path/to/forge/Modules
| Keyword | Subskill | What it does |
|---|---|---|
| "drift", "check", "status" | Drift | Scan and report provenance state |
| "sync", "update", "propagate" | Sync | Pull upstream changes into adapted files |
| "adopt", "add" | Adopt | Start tracking a new upstream file |
| "promote", "push upstream" | Promote | Push a local improvement back to forge |
| "setup", "initialize" | Setup | Scaffold a downstream repo for inheritance |
Run the companion script to show the current state of all inherited content.
publish-prompts.sh --type all and present the table to the user.Propagate upstream changes to files tracked in the manifest.
publish-prompts.sh --type all to get current state.To compute the 3-way diff, use the manifest SHA to identify what the file looked like when it was adopted. If the upstream module is a git repo, you can retrieve the ancestor content:
# Find the commit where the upstream file had the adopted SHA
git -C Modules/forge-core log --all --format=%H -- rules/SelfLearning.md | while read commit; do
sha=$(git -C Modules/forge-core show "$commit:rules/SelfLearning.md" | awk 'BEGIN{fm=0}/^---$/{fm++;next}fm>=2{print}' | shasum -a 256 | cut -d' ' -f1)
if [ "${sha:0:8}" = "a3f047b9" ]; then
echo "Ancestor commit: $commit"
git -C Modules/forge-core show "$commit:rules/SelfLearning.md"
break
fi
done
Add a new upstream file to local tracking.
rules/, skills/, or agents/ directory.paths: scoping), make the edits.make install to regenerate the manifest with the new entry.Push a local improvement back upstream to a forge module.
make install to update the manifest.Initialize a downstream repo for inheritance tracking.
make install to generate manifests for all tracked content.All three artifact types (rules, skills, agents) use a unified SHA map format. The .manifest file is written by install binaries during make install and grouped by source module:
forge-core:
GitConventions.md: 8f4ca9a50b03d3043a53d0007965a5dcf182bb236cea5f27...
KeepChangelog.md: 1de3b2a8c0681396c7bd76be217f688958f44cf4a186c52c...
forge-council:
AgentTeams.md: e1ae3ab285bc4d502508989d26ab41922e603908c78b61b9...
For rules and agents, the SHA is the body hash of the upstream source file (frontmatter stripped). For skills, it's the body hash of SKILL.md. State is computed at scan time:
forge install, not by the companion script