feat: migrate repo releases to manual release-please (#293)

This commit is contained in:
Trevin Chow
2026-03-17 17:58:13 -07:00
committed by GitHub
parent 74fb71731a
commit f47f829d81
44 changed files with 1967 additions and 801 deletions

View File

@@ -0,0 +1,33 @@
#!/usr/bin/env bun
import { updateRootChangelog } from "../../src/release/metadata"
import type { ReleaseComponent } from "../../src/release/types"
type EntryInput = {
component: ReleaseComponent
version: string
date: string
sections: Record<string, string[]>
}
function parseEntries(argv: string[]): EntryInput[] {
const jsonIndex = argv.findIndex((arg) => arg === "--entries")
if (jsonIndex === -1) return []
const raw = argv[jsonIndex + 1]
if (!raw) return []
return JSON.parse(raw) as EntryInput[]
}
const write = process.argv.includes("--write")
const entries = parseEntries(process.argv.slice(2))
if (entries.length === 0) {
console.error("No changelog entries provided. Pass --entries '<json>'.")
process.exit(1)
}
const result = await updateRootChangelog({
entries,
write,
})
console.log(`${result.changed ? "update" : "keep"} ${result.path}`)