fix: support marketing-based project layout in skills and runs#24
Open
canovars wants to merge 2 commits intorenatoasse:masterfrom
Open
fix: support marketing-based project layout in skills and runs#24canovars wants to merge 2 commits intorenatoasse:masterfrom
canovars wants to merge 2 commits intorenatoasse:masterfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #23
What
The CLI currently assumes that installed skills and squads always live at the project root:
skills/squads/That breaks repositories that organize work by department and use:
marketing/skills/marketing/squads/There is also a separate bug in
runs: any directory underoutput/is treated as a run, so folders likeoutput/images/andoutput/slides/appear as false run entries.This PR updates:
src/skills.jsPrefer
marketing/skills/for new installs when a project uses the department-based layout, but continue to read, update, and remove skills from bothmarketing/skills/and legacyskills/during migration.src/runs.jsPrefer
marketing/squads/, keep legacysquads/run history visible during migration, de-duplicate identical run ids across both layouts, and ignore non-run output directories.src/init.jsandsrc/update.jsPrint the actual installed skill path instead of always logging
skills/....src/readme/README.mdDocument both root-based and department-based dashboard paths.
tests/skills.test.jsandtests/runs.test.jsAdd regression coverage for mixed-layout migration cases.
Why
How to test
marketing/skills/example-skill/SKILL.mdmarketing/squads/example-squad/output/images/marketing/squads/example-squad/output/slides/npx opensquad skillsnpx opensquad runs example-squadExpected after patch:
skillslists skills installed inmarketing/skills/runsresolvesmarketing/squads/runsdoes not reportimagesorslidesas run idsskills/legacy-skill/squads/legacy-squad/output/<run-id>/marketing/skills/andmarketing/squads/Expected after patch:
npx opensquad skillsnpx opensquad runsnode --testValidation used locally
Validated locally against
opensquad@0.1.15.Results after patch:
npx opensquad skillscorrectly lists installed skills from mixed root andmarketing/layoutsnpx opensquad runs instagram-leadsresolvesmarketing/squadsnpx opensquad runs instagram-leadsno longer treatsimages/andslides/as runsnode --testpasses locally with138testsNotes
If you would prefer a more general configurable path mechanism instead of explicit
marketing/...fallback, I can adapt the patch in a follow-up. This PR keeps the change intentionally narrow while preserving backward compatibility during migration.