merge: integrate upstream main with local Makelore changes
This commit is contained in:
@@ -104,8 +104,11 @@ export async function listProductCodingSkills(
|
||||
];
|
||||
const visibleSources = sources.filter(({ id, available }) => available !== false || selected.has(id));
|
||||
return await Promise.all(visibleSources.map(async ({ id, directory, entryPath, available = true }) => {
|
||||
const location = path.resolve(directory);
|
||||
const content = await readFile(path.join(location, entryPath ?? 'SKILL.md'), 'utf8');
|
||||
const sourceLocation = path.resolve(directory);
|
||||
const location = (BUNDLED_CODING_SKILL_IDS as readonly string[]).includes(id)
|
||||
? path.posix.join('resources', 'coding-skills', id)
|
||||
: sourceLocation;
|
||||
const content = await readFile(path.join(sourceLocation, entryPath ?? 'SKILL.md'), 'utf8');
|
||||
return {
|
||||
id: productSkillId(id),
|
||||
name: frontmatterScalar(content, 'name') ?? id,
|
||||
@@ -115,7 +118,7 @@ export async function listProductCodingSkills(
|
||||
effective: available && selected.has(id),
|
||||
location,
|
||||
content,
|
||||
entries: await listSkillEntries(location),
|
||||
entries: await listSkillEntries(sourceLocation),
|
||||
};
|
||||
}));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user