diff --git a/workspaces/cms-scripts/src/index.ts b/workspaces/cms-scripts/src/index.ts index 9a88145f77e..6f07c48d3a7 100644 --- a/workspaces/cms-scripts/src/index.ts +++ b/workspaces/cms-scripts/src/index.ts @@ -11,6 +11,7 @@ import { AnnouncementsPost, RoadmapDetails, RoadmapPost, + getAnnouncements, getPages, getPosts, getRoadmapPosts, @@ -186,6 +187,7 @@ for (const simpleFile of simpleFiles) { const posts = await getPosts(); const roadmapPosts = await getRoadmapPosts(); +const announcements = await getAnnouncements(); const pages = await getPages(); const tutorials = await getTutorials(); @@ -222,6 +224,13 @@ for (const data of roadmapPosts.filenameMap.values()) { ); } +for (const data of announcements.filenameMap.values()) { + await write( + `public/data/announcements/${data.locale}/${data.slug}.json`, + data +); +} + for (const locale of locales) { await fs.mkdir(`public/data/pages/${locale}`, { recursive: true }); } @@ -270,4 +279,5 @@ const redirects = await yaml("_data/settings/redirects.yml"); await write(`workspaces/website/redirects.json`, redirects); await createRoadmapDetails() +await createAnnouncementDetails() await createSharedData()