@devries-cameron20 / t3code Mirror · read-only / commits / b297e20f4e
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 25, 10:00 UTC

Fix release target commit and gate version bump steps

- Set `target_commitish` from preflight ref when creating GitHub releases - Track whether package versions changed and expose it via step output - Run format, lockfile refresh, and bump commit only when changes exist

Julius Marminge committed Mar 5, 2026 at 16:01 UTC b297e20f4e6e9a89d8f160e021b0b0f91248ca4f
1 file changed +9 -2
.github/workflows/release.yml
+9 -2
@@ -257,6 +257,7 @@ jobs:
257 uses: softprops/action-gh-release@v2
258 with:
259 tag_name: ${{ needs.preflight.outputs.tag }}
260 + target_commitish: ${{ needs.preflight.outputs.ref }}
261 name: T3 Code v${{ needs.preflight.outputs.version }}
262 generate_release_notes: true
263 make_latest: true
@@ -290,12 +291,13 @@ jobs:
291 with:
292 node-version-file: package.json
293
293 - - name: Update version strings
294 + - id: update_versions
295 + name: Update version strings
296 env:
297 RELEASE_VERSION: ${{ needs.preflight.outputs.version }}
298 run: |
299 node --input-type=module -e '
298 - import { readFileSync, writeFileSync } from "node:fs";
300 + import { appendFileSync, readFileSync, writeFileSync } from "node:fs";
301
302 const files = [
303 "apps/server/package.json",
@@ -317,15 +319,20 @@ jobs:
319 if (!changed) {
320 console.log("All package.json versions already match release version.");
321 }
322 +
323 + appendFileSync(process.env.GITHUB_OUTPUT, `changed=${changed}\n`);
324 '
325
326 - name: Format package.json files
327 + if: steps.update_versions.outputs.changed == 'true'
328 run: bunx oxfmt apps/server/package.json apps/desktop/package.json apps/web/package.json packages/contracts/package.json
329
330 - name: Refresh lockfile
331 + if: steps.update_versions.outputs.changed == 'true'
332 run: bun install
333
334 - name: Commit and push version bump
335 + if: steps.update_versions.outputs.changed == 'true'
336 shell: bash
337 env:
338 RELEASE_TAG: ${{ needs.preflight.outputs.tag }}