diff --git a/scripts/release-npm-tag.mjs b/scripts/release-npm-tag.mjs index ad85b9798c..b6f9e1ac7c 100644 --- a/scripts/release-npm-tag.mjs +++ b/scripts/release-npm-tag.mjs @@ -1,15 +1,7 @@ import semver from "semver"; -import { resolve } from "node:path"; -import { fileURLToPath } from "node:url"; export function releaseNpmTag(version) { if (version === undefined || semver.valid(version) !== version) throw new Error("Expected an exact SemVer version."); return semver.prerelease(version) === null ? "latest" : "next"; } - -if ( - process.argv[1] !== undefined && - resolve(process.argv[1]) === fileURLToPath(import.meta.url) -) - process.stdout.write(releaseNpmTag(process.argv[2])); diff --git a/scripts/release-proposal.mjs b/scripts/release-proposal.mjs index bf64a27bc5..3f85424ef3 100644 --- a/scripts/release-proposal.mjs +++ b/scripts/release-proposal.mjs @@ -56,7 +56,7 @@ async function main() { if (process.env.GITHUB_OUTPUT) { await appendFile( process.env.GITHUB_OUTPUT, - `prs_created=${prs.length > 0}\n${prs.length ? `pr=${JSON.stringify(prs[0])}\nprs=${JSON.stringify(prs)}\n` : ""}`, + `prs_created=${prs.length > 0}\n${prs.length ? `pr=${JSON.stringify(prs[0])}\n` : ""}`, ); } } diff --git a/tests/boundary/filesystem/releaseWorkflow.test.ts b/tests/boundary/filesystem/releaseWorkflow.test.ts index 60064dbe10..473659dacc 100644 --- a/tests/boundary/filesystem/releaseWorkflow.test.ts +++ b/tests/boundary/filesystem/releaseWorkflow.test.ts @@ -1,7 +1,6 @@ import { execFile } from "node:child_process"; import { readFile, writeFile } from "node:fs/promises"; import { delimiter, join } from "node:path"; -import { fileURLToPath } from "node:url"; import { promisify } from "node:util"; import { expect, it } from "vitest"; import { parse } from "yaml"; @@ -542,20 +541,6 @@ it("binds npm and MCP publication to the same immutable release SHA", async () = expect(publishCommand).toContain( '--registry=https://registry.npmjs.org --access=public --tag="$NPM_RELEASE_TAG"', ); - for (const [version, tag] of [ - ["6.1.0", "latest"], - ["6.1.0-rc.1", "next"], - ] as const) { - const helper = new URL( - "../../../scripts/release-npm-tag.mjs", - import.meta.url, - ); - const result = await execFileAsync(process.execPath, [ - fileURLToPath(helper), - version, - ]); - expect(result.stdout).toBe(tag); - } }); it.skipIf(process.platform === "win32").each([