بنقرة واحدة
anchor
Create and manage anchor specs — cross-cutting constraints with optional external references
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Create and manage anchor specs — cross-cutting constraints with optional external references
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
Evaluate proof quality — STRONG/WEAK/HOLLOW assessments
Reverse-engineer 3-section specs from existing code
Scaffold or edit feature specs in 3-section format
Initialize a project for Purlin
Inject spec rules into context, then implement
Run all tests, issue verification receipts
| name | anchor |
| description | Create and manage anchor specs — cross-cutting constraints with optional external references |
Create, sync, and manage anchor specs. Anchors define cross-cutting constraints that other features reference via > Requires:.
See references/formats/anchor_format.md for the full format.
purlin:anchor create <name> # Create a local anchor
purlin:anchor create <name> --source <url> # Create with external reference
purlin:anchor add-figma <figma-url> # Create from Figma design
purlin:anchor sync <name> # Pull latest from external source
purlin:anchor sync --check-only # CI: exit non-zero if any anchor is stale
Create a new anchor spec in specs/_anchors/.
purlin:spec).references/formats/anchor_format.md.--source <url> is provided, add > Source: and > Pinned: metadata and read the external content to inform the rules.After creating the anchor, commit immediately:
git add specs/_anchors/<name>.md
git commit -m "anchor(<name>): create cross-cutting constraint"
Do not batch with other changes. Drift detection and staleness checks depend on committed anchor state.
Create an anchor from a Figma design URL. Read references/figma_extraction_criteria.md for the full extraction criteria.
get_metadata MCP tool to get the file info.get_design_context MCP tool to read the design.get_screenshot MCP tool to capture the visual reference.specs/_anchors/screenshots/.> Source: pointing to the Figma URL> Visual-Reference: figma://<fileKey>/<nodeId>> Pinned: set to the file's lastModified timestamp> Type: design@e2ereferences/commit_conventions.md.Do NOT extract granular CSS/typography/spacing rules. The LLM reads Figma directly during build for full visual fidelity.
Compare > Pinned: value to the upstream source. Pull if different.
> Source: to get repo URL and > Path: to get file path.> Pinned: to get the current SHA.git ls-remote <repo> HEAD.> Pinned: with the new SHA.
c. If the anchor has local rules (rules not from the original sync), flag: "External reference changed. This anchor has N local rules — review for conflicts via purlin:drift."
d. Commit per references/commit_conventions.md: anchor(<name>): sync from upstream (<new-sha>[:7])> Source: to get the Figma URL.> Pinned: to get the current timestamp.get_metadata MCP tool with the Figma file key to get lastModified.get_design_context to fetch the current design data.
b. Update the anchor file with refreshed visual data.
c. Update > Pinned: with the new timestamp.
d. If > Visual-Reference: exists, call get_screenshot to recapture the reference screenshot.
e. If local rules exist, flag for drift review.
f. Commit.If any fetch command fails (auth error, network timeout, repo not found, Figma MCP error):
> Pinned: or the anchor content.purlin:anchor sync <name>."If the fetched content is empty or unparseable:
For CI pipelines without Claude Code:
> Source:, compare > Pinned: to the remote HEAD.CI scripting example (without Claude Code):
# Check if anchor's external ref is stale
PINNED=$(grep '> Pinned:' specs/_anchors/api_contract.md | awk '{print $3}')
REMOTE=$(git ls-remote git@github.com:acme/api-spec.git HEAD | cut -f1)
if [ "$PINNED" != "$REMOTE" ]; then echo "Anchor stale"; exit 1; fi