release: bridge legacy installations to ForgeFlow-Public
Managed validation / full (pull_request) Successful in 27s
ChatGPT validation / quality (push) Successful in 21m36s

This commit is contained in:
NuklearRabbit committed 2026-09-30 23:02:50 +02:00
1 parent 1192d75d15
commit 8769f07539
16 files changed
+339 -222

No files matched your search

+6 -16
View File
@@ -5,6 +5,7 @@ const path = require("node:path");
const { execFileSync } = require("node:child_process");
const { app, safeStorage } = require("electron");
const { normalizeBaseUrl } = require("../src/shared/validation.cjs");
const { existingReleaseState } = require("../src/shared/release-policy.cjs");
const root = path.resolve(__dirname, "..");
const configuredUserData =
@@ -88,7 +89,7 @@ app.whenReady().then(async () => {
"Release repository owner",
);
const repo = safeRepositoryPart(
process.env.FORGEFLOW_RELEASE_REPO || config.updates?.repo || "ForgeFlow",
process.env.FORGEFLOW_RELEASE_REPO || config.updates?.repo || "ForgeFlow-Public",
"Release repository name",
);
const branch = safeRepositoryPart(
@@ -143,17 +144,10 @@ app.whenReady().then(async () => {
);
}
if (release.draft !== true) {
release = await api(
baseUrl,
token,
`/repos/${encodeURIComponent(owner)}/${encodeURIComponent(repo)}/releases/${release.id}`,
{
method: "PATCH",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ draft: true }),
},
);
if (existingReleaseState(release, version, commit) === "published") {
console.log(`PASS ForgeFlow ${version} is already published for ${commit.slice(0, 7)}`);
app.exit(0);
return;
}
const binaries = [
path.join(root, "dist", `ForgeFlow-Setup-${version}-win-x64.exe`),
@@ -172,10 +166,6 @@ app.whenReady().then(async () => {
const existing = (release.assets || []).find(
(asset) => asset.name === name,
);
if (existing && Number(existing.size) === bytes.length) {
console.log(`SKIP ${name} already published`);
continue;
}
if (existing) {
await api(
baseUrl,
+3 -2
View File
@@ -97,6 +97,7 @@ const required = [
"docs/RELEASE_NOTES_0.10.13.md",
"docs/RELEASE_NOTES_0.10.14.md",
"docs/RELEASE_NOTES_0.10.15.md",
"docs/RELEASE_NOTES_0.10.16.md",
"docs/UPDATING.md",
"docs/DIAGNOSTICS.md",
"docs/DEPLOYMENT_SETUP.md",
@@ -136,9 +137,9 @@ for (const file of required) await access(path.join(root, file));
const packageJson = JSON.parse(
await readFile(path.join(root, "package.json"), "utf8"),
);
if (packageJson.version !== "0.10.15")
if (packageJson.version !== "0.10.16")
throw new Error(
`Expected package version 0.10.15, got ${packageJson.version}.`,
`Expected package version 0.10.16, got ${packageJson.version}.`,
);
const sourceManifest = await readFile(
path.join(root, "SOURCE_MANIFEST.txt"),