GeezerVison is showing github.com — sync · al-prk/opencode@cd79676
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: packages/opencode/script/publish.ts +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -42,7 +42,7 @@ await $`cd ./dist/${pkg.name} && bun publish --access public --tag ${Script.chan |
42 | 42 |
|
43 | 43 | if (!Script.preview) { |
44 | 44 | const major = Script.version.split(".")[0] |
45 | | - const majorTag = `v${major}` |
| 45 | + const majorTag = `latest-${major}` |
46 | 46 | for (const [name] of Object.entries(binaries)) { |
47 | 47 | await $`cd dist/${name} && npm dist-tag add ${name}@${Script.version} ${majorTag}` |
48 | 48 | } |
|
Collapse file
Copy file name to clipboardExpand all lines: packages/script/src/index.ts +5-2Lines changed: 5 additions & 2 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -4,10 +4,13 @@ if (process.versions.bun !== "1.3.0") { |
4 | 4 | |
5 | 5 | } |
6 | 6 |
|
7 | | -const CHANNEL = process.env["OPENCODE_CHANNEL"] ?? (await $`git branch --show-current`.text().then((x) => x.trim())) |
| 7 | +const CHANNEL = |
| 8 | + process.env["OPENCODE_CHANNEL"] ?? |
| 9 | + (await $`git branch --show-current`.text().then((x) => x.trim())) |
8 | 10 | const IS_PREVIEW = CHANNEL !== "latest" |
9 | 11 | const VERSION = await (async () => { |
10 | | - if (IS_PREVIEW) return `0.0.0-${CHANNEL}-${new Date().toISOString().slice(0, 16).replace(/[-:T]/g, "")}` |
| 12 | + if (IS_PREVIEW) |
| 13 | + return `0.0.0-${CHANNEL}-${new Date().toISOString().slice(0, 16).replace(/[-:T]/g, "")}` |
11 | 14 | const version = await fetch("https://registry.npmjs.org/opencode-ai/latest") |
12 | 15 | .then((res) => { |
13 | 16 | if (!res.ok) throw new Error(res.statusText) |
|