Skip to content

chore(release): rewire pipeline for fork-owned releases#3

Merged
Berkay2002 merged 1 commit into
mainfrom
release-pipeline-fork
Apr 16, 2026
Merged

chore(release): rewire pipeline for fork-owned releases#3
Berkay2002 merged 1 commit into
mainfrom
release-pipeline-fork

Conversation

@Berkay2002
Copy link
Copy Markdown
Owner

Summary

  • Drop schedule: cron + nightly branch from release.yml. Tag-only + workflow_dispatch (stable) escape hatch.
  • Rename apps/server npm package from t3 to @berkayorhan/bcode (scoped, owned by this fork). Add publishConfig.access: public.
  • Rename CLI binary from t3 to bcode so npx @berkayorhan/bcode invokes bcode.
  • Update Turbo filters (--filter=t3--filter=@berkayorhan/bcode) in root package.json, release.yml, and scripts/dev-runner.ts.
  • Point apps/server repository.url at Berkay2002/bcode.

Discovery notes

  • No electron-builder.yml exists; build config is generated in scripts/build-desktop-artifact.ts. Bundle ID stays com.t3tools.t3code for this PR (deep rebrand is in sub-project 2).
  • Desktop publish target already resolves GITHUB_REPOSITORY (= Berkay2002/bcode in CI). No change needed.
  • apps/server/scripts/cli.ts reads name from package.json — no hardcoded "t3" strings.

Source spec: docs/superpowers/specs/2026-04-16-bcode-release-and-deep-rebrand-design.md (sub-project 1).
Plan: docs/superpowers/plans/2026-04-16-bcode-release-pipeline-and-v0-0-18.md Phase A.

Known pre-existing CI failure (not introduced by this PR)

apps/server typecheck fails on 10 errors in integration/perf/serverLatency.perf.test.ts:

  • WS_METHODS.gitStatus — renamed to gitRefreshStatus in the contract
  • WS_METHODS.subscribeOrchestrationDomainEvents — removed; domain events moved to the orchestration.domainEvent push channel

The perf test has been stale since d81e41c3 ("fix: resolve test failures from provider usage limits cherry-pick") and is unrelated to the rename work in this PR. Tracking this as a follow-up alongside the deep identifier rebrand (sub-project 2).

PRs #1 and #2 already cleared the pre-existing drift in apps/web and apps/server/src.

Test plan

  • bun run fmt
  • bun run lint
  • bun run typecheck — pre-existing integration/perf/serverLatency.perf.test.ts failures only (see above)
  • bun run test@t3tools/web 888 tests pass; server suite has 27 pre-existing failures tied to the same perf-test drift
  • bun run dev:server -- --dry-run — turbo accepts --filter=@berkayorhan/bcode
  • node apps/server/scripts/cli.ts publish --dry-run --tag latest --app-version 0.0.17 --verbose — tarball shows name: @berkayorhan/bcode, version: 0.0.17
  • CI green (once the perf-test drift follow-up lands)
  • Phase B manual prerequisites (enable Actions on fork, npm OIDC trusted publisher, classic-token fallback staged)
  • Phase C dry-run release at throwaway tag

- Drop schedule + nightly logic from release.yml; tag-only + workflow_dispatch
- Rename npm package t3 -> @berkayorhan/bcode (scoped, OIDC trusted publishing)
- Rename CLI binary t3 -> bcode
- Update turbo filters (--filter=t3 -> --filter=@berkayorhan/bcode) in package.json,
  release.yml, dev-runner.ts
Copilot AI review requested due to automatic review settings April 16, 2026 21:05
@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:L labels Apr 16, 2026
@Berkay2002 Berkay2002 merged commit 5803e5d into main Apr 16, 2026
10 of 11 checks passed
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Rewires the release pipeline to work for fork-owned publishing and completes the server package rename/re-scope needed to publish the CLI under the fork’s npm ownership.

Changes:

  • Update the GitHub release workflow to be tag-driven with a workflow_dispatch version input (no cron/nightly flow).
  • Rename apps/server npm package and CLI bin (t3@berkayorhan/bcode / bcode) and set publishConfig.access: public.
  • Update Turbo filters across dev runner, root scripts, and release workflow to target @berkayorhan/bcode.

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
.github/workflows/release.yml Removes nightly scheduling/channel input and updates build/publish flow for the renamed CLI package.
apps/server/package.json Renames/scopes the published package and CLI bin; sets publishConfig.access: public; updates repository URL.
package.json Updates Turbo filters in root scripts to point to the renamed server workspace.
scripts/dev-runner.ts Updates Turbo filters used by the dev runner to target the renamed server workspace.
bun.lock Updates workspace metadata (name/bin) and refreshes lock entries to reflect the rename.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +69 to +72
version="${raw#v}"
if [[ ! "$version" =~ ^[0-9]+\.[0-9]+\.[0-9]+([.-][0-9A-Za-z.-]+)?$ ]]; then
echo "Invalid release version: $raw" >&2
exit 1
Copy link

Copilot AI Apr 16, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The version validation regex here is inconsistent with scripts/resolve-previous-release-tag.ts’s parseStableTag().

  • This regex accepts versions like 1.2.3.foo (because of [.-]), but parseStableTag() only accepts prereleases prefixed with -, so the workflow would later fail when resolving previous_tag.
  • It also rejects valid SemVer build metadata (+build), which parseStableTag() explicitly supports.

Suggestion: align this check with the parseStableTag() pattern (allow optional -<prerelease> and optional +<build>), or reuse the same parsing/validation logic to avoid drift.

