Improve repo structure, CI pipeline, and contributor experience#5
Improve repo structure, CI pipeline, and contributor experience#5
Conversation
Consolidate duplicated parsing logic into a shared module, add structural validation, harden the CI pipeline for PRs, and align all documentation with actual tooling behavior. - Extract shared parser into scripts/lib/parse-skill.js (eliminates 5x duplication) - Add scripts/validate-skills.js for frontmatter, sections, deps, and cycle detection - Add skills/skill.schema.json and skills/_template/SKILL.md.template - Add .claude/CLAUDE.md with contributor instructions - Add PR validation and version bump enforcement to CI pipeline - Auto-generate ai-plugin.json alongside agent.json - Move sitemap.xml to build-time dist/ generation (deterministic git dates) - Add requires and tags fields to all 12 skill frontmatter blocks - Remove redundant > version: body lines (frontmatter as single source of truth) - Add Setup section and generate step to CONTRIBUTING.md - Update README with Programmatic Access section and accurate usage instructions
Move pages:write and id-token:write from workflow-level to the deploy job only so PR runs cannot trigger deployments. Patch-bump all 12 skill versions to satisfy the new CI version-check gate.
- _checks.yml: reusable workflow with validation, freshness, and version bump checks - ci.yml: PR-only trigger, calls _checks.yml (shows as "PR / checks / validate") - deploy.yml: push-to-main only, calls _checks.yml then builds and deploys
|
Follow-up: Reconsider There's overlap between the Since skills are primarily consumed by agents (who parse frontmatter), we should consider:
This would require updating the template, validator ( Would love to hear thoughts from anyone who has opinions on this. Please comment if you have ideas on how the |
Merge upstream changes (ic-cdk 0.19 migration, audit fixes). Resolve conflicts by keeping frontmatter as source of truth (no body version lines) and updating requires fields to ic-cdk >= 0.19. Regenerate llms-full.txt. Remove sitemap.xml (moved to build-time generation).
Update template, schema, README, and https-outcalls prerequisite to reflect the current ic-cdk version.
JoshDFN
left a comment
There was a problem hiding this comment.
Looks good — pushed a fix commit bumping ic-cdk references from 0.18 to 0.19 in the template, schema, README, and https-outcalls.
JoshDFN
left a comment
There was a problem hiding this comment.
Looks good — pushed a fix commit bumping ic-cdk references from 0.18 to 0.19 in the template, schema, README, and https-outcalls.
- Rename H1 to match skill name (Wallet Integration) - Rename "Mistakes That Break Your Build" to "Pitfalls" - Fix pitfall #5: clarify that requestPermissionsNotGranted() is a UX optimization, not a requirement (verified against library source) - Make IcpWallet/IcrcWallet code blocks self-contained (add connect + accounts so agents get copy-paste correct code) - Add error class imports to import map (RelyingPartyResponseError, RelyingPartyDisconnectedError) - Remove "Build Your Project" section (generic TS commands) - Replace "Verify It Works" with condensed "Expected Behavior" section focused on return types and behavioral facts not stated elsewhere
Summary
scripts/lib/parse-skill.js(single source of truth)scripts/validate-skills.jschecking frontmatter fields, required sections, dependency graph integrity, circular dependency detection, and code block annotations. Runs in CI and locally vianpm run validate_checks.yml(reusable validation, freshness, version bump checks),ci.yml(PR-only, shows as "PR / checks / validate"), anddeploy.yml(push-to-main only, builds and deploys to GitHub Pages). Deploy permissions (pages: write,id-token: write) scoped exclusively to the deploy jobrequiresandtagsfields to all 12 skills; remove redundant> version:body lines (frontmatter as single source of truth); patch-bump all skill versionspublic/to build-timedist/generation using git commit dates (no morenew Date()drift).claude/CLAUDE.mdfor AI agent contributorsskills/skill.schema.jsonandskills/_template/SKILL.md.templatefor consistent new skill creation