summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/nix-hashes.yml2
-rwxr-xr-xscript/beta.ts13
2 files changed, 10 insertions, 5 deletions
diff --git a/.github/workflows/nix-hashes.yml b/.github/workflows/nix-hashes.yml
index 894dbf47b..2529c14c2 100644
--- a/.github/workflows/nix-hashes.yml
+++ b/.github/workflows/nix-hashes.yml
@@ -6,7 +6,7 @@ permissions:
on:
workflow_dispatch:
push:
- branches: [dev]
+ branches: [dev, beta]
paths:
- "bun.lock"
- "package.json"
diff --git a/script/beta.ts b/script/beta.ts
index b5f1c3e1e..a5fb027e6 100755
--- a/script/beta.ts
+++ b/script/beta.ts
@@ -128,10 +128,15 @@ async function main() {
await $`git fetch origin beta`
const localTree = await $`git rev-parse beta^{tree}`.text()
- const remoteTree = await $`git rev-parse origin/beta^{tree}`.text()
-
- if (localTree.trim() === remoteTree.trim()) {
- console.log("Beta branch has identical contents, no push needed")
+ const remoteTrees = (await $`git log origin/dev..origin/beta --format=%T`.text()).split("\n")
+
+ const matchIdx = remoteTrees.indexOf(localTree.trim())
+ if (matchIdx !== -1) {
+ if (matchIdx !== 0) {
+ console.log(`Beta branch contains this sync, but additional commits exist after it. Leaving beta branch as is.`)
+ } else {
+ console.log("Beta branch has identical contents, no push needed")
+ }
return
}