Skip to content

The open source coding agent.

TypeScript

ci

Dax Raadb1b8f6cf7159
diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml
index 77d7bb30e0b..cdc8bd741d4 100644
--- a/.github/workflows/publish.yml
+++ b/.github/workflows/publish.yml
@@ -221,8 +221,7 @@ jobs:
- run: ./script/publish-complete.ts
env:
- OPENCODE_BUMP: ${{ inputs.bump }}
- OPENCODE_VERSION: ${{ inputs.version }}
+ OPENCODE_VERSION: ${{ needs.publish.outputs.tagName }}
AUR_KEY: ${{ secrets.AUR_KEY }}
GITHUB_TOKEN: ${{ secrets.SST_GITHUB_TOKEN }}
OPENCODE_RELEASE_TAG: ${{ needs.publish.outputs.tagName }}
diff --git a/packages/tauri/scripts/prepare.ts b/packages/tauri/scripts/prepare.ts
index 23cf3dc5dbe..692e0dd788c 100755
--- a/packages/tauri/scripts/prepare.ts
+++ b/packages/tauri/scripts/prepare.ts
@@ -3,13 +3,14 @@
import { $ } from "bun"
import { copyBinaryToSidecarFolder, getCurrentSidecar } from "./utils"
+import { Script } from "@opencode-ai/script"
const sidecarConfig = getCurrentSidecar()
const dir = "src-tauri/target/opencode-binaries"
await $`mkdir -p ${dir}`
-await $`gh release download ${Bun.env.OPENCODE_RELEASE_TAG} --pattern ${sidecarConfig.ocBinary}.${sidecarConfig.assetExt} --repo sst/opencode --skip-existing --dir ${dir}`
+await $`gh release download v${Script.version} --pattern ${sidecarConfig.ocBinary}.${sidecarConfig.assetExt} --repo sst/opencode --skip-existing --dir ${dir}`
if (sidecarConfig.assetExt === "tar.gz") {
await $`tar -xvzf ${dir}/${sidecarConfig.ocBinary}.${sidecarConfig.assetExt} -C ${dir}`
diff --git a/script/publish-complete.ts b/script/publish-complete.ts
index aae1a3524ac..a3bdceae07d 100755
--- a/script/publish-complete.ts
+++ b/script/publish-complete.ts
@@ -4,7 +4,7 @@ import { Script } from "@opencode-ai/script"
import { $ } from "bun"
if (!Script.preview) {
- await $`gh release edit ${process.env.OPENCODE_RELEASE_TAG} --draft=false`
+ await $`gh release edit v${Script.version} --draft=false`
}
await $`bun install`