mirror of
https://github.com/aljazceru/opencode.git
synced 2026-01-05 00:44:54 +01:00
ci: stuff
This commit is contained in:
@@ -74,7 +74,6 @@ const pkgjsons = await Array.fromAsync(
|
||||
}),
|
||||
).then((arr) => arr.filter((x) => !x.includes("node_modules") && !x.includes("dist")))
|
||||
|
||||
const tree = await $`git add . && git write-tree`.text().then((x) => x.trim())
|
||||
for (const file of pkgjsons) {
|
||||
let pkg = await Bun.file(file).text()
|
||||
pkg = pkg.replaceAll(/"version": "[^"]+"/g, `"version": "${Script.version}"`)
|
||||
@@ -104,14 +103,3 @@ if (!Script.preview) {
|
||||
|
||||
await $`gh release create v${Script.version} --title "v${Script.version}" --notes ${notes.join("\n") ?? "No notable changes"} ./packages/opencode/dist/*.zip`
|
||||
}
|
||||
if (Script.preview) {
|
||||
await $`git checkout -b snapshot-${Script.version}`
|
||||
await $`git commit --allow-empty -m "Snapshot release v${Script.version}"`
|
||||
await $`git tag v${Script.version}`
|
||||
await $`git push origin v${Script.version} --no-verify`
|
||||
await $`git checkout dev`
|
||||
await $`git branch -D snapshot-${Script.version}`
|
||||
for (const file of pkgjsons) {
|
||||
await $`git checkout ${tree} ${file}`
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user