From 8fd5fe6a5fd9dac0ff9e94a90f8d1862d8d7e5c1 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Fri, 30 Jan 2026 09:19:37 -0500 Subject: [PATCH] sync --- .github/workflows/publish.yml | 21 +++++++++++---------- script/version.ts | 4 ++-- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 3974d23ffc..85a559031f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -7,6 +7,7 @@ on: - ci - dev - beta + - workflow/publish-updates - snapshot-* workflow_dispatch: inputs: @@ -49,7 +50,7 @@ jobs: run: | ./script/version.ts env: - GH_TOKEN: ${{ github.token }} + GITHUB_TOKEN: ${{ github.token }} OPENCODE_BUMP: ${{ inputs.bump }} OPENCODE_VERSION: ${{ inputs.version }} OPENCODE_API_KEY: ${{ secrets.OPENCODE_API_KEY }} @@ -76,7 +77,7 @@ jobs: env: OPENCODE_VERSION: ${{ needs.version.outputs.version }} OPENCODE_RELEASE: ${{ needs.version.outputs.release }} - GH_TOKEN: ${{ github.token }} + GITHUB_TOKEN: ${{ github.token }} - uses: actions/upload-artifact@v4 with: @@ -166,7 +167,7 @@ jobs: OPENCODE_VERSION: ${{ needs.version.outputs.version }} GITHUB_TOKEN: ${{ steps.committer.outputs.token }} RUST_TARGET: ${{ matrix.settings.target }} - GH_TOKEN: ${{ github.token }} + GITHUB_TOKEN: ${{ github.token }} GITHUB_RUN_ID: ${{ github.run_id }} # Fixes AppImage build issues, can be removed when https://github.com/tauri-apps/tauri/pull/12491 is released @@ -231,13 +232,6 @@ jobs: node-version: "24" registry-url: "https://registry.npmjs.org" - - name: Setup git committer - id: committer - uses: ./.github/actions/setup-git-committer - with: - opencode-app-id: ${{ vars.OPENCODE_APP_ID }} - opencode-app-secret: ${{ secrets.OPENCODE_APP_SECRET }} - - uses: actions/download-artifact@v4 with: name: opencode-cli @@ -262,6 +256,13 @@ jobs: git config --global user.name "opencode" ssh-keyscan -H aur.archlinux.org >> ~/.ssh/known_hosts || true + - name: Setup git committer + id: committer + uses: ./.github/actions/setup-git-committer + with: + opencode-app-id: ${{ vars.OPENCODE_APP_ID }} + opencode-app-secret: ${{ secrets.OPENCODE_APP_SECRET }} + - run: ./script/publish.ts env: OPENCODE_VERSION: ${{ needs.version.outputs.version }} diff --git a/script/version.ts b/script/version.ts index 1b7eac5d91..d3b1274955 100755 --- a/script/version.ts +++ b/script/version.ts @@ -6,14 +6,14 @@ import { buildNotes, getLatestRelease } from "./changelog" const output = [`version=${Script.version}`] -if (!Script.preview) { +if (!Script.preview || true) { const previous = await getLatestRelease() const notes = await buildNotes(previous, "HEAD") const body = notes.join("\n") || "No notable changes" const dir = process.env.RUNNER_TEMP ?? "/tmp" const file = `${dir}/opencode-release-notes.txt` await Bun.write(file, body) - await $`gh release create v${Script.version} -d --title "v${Script.version}" --notes-file ${file}` + await $`gh release create v${Script.version} -d --title "v${Script.version}" --notes-file ${file} --prerelease=${Script.preview}` const release = await $`gh release view v${Script.version} --json id,tagName`.json() output.push(`release=${release.id}`) output.push(`tag=${release.tagName}`)