📦 deps(thirdparty): update snapshots
This commit is contained in:
@@ -138,7 +138,13 @@ export function buildSitemap(skills, topCount = TOP_SKILL_COUNT, baseUrl = SITE_
|
||||
const landingPaths = getSeoLandingPaths();
|
||||
return generateSitemapXml({
|
||||
baseUrl,
|
||||
paths: ['/', toIndexableRoutePath('/plugins'), ...landingPaths, ...topSkillPaths.map(toIndexableRoutePath)],
|
||||
paths: [
|
||||
'/',
|
||||
toIndexableRoutePath('/workbench'),
|
||||
toIndexableRoutePath('/plugins'),
|
||||
...landingPaths,
|
||||
...topSkillPaths.map(toIndexableRoutePath),
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -23,6 +23,7 @@ describe('sitemap generation script helpers', () => {
|
||||
const xml = buildSitemap(catalog, 1, 'https://example.com');
|
||||
|
||||
expect(xml).toContain('https://example.com/</loc>');
|
||||
expect(xml).toContain('https://example.com/workbench/</loc>');
|
||||
expect(xml).toContain('https://example.com/topics/antigravity-cli-skills/</loc>');
|
||||
expect(xml).toContain('https://example.com/skill/gamma/</loc>');
|
||||
expect(xml).not.toContain('/skill/delta');
|
||||
@@ -37,7 +38,7 @@ describe('sitemap generation script helpers', () => {
|
||||
expect(xml).toContain('/safe%26id/</loc>');
|
||||
});
|
||||
|
||||
it('returns homepage and topic routes when top skill limit is zero', () => {
|
||||
it('returns homepage, workbench, and topic routes when top skill limit is zero', () => {
|
||||
const catalog = [
|
||||
{ id: 'gamma', stars: 2 },
|
||||
{ id: 'delta', stars: 1 },
|
||||
@@ -46,6 +47,7 @@ describe('sitemap generation script helpers', () => {
|
||||
const xml = buildSitemap(catalog, 0, 'https://example.com');
|
||||
|
||||
expect(xml).toContain('https://example.com/</loc>');
|
||||
expect(xml).toContain('https://example.com/workbench/</loc>');
|
||||
expect(xml).toContain('https://example.com/topics/github-ai-skills-repository/</loc>');
|
||||
expect(xml).not.toContain('https://example.com/skill');
|
||||
});
|
||||
|
||||
@@ -540,6 +540,88 @@ function buildPluginsMeta({ pluginCount, imageUrl, canonicalUrl }) {
|
||||
};
|
||||
}
|
||||
|
||||
function buildWorkbenchMeta({ imageUrl, canonicalUrl }) {
|
||||
const title = 'Skill Workbench | Agentic Awesome Skills';
|
||||
const description = 'Filter canonical skill evidence, compose an exact host-aware set, and preview a version-pinned install without filesystem writes.';
|
||||
const catalogBaseUrl = canonicalUrl.replace(/\/workbench\/?$/, '');
|
||||
const catalogRootUrl = `${catalogBaseUrl}/`;
|
||||
const sourceCodeEntity = {
|
||||
'@context': 'https://schema.org',
|
||||
'@type': 'SoftwareSourceCode',
|
||||
name: SITE_NAME,
|
||||
description: 'Canonical repository of installable agent skills and machine-readable registry evidence.',
|
||||
url: REPOSITORY_URL,
|
||||
sameAs: [canonicalUrl, catalogRootUrl, 'https://www.npmjs.com/package/agentic-awesome-skills'],
|
||||
mainEntityOfPage: canonicalUrl,
|
||||
codeRepository: REPOSITORY_URL,
|
||||
applicationCategory: 'DeveloperApplication',
|
||||
isAccessibleForFree: true,
|
||||
license: `${REPOSITORY_URL}/blob/main/LICENSE`,
|
||||
};
|
||||
|
||||
return {
|
||||
title,
|
||||
description,
|
||||
canonicalUrl,
|
||||
ogTitle: title,
|
||||
ogDescription: description,
|
||||
ogImage: imageUrl,
|
||||
twitterCard: 'summary_large_image',
|
||||
jsonLd: [
|
||||
{
|
||||
'@context': 'https://schema.org',
|
||||
'@type': 'WebPage',
|
||||
name: 'Agentic Awesome Skills Workbench',
|
||||
headline: 'Build a precise, inspectable skill set',
|
||||
description,
|
||||
url: canonicalUrl,
|
||||
mainEntityOfPage: canonicalUrl,
|
||||
isPartOf: {
|
||||
'@type': 'WebSite',
|
||||
name: SITE_NAME,
|
||||
url: catalogBaseUrl,
|
||||
sameAs: REPOSITORY_URL,
|
||||
},
|
||||
about: sourceCodeEntity,
|
||||
},
|
||||
{
|
||||
'@context': 'https://schema.org',
|
||||
'@type': 'BreadcrumbList',
|
||||
itemListElement: [
|
||||
{ '@type': 'ListItem', position: 1, name: SITE_NAME, item: catalogRootUrl },
|
||||
{ '@type': 'ListItem', position: 2, name: 'Skill Workbench', item: canonicalUrl },
|
||||
],
|
||||
},
|
||||
{
|
||||
'@context': 'https://schema.org',
|
||||
'@type': 'Organization',
|
||||
'@id': `${REPOSITORY_URL}#organization`,
|
||||
name: SITE_NAME,
|
||||
url: REPOSITORY_URL,
|
||||
sameAs: [
|
||||
'https://x.com/AASkills_',
|
||||
'https://www.npmjs.com/package/agentic-awesome-skills',
|
||||
catalogRootUrl,
|
||||
],
|
||||
},
|
||||
{
|
||||
'@context': 'https://schema.org',
|
||||
'@type': 'WebSite',
|
||||
name: SITE_NAME,
|
||||
url: catalogBaseUrl,
|
||||
sameAs: REPOSITORY_URL,
|
||||
inLanguage: 'en',
|
||||
potentialAction: {
|
||||
'@type': 'SearchAction',
|
||||
target: `${catalogBaseUrl}/?q={search_term_string}`,
|
||||
'query-input': 'required name=search_term_string',
|
||||
},
|
||||
},
|
||||
sourceCodeEntity,
|
||||
],
|
||||
};
|
||||
}
|
||||
|
||||
function buildTopicLandingMeta({ page, imageUrl, canonicalUrl }) {
|
||||
const catalogBaseUrl = canonicalUrl.replace(/\/topics\/[^/]+\/?$/, '');
|
||||
const keywords = Array.isArray(page.keywords) ? page.keywords.join(', ') : '';
|
||||
@@ -752,6 +834,13 @@ function main() {
|
||||
});
|
||||
writePrerenderedRoute('/plugins', template, pluginsMeta);
|
||||
|
||||
const workbenchCanonical = routeToUrl('/workbench', siteBaseUrl);
|
||||
const workbenchMeta = buildWorkbenchMeta({
|
||||
imageUrl: socialImage,
|
||||
canonicalUrl: workbenchCanonical,
|
||||
});
|
||||
writePrerenderedRoute('/workbench', template, workbenchMeta);
|
||||
|
||||
for (const page of landingPages) {
|
||||
if (!page?.slug) {
|
||||
continue;
|
||||
|
||||
@@ -233,10 +233,15 @@ export function analyzeSitemap(urlText, { minSkillUrls = 1, requireHostedUrl = f
|
||||
|
||||
const isRoot = ({ parsed: parsedUrl }) => rootPathVariants.has(parsedUrl.pathname);
|
||||
const extraRoutes = parsed.filter(({ parsed: parsedUrl }) => !isRoot({ parsed: parsedUrl }));
|
||||
const allowedExtraPathVariants = new Set([
|
||||
const pluginPathVariants = new Set([
|
||||
`${normalizedRoot}/plugins`,
|
||||
`${normalizedRoot}/plugins/`,
|
||||
]);
|
||||
const workbenchPathVariants = new Set([
|
||||
`${normalizedRoot}/workbench`,
|
||||
`${normalizedRoot}/workbench/`,
|
||||
]);
|
||||
const allowedExtraPathVariants = new Set([...pluginPathVariants, ...workbenchPathVariants]);
|
||||
const topicPathVariants = new Set(
|
||||
getSeoLandingPaths().flatMap((topicPath) => [
|
||||
`${normalizedRoot}${topicPath}`,
|
||||
@@ -273,7 +278,10 @@ export function analyzeSitemap(urlText, { minSkillUrls = 1, requireHostedUrl = f
|
||||
skillUrls: skillRoutes.map(({ raw }) => raw),
|
||||
topicUrls: topicRoutes.map(({ raw }) => raw),
|
||||
pluginUrls: extraRoutes
|
||||
.filter(({ parsed: parsedUrl }) => allowedExtraPathVariants.has(parsedUrl.pathname))
|
||||
.filter(({ parsed: parsedUrl }) => pluginPathVariants.has(parsedUrl.pathname))
|
||||
.map(({ raw }) => raw),
|
||||
workbenchUrls: extraRoutes
|
||||
.filter(({ parsed: parsedUrl }) => workbenchPathVariants.has(parsedUrl.pathname))
|
||||
.map(({ raw }) => raw),
|
||||
};
|
||||
}
|
||||
@@ -510,6 +518,20 @@ export function assertPrerenderedPluginRoutes(pluginUrls, distDir = 'dist', norm
|
||||
}
|
||||
}
|
||||
|
||||
export function assertPrerenderedWorkbenchRoutes(workbenchUrls, distDir = 'dist', normalizedRootPath = '') {
|
||||
for (const workbenchUrl of workbenchUrls) {
|
||||
const parsed = new URL(workbenchUrl);
|
||||
const filePath = safeUserPath(routePathToDistFile(parsed.pathname, normalizedRootPath), distDir);
|
||||
assert(
|
||||
fs.existsSync(filePath),
|
||||
`Missing prerendered page for workbench route: ${parsed.pathname}. Expected ${filePath}.`,
|
||||
);
|
||||
const html = readFile(filePath, distDir);
|
||||
assert(extractTitle(html).includes('Skill Workbench'), 'Workbench prerender must expose its exact product title.');
|
||||
assert(extractMetaContent(html, 'name', 'description')?.includes('exact host-aware set'), 'Workbench prerender must describe exact composition.');
|
||||
}
|
||||
}
|
||||
|
||||
export function assertPrerenderedTopicRoutes(topicUrls, distDir = 'dist', normalizedRootPath = '') {
|
||||
for (const topicUrl of topicUrls) {
|
||||
const parsed = new URL(topicUrl);
|
||||
@@ -546,6 +568,7 @@ export function assertLlms(llmsText, { expectedSkillCountLabel = '1,678+', expec
|
||||
'Claude Code',
|
||||
'Codex CLI',
|
||||
'https://github.com/sickn33/agentic-awesome-skills',
|
||||
'https://sickn33.github.io/agentic-awesome-skills/workbench',
|
||||
'Canonical source of truth',
|
||||
];
|
||||
|
||||
@@ -602,6 +625,7 @@ export function runVerification({
|
||||
const expectedSkillCountLabel = readSkillCountLabel(distDir);
|
||||
assertPrerenderedSkillRoutes(sitemapReport.skillUrls, distDir, sitemapReport.normalizedRootPath);
|
||||
assertPrerenderedPluginRoutes(sitemapReport.pluginUrls, distDir, sitemapReport.normalizedRootPath);
|
||||
assertPrerenderedWorkbenchRoutes(sitemapReport.workbenchUrls, distDir, sitemapReport.normalizedRootPath);
|
||||
assertPrerenderedTopicRoutes(sitemapReport.topicUrls, distDir, sitemapReport.normalizedRootPath);
|
||||
assertIndexSocialMeta(indexHtml);
|
||||
assertIndexDiscoveryMeta(indexHtml, { expectedSkillCountLabel, requireHostedUrl });
|
||||
|
||||
@@ -11,6 +11,7 @@ import {
|
||||
assertPrerenderedPluginRoutes,
|
||||
assertPrerenderedSkillRoutes,
|
||||
assertPrerenderedTopicRoutes,
|
||||
assertPrerenderedWorkbenchRoutes,
|
||||
assertIndexSocialMeta,
|
||||
assertLlms,
|
||||
assertRobots,
|
||||
@@ -96,6 +97,7 @@ describe('seo assets verification helpers', () => {
|
||||
Current release: V1.2.3.
|
||||
1,678+ agentic skills with specialized plugins for Claude Code and Codex CLI.
|
||||
https://github.com/sickn33/agentic-awesome-skills
|
||||
https://sickn33.github.io/agentic-awesome-skills/workbench
|
||||
Canonical source of truth: the GitHub repository is the primary project URL.
|
||||
`;
|
||||
|
||||
@@ -108,6 +110,7 @@ describe('seo assets verification helpers', () => {
|
||||
Current release: V1.2.2.
|
||||
1,678+ agentic skills with specialized plugins for Claude Code and Codex CLI.
|
||||
https://github.com/sickn33/agentic-awesome-skills
|
||||
https://sickn33.github.io/agentic-awesome-skills/workbench
|
||||
Canonical source of truth: the GitHub repository is the primary project URL.
|
||||
`;
|
||||
|
||||
@@ -313,6 +316,32 @@ describe('seo assets verification helpers', () => {
|
||||
expect(() => assertPrerenderedPluginRoutes(report.pluginUrls, distDir, report.normalizedRootPath)).not.toThrow();
|
||||
});
|
||||
|
||||
it('validates the prerendered workbench route and its exact-composition promise', () => {
|
||||
const tmpDir = fs.mkdtempSync(path.join(os.tmpdir(), 'seo-assets-'));
|
||||
const distDir = path.join(tmpDir, 'dist');
|
||||
const routeFile = path.join(distDir, 'workbench', 'index.html');
|
||||
fs.mkdirSync(path.dirname(routeFile), { recursive: true });
|
||||
fs.writeFileSync(
|
||||
routeFile,
|
||||
'<html><head><title>Skill Workbench | Compose an exact agent stack</title><meta name="description" content="Filter, inspect, and install an exact host-aware set of skills." /></head></html>',
|
||||
);
|
||||
|
||||
const xml = `
|
||||
<urlset>
|
||||
<url><loc>https://owner.github.io/repo/</loc></url>
|
||||
<url><loc>https://owner.github.io/repo/workbench/</loc></url>
|
||||
</urlset>
|
||||
`;
|
||||
|
||||
const report = analyzeSitemap(xml, { minSkillUrls: 0 });
|
||||
expect(report.workbenchUrls).toEqual(['https://owner.github.io/repo/workbench/']);
|
||||
expect(() => assertPrerenderedWorkbenchRoutes(
|
||||
report.workbenchUrls,
|
||||
distDir,
|
||||
report.normalizedRootPath,
|
||||
)).not.toThrow();
|
||||
});
|
||||
|
||||
it('throws when a prerendered skill file is missing', () => {
|
||||
const tmpDir = fs.mkdtempSync(path.join(os.tmpdir(), 'seo-assets-'));
|
||||
const distDir = path.join(tmpDir, 'dist');
|
||||
|
||||
Reference in New Issue
Block a user