feat(skill): worktree provisioning and CLAUDE.md skill injection#391
feat(skill): worktree provisioning and CLAUDE.md skill injection#391nextlevelshit merged 2 commits intomainfrom
Conversation
…ll injection Extract DirectoryStore skill provisioning from executor.go into skill.ProvisionFromStore with hard error semantics for missing skills. Add SkillRef type and ResolvedSkills field to AdapterRunConfig, inject an Available Skills section into the runtime CLAUDE.md assembly between persona prompt and contract compliance. Existing commands_glob provisioning path is unchanged.
Code Review (Wave Pipeline)Verdict: REQUEST_CHANGES This PR is a well-structured refactor that extracts skill provisioning into a dedicated function and adds skill metadata injection into runtime CLAUDE.md. The direction is sound and improves testability, separation of concerns, and error handling. However, there is one bug and one breaking change that should be addressed before merge. Critical Issues (must fix)1.
|
Code Review (Wave Pipeline)Verdict: APPROVE Well-structured extraction of inline skill provisioning into Critical IssuesNone. All findings are defense-in-depth recommendations or code quality improvements — nothing blocks merge. Suggested Improvements1. Document the behavioral breaking change (HIGH — from quality review)
Action: Document this in release notes. Consider whether a migration path is needed. 2. Add
|
…ng skills - NewChildExecutor now copies skillStore so child pipelines get skill provisioning - Missing skills in ProvisionFromStore now log a warning and skip instead of hard error - Fix De Morgan's law lint in claude_test.go
Summary
ProvisionSkills()function ininternal/skill/provision.gothat copies SKILL.md files into step worktrees at.wave/skills/<name>/InjectSkillContent()methodCloses #386
Changes
internal/skill/provision.go(new) —ProvisionSkills()copies resolved skill SKILL.md files into step worktrees, handles deduplication and missing skill errorsinternal/skill/provision_test.go(new) — comprehensive tests for provisioning: happy path, missing skills, deduplication, conflict resolutioninternal/adapter/claude.go—InjectSkillContent()method to append skill SKILL.md content into runtime CLAUDE.mdinternal/adapter/claude_test.go— tests for skill content injection into CLAUDE.mdinternal/adapter/adapter.go— updatedAdapterRunConfigto carry resolved skill metadatainternal/pipeline/executor.go— integrated skill provisioning into step execution flow, removed old inline skill handlinginternal/pipeline/executor_test.go— executor-level tests for skill provisioning integrationspecs/386-skill-worktree-provisioning/— specification, plan, and task artifactsTest Plan
ProvisionSkills()covering: successful provisioning, missing skills, deduplication, scope precedenceInjectSkillContent()verifying CLAUDE.md assembly includes skill contentgo test ./...andgo test -race ./...