(dir: string)
| 107 | } |
| 108 | |
| 109 | function visit(dir: string): void { |
| 110 | const entries = fs.readdirSync(dir, { withFileTypes: true }); |
| 111 | |
| 112 | for (const entry of entries) { |
| 113 | const fullPath = path.join(dir, entry.name); |
| 114 | if (entry.isDirectory()) { |
| 115 | visit(fullPath); |
| 116 | continue; |
| 117 | } |
| 118 | |
| 119 | if (entry.name !== "SKILL.md") { |
| 120 | continue; |
| 121 | } |
| 122 | |
| 123 | const skill = parseSkillMd(fullPath); |
| 124 | if (skill) { |
| 125 | installed.push(skill); |
| 126 | } |
| 127 | } |
| 128 | } |
| 129 | |
| 130 | visit(skillsDir); |
| 131 | return installed; |
no test coverage detected