GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — ci · f2dmarques/opencode@8e674ae

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • .github/workflows
    • publish.yml
  • packages/tauri/scripts
    • prepare.ts
  • script
    • publish-start.ts
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎.github/workflows/publish.yml‎

Copy file name to clipboardExpand all lines: .github/workflows/publish.yml
+7-10Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,9 @@ jobs:
8080
GITHUB_TOKEN: ${{ secrets.SST_GITHUB_TOKEN }}
8181
NPM_CONFIG_PROVENANCE: false
8282
outputs:
83-
releaseId: ${{ steps.publish.outputs.releaseId }}
84-
tagName: ${{ steps.publish.outputs.tagName }}
83+
release: ${{ steps.publish.outputs.release }}
84+
tag: ${{ steps.publish.outputs.tag }}
85+
version: ${{ steps.publish.outputs.version }}
8586

8687
publish-tauri:
8788
needs: publish
@@ -150,16 +151,13 @@ jobs:
150151
cd packages/tauri
151152
bun ./scripts/prepare.ts
152153
env:
153-
OPENCODE_BUMP: ${{ inputs.bump }}
154-
OPENCODE_VERSION: ${{ inputs.version }}
155-
OPENCODE_CHANNEL: latest
154+
OPENCODE_VERSION: ${{ needs.publish.outputs.version }}
156155
NPM_CONFIG_TOKEN: ${{ secrets.NPM_TOKEN }}
157156
GITHUB_TOKEN: ${{ secrets.SST_GITHUB_TOKEN }}
158157
AUR_KEY: ${{ secrets.AUR_KEY }}
159158
OPENCODE_API_KEY: ${{ secrets.OPENCODE_API_KEY }}
160159
RUST_TARGET: ${{ matrix.settings.target }}
161160
GH_TOKEN: ${{ github.token }}
162-
OPENCODE_RELEASE_TAG: ${{ needs.publish.outputs.tagName }}
163161

164162
# Fixes AppImage build issues, can be removed when https://github.com/tauri-apps/tauri/pull/12491 is released
165163
- name: Install tauri-cli from portable appimage branch
@@ -189,8 +187,8 @@ jobs:
189187
tauriScript: ${{ (contains(matrix.settings.host, 'ubuntu') && 'cargo tauri') || '' }}
190188
args: --target ${{ matrix.settings.target }} --config src-tauri/tauri.prod.conf.json
191189
updaterJsonPreferNsis: true
192-
releaseId: ${{ needs.publish.outputs.releaseId }}
193-
tagName: ${{ needs.publish.outputs.tagName }}
190+
releaseId: ${{ needs.publish.outputs.release }}
191+
tagName: ${{ needs.publish.outputs.tag }}
194192
releaseAssetNamePattern: opencode-desktop-[platform]-[arch][ext]
195193
releaseDraft: true
196194

@@ -221,7 +219,6 @@ jobs:
221219
222220
- run: ./script/publish-complete.ts
223221
env:
224-
OPENCODE_VERSION: ${{ needs.publish.outputs.tagName }}
222+
OPENCODE_VERSION: ${{ needs.publish.outputs.version }}
225223
AUR_KEY: ${{ secrets.AUR_KEY }}
226224
GITHUB_TOKEN: ${{ secrets.SST_GITHUB_TOKEN }}
227-
OPENCODE_RELEASE_TAG: ${{ needs.publish.outputs.tagName }}
Collapse file

‎packages/tauri/scripts/prepare.ts‎

Copy file name to clipboardExpand all lines: packages/tauri/scripts/prepare.ts
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,14 @@
33
import { $ } from "bun"
44

55
import { copyBinaryToSidecarFolder, getCurrentSidecar } from "./utils"
6+
import { Script } from "@opencode-ai/script"
67

78
const sidecarConfig = getCurrentSidecar()
89

910
const dir = "src-tauri/target/opencode-binaries"
1011

1112
await $`mkdir -p ${dir}`
12-
await $`gh release download ${Bun.env.OPENCODE_RELEASE_TAG} --pattern ${sidecarConfig.ocBinary}.${sidecarConfig.assetExt} --repo sst/opencode --skip-existing --dir ${dir}`
13+
await $`gh release download v${Script.version} --pattern ${sidecarConfig.ocBinary}.${sidecarConfig.assetExt} --repo sst/opencode --skip-existing --dir ${dir}`
1314

1415
if (sidecarConfig.assetExt === "tar.gz") {
1516
await $`tar -xvzf ${dir}/${sidecarConfig.ocBinary}.${sidecarConfig.assetExt} -C ${dir}`
Collapse file

‎script/publish-start.ts‎

Copy file name to clipboardExpand all lines: script/publish-start.ts
+8-3Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,8 @@ await import(`../packages/plugin/script/publish.ts`)
181181
const dir = new URL("..", import.meta.url).pathname
182182
process.chdir(dir)
183183

184+
let output = `version=${Script.version}\n`
185+
184186
if (!Script.preview) {
185187
await $`git commit -am "release: v${Script.version}"`
186188
await $`git tag v${Script.version}`
@@ -190,7 +192,10 @@ if (!Script.preview) {
190192
await new Promise((resolve) => setTimeout(resolve, 5_000))
191193
await $`gh release create v${Script.version} -d --title "v${Script.version}" --notes ${notes.join("\n") || "No notable changes"} ./packages/opencode/dist/*.zip ./packages/opencode/dist/*.tar.gz`
192194
const release = await $`gh release view v${Script.version} --json id,tagName`.json()
193-
if (process.env.GITHUB_OUTPUT) {
194-
await Bun.write(process.env.GITHUB_OUTPUT, `releaseId=${release.id}\ntagName=${release.tagName}\n`)
195-
}
195+
output += `release=${release.id}`
196+
output += `tag=${release.tagName}`
197+
}
198+
199+
if (process.env.GITHUB_OUTPUT) {
200+
await Bun.write(process.env.GITHUB_OUTPUT, output)
196201
}

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.