Support marketing/{skills,squads} project layout and ignore non-run output directories in runs
Summary
The current CLI assumes that project-level skills and squads always live at the repository root:
skills/squads/
That breaks projects organized by department, where the canonical layout is:
marketing/skills/marketing/squads/
There is also a second issue in runs: it treats any directory under output/ as a run, which causes false positives for asset folders such as output/images/ and output/slides/.
Current behavior
npx opensquad skillsonly readsskills/npx opensquad runs <squad>only readssquads/npx opensquad runs <squad>treats any folder inoutput/as a run id
Expected behavior
- Prefer
marketing/skills/when it exists, with fallback toskills/ - Prefer
marketing/squads/when it exists, with fallback tosquads/ - Only treat real run directories as runs, for example
YYYY-MM-DD-HHmmssandYYYY-MM-DD-HHmmss-N
Minimal reproduction
- Create a project using:
marketing/skills/example-skill/SKILL.mdmarketing/squads/example-squad/output/images/marketing/squads/example-squad/output/slides/
- Run
npx opensquad skills - Run
npx opensquad runs example-squad
Observed today:
skillsdoes not findexample-skillrunsdoes not resolve the squad path unless the project also keeps a legacysquads/alias- when the squad path is resolved,
imagesandslidescan be reported as if they were runs
Environment
- OS: macOS Darwin 25.4.0
- Node.js:
v24.11.1 - npm:
11.6.2 - IDE: Codex / Claude Code-compatible local environment
Proposed fix
Keep the upstream change minimal and runtime-only:
- update
src/skills.jsto resolvemarketing/skills/first, then fallback toskills/ - update
src/runs.jsto resolvemarketing/squads/first, then fallback tosquads/ - update
src/runs.jsto ignore non-run directories insideoutput/
I already prepared a patch for [email protected] plus matching tests for skills and runs.
Notes
- This preserves backward compatibility for existing root-based projects.
- I intentionally did not include template or documentation changes in the patch, to keep the proposal narrowly scoped to CLI/runtime behavior first.
- I checked the current upstream
masterbranch before preparing this report:src/skills.jsstill resolves onlyskills/, andsrc/runs.jsstill resolves onlysquads/and lists everyoutput/subdirectory as a run.
Opened PR #24 for this fix: https://github.com/renatoasse/opensquad/pull/24
A parte do runs, que tratava pastas como output/images e output/slides como execuções, foi corrigida na master em eccde7e. O layout marketing/{skills,squads} não vai entrar: o opensquad mantém um layout único, com skills/ e squads/ na raiz. Mais detalhes no PR #24. Fechando.