GeezerVison is showing github.com — ci · cyrilmhansen/opencode@2e005de
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: script/beta.ts +12Lines changed: 12 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -34,6 +34,18 @@ async function main() { |
34 | 34 | throw new Error(`Failed to checkout beta branch: ${checkoutBeta.stderr}`) |
35 | 35 | } |
36 | 36 |
|
| 37 | + const shallow = await run(["git", "rev-parse", "--is-shallow-repository"]) |
| 38 | + if (shallow.exitCode !== 0) { |
| 39 | + throw new Error(`Failed to check shallow state: ${shallow.stderr}`) |
| 40 | + } |
| 41 | + if (shallow.stdout.trim() === "true") { |
| 42 | + console.log("Unshallowing repository...") |
| 43 | + const unshallow = await run(["git", "fetch", "--unshallow"]) |
| 44 | + if (unshallow.exitCode !== 0) { |
| 45 | + throw new Error(`Failed to unshallow repository: ${unshallow.stderr}`) |
| 46 | + } |
| 47 | + } |
| 48 | + |
37 | 49 | const applied: number[] = [] |
38 | 50 | const skipped: Array<{ number: number; reason: string }> = [] |
39 | 51 |
|
|