fix(release): keep the launched package name when comparing plugin manifests

The version-only comparison blanked the whole launch argument, so a release
that swapped rea-agents for another package passed the notes check as a
version bump. Mask only the version after the last "@" and test a changed
package name.

The plugin readiness command in the installation guide now uses the pinned
release version, so its report describes the server the plugin starts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
GamerDubz
2026-10-13 08:51:56 +02:00
co-authored by Claude Opus 5.5
parent 2da5e86289
commit 2fb79a99c8
3 changed files with 31 additions and 9 deletions
+18 -6
View File
@@ -48,10 +48,13 @@ const pluginManifests = [
".codex-plugin/plugin.json",
] as const;
const pluginManifest = (version: string, skills = ["./skill"]) => ({
const pluginManifest = (
version: string,
{ skills = ["./skill"], packageName = "rea-agents" } = {},
) => ({
version,
skills,
mcpServers: { rea: { args: ["-y", `rea-agents@${version}`, "mcp"] } },
mcpServers: { rea: { args: ["-y", `${packageName}@${version}`, "mcp"] } },
});
beforeAll(async () => {
@@ -415,13 +418,22 @@ it("binds publication to complete recorded history and the reviewed base", async
});
});
it.each(pluginManifests)(
"treats a release that changes plugin behavior in %s as a product change",
async (path) => {
it.each(
pluginManifests.flatMap((path) => [
{ path, change: "the skill path", edit: { skills: ["./another-skill"] } },
{
path,
change: "the launched package",
edit: { packageName: "another-package" },
},
]),
)(
"treats a release that changes $change in $path as a product change",
async ({ path, edit }) => {
const f = await fixture();
await writeFile(
join(f.directory, path),
JSON.stringify(pluginManifest("6.4.0", ["./another-skill"])),
JSON.stringify(pluginManifest("6.4.0", edit)),
);
await git(f.directory, ["add", "CHANGELOG.md", path]);
await git(f.directory, ["commit", "-m", "chore: release notes"]);