Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .claude/skills/release-video/assets/youtube-metadata.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/usr/bin/env node
/**
* The YouTube title and description of the release video, in the layout of the published ones:
* The YouTube title and description of the release video, in the layout of the published ones, with the
* themes and the programme they are built from, which the announcements are built from too:
* `node .claude/skills/release-video/assets/youtube-metadata.js --version 5.13 --tag v5.13.0 --repo <owner/repo> [--out release-video.json]`.
*/
const fs = require("node:fs");
Expand Down Expand Up @@ -28,7 +29,8 @@ function youtubeMetadata(plan, { version, tag, repo }) {
];
if (contributors) lines.push(`Version livrée par ${contributors} contributeurs (crédits dans les notes de version).`, "");
lines.push(`Notes de version : https://github.com/${repo}/releases/tag/${tag}`, `Code source : https://github.com/${repo}`);
return { title: titleOf(plan, version), description: lines.join("\n") };
const { themes, programme } = plan.youtube;
return { title: titleOf(plan, version), description: lines.join("\n"), themes, programme };
}

/** What a plan lacks to be published: the block, a title that fits, a line for every scene's surface. */
Expand Down
7 changes: 7 additions & 0 deletions scripts/__tests__/youtube-metadata.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@ test("the description follows the published layout, with commands, contributors
);
});

test("the themes and the programme travel with the text, so an announcement can be built from the video", () => {
const metadata = youtubeMetadata(plan, context);

assert.deepEqual(metadata.themes, plan.youtube.themes);
assert.deepEqual(metadata.programme, plan.youtube.programme);
});

test("a plugin skill is written as a slash command and a CLI command is left as it is", () => {
const { description } = youtubeMetadata(plan, context);

Expand Down
Loading