Copilot uses AI. Check for mistakes.
Berkay2002 added a commit that referenced this pull request Apr 17, 2026
- desktop main.ts:1412: write bcodeHome (not t3Home) to the bootstrap
  envelope so the server honors the desktop-selected base dir after the
  schema field rename.
- turbo.json: add BCODE_WEB_SOURCEMAP and T3CODE_WEB_SOURCEMAP to
  globalEnv so vite sourcemap changes invalidate turbo cache.
- build-desktop-artifact.ts: emit the one-time legacy-env deprecation
  warning for T3CODE_DESKTOP_UPDATE_REPOSITORY like the other shimmed
  reads.
- observability.md / KEYBINDINGS.md / debugging.md / scripts.md: revert
  hardcoded ~/.bcode/... paths to ~/.t3/... with a note about the
  upcoming home-dir flip. The runtime default is still ~/.t3 until PR #3
  lands the auto-migration, so user-facing docs must match the current
  on-disk reality. Env var name flips (BCODE_*) are retained since the
  shim honors both.
Berkay2002 added a commit that referenced this pull request Apr 17, 2026
…/Linux IDs (#9)

* feat(shared): add env dual-read shim (BCODE_* preferred, T3CODE_* fallback with warning)

* feat(rebrand): flip server CLI env vars via Effect Config shim

BCODE_* preferred with T3CODE_* fallback + per-key deprecation warning.
Rename bootstrap envelope field t3Home -> bcodeHome. Default
otlpServiceName flips from t3-server to bcode-server.

* feat(rebrand): flip desktop + scripts env readers to new names

Desktop app.ts, updateState, terminal Manager, perf harnesses, telemetry,
projectScripts, vite/web, dev-runner, build-desktop-artifact, mock-update
and misc tests move to BCODE_*. Scripts with user-facing env (dev-runner,
build-desktop-artifact) keep a BCODE_* preferred / T3CODE_* fallback shim
that warns once per legacy key. projectScriptRuntimeEnv writes both
prefixes so user-authored project scripts continue reading legacy names.
Terminal env strip filter now drops both BCODE_* and T3CODE_* keys.

* feat(rebrand): flip shell capture sentinels __T3CODE_* to __BCODE_*

Internal-only markers grep'd out of captured shell output. No persistence
or external interface, safe to flip without a legacy-name fallback.

* chore(rebrand): add BCODE_* keys to turbo globalEnv alongside T3CODE_*

Dual-listing matches the env var shim window: cache invalidation fires
when either prefix changes through v0.0.19. The T3CODE_* entries are
removed together with the shim in v0.0.20.

* feat(rebrand): rename desktop internal protocol scheme t3:// to bcode://

DESKTOP_SCHEME is an electron-internal asset protocol used for packaged
UI loading. No OS-level handler is registered via setAsDefaultProtocolClient,
so this flip has no external surface and needs no migration shim.

* feat(rebrand): rename COM/bundle ID to com.berkayorhan.bcode and artifactName to BCode-*

Flips APP_USER_MODEL_ID (Windows AUMID), APP_BUNDLE_ID (macOS plist patching
in the electron launcher), and the electron-builder appId + artifactName
pattern. Changes the installed-app identity on new installs; existing
installs continue to resolve their own identity via electron's userData
paths (deliberately kept under the legacy t3code name).

* feat(rebrand): rename Linux entry, WM class, and internal t3code identifiers to bcode

LINUX_DESKTOP_ENTRY_NAME, LINUX_WM_CLASS, executableName, StartupWMClass,
the dev-electron pkill marker arg, the packaged package.json name, the
temp stage dir prefixes, and the bcodeCommitHash metadata field all flip
to bcode. USER_DATA_DIR_NAME remains 't3code' deliberately (per AGENTS.md)
to preserve electron-managed state on existing installs.

* test(rebrand): flip release fixture artifact names T3-Code-* to BCode-*

Follows the commit 8 artifactName flip: update-manifest test fixtures
and release-smoke-test fixture URLs must match the new artifact naming
pattern or the tests fail on what's effectively stale hardcoded data.

* docs(rebrand): rewrite current docs for BCODE_*, bcode://, ~/.bcode

Updates observability, release, perf-benchmarks, quick-start, scripts,
KEYBINDINGS, and debugging rule docs to use the new env var names and
home directory. Adds an env var deprecation-window note at the top of
observability.md. Historical plans and specs are left untouched.

* docs(plan): add PR #2 execution breakdown

* test(rebrand): assert dual-prefix env keys in project setup script

The projectScriptRuntimeEnv helper writes both BCODE_* and T3CODE_*
aliases through v0.0.19 so user-authored project scripts keep reading
legacy names. The setup-script runner assertion must match that shape.
Other projectScripts/ChatView assertions already use toMatchObject
partial matching so they were unaffected.

* fix(rebrand): address Copilot review on PR #9

- desktop main.ts:1412: write bcodeHome (not t3Home) to the bootstrap
  envelope so the server honors the desktop-selected base dir after the
  schema field rename.
- turbo.json: add BCODE_WEB_SOURCEMAP and T3CODE_WEB_SOURCEMAP to
  globalEnv so vite sourcemap changes invalidate turbo cache.
- build-desktop-artifact.ts: emit the one-time legacy-env deprecation
  warning for T3CODE_DESKTOP_UPDATE_REPOSITORY like the other shimmed
  reads.
- observability.md / KEYBINDINGS.md / debugging.md / scripts.md: revert
  hardcoded ~/.bcode/... paths to ~/.t3/... with a note about the
  upcoming home-dir flip. The runtime default is still ~/.t3 until PR #3
  lands the auto-migration, so user-facing docs must match the current
  on-disk reality. Env var name flips (BCODE_*) are retained since the
  shim honors both.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants