mirror of
https://github.com/tiennm99/ccs.git
synced 2026-07-16 20:17:45 +00:00
fix(web): correct skill detection to look for SKILL.md instead of prompt.md
The Skills page was only showing 4 skills instead of 38 because it was looking for prompt.md files instead of SKILL.md files in the skills directory. Updated the detection logic to check for SKILL.md for skills and prompt.md for agents.
This commit is contained in:
@@ -75,8 +75,9 @@ function getSharedItems(type: 'commands' | 'skills' | 'agents'): SharedItem[] {
|
||||
|
||||
for (const entry of entries) {
|
||||
if (entry.isDirectory()) {
|
||||
// Skill/Agent: look for prompt.md
|
||||
const promptPath = path.join(sharedDir, entry.name, 'prompt.md');
|
||||
// Skill/Agent: look for SKILL.md for skills, prompt.md for agents
|
||||
const markdownFile = type === 'skills' ? 'SKILL.md' : 'prompt.md';
|
||||
const promptPath = path.join(sharedDir, entry.name, markdownFile);
|
||||
if (fs.existsSync(promptPath)) {
|
||||
const content = fs.readFileSync(promptPath, 'utf8');
|
||||
const description = extractDescription(content);
|
||||
|
||||
Reference in New Issue
Block a user