Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
108 commits
Select commit Hold shift + click to select a range
42b8fdf
feat(web): codecast cross-platform builds
ashot Dec 4, 2026
d5c096e
feat(web): codecast IDE build
ashot Dec 4, 2026
94422b6
feat(web): public content CMS
ashot Dec 4, 2026
d73a829
feat(cli): CI and deploy speed
ashot Dec 4, 2026
42b7870
feat(web): restore call stage screens
ashot Dec 4, 2026
b6b3016
feat(web): folder picker redesign
ashot Dec 4, 2026
48a5103
feat(web): remove decision card ask feature
ashot Dec 4, 2026
d828448
feat(web): inline conversation references
ashot Dec 4, 2026
be90792
feat(web): blog posts to markdown
ashot Dec 4, 2026
d075bf8
feat(shared): codecast deploy orchestration
ashot Dec 4, 2026
ca9c334
feat(cli): ship main checkout
ashot Dec 4, 2026
6c61149
fix(convex): log error monitoring
ashot Dec 4, 2026
f576877
feat(mobile): call thread access
ashot Dec 4, 2026
63d7fac
feat(web): changes in web
ashot Dec 4, 2026
3ea3012
feat(web): layout persistence and DM badge
ashot Dec 4, 2026
1020fa1
feat(mobile): iOS attachment name and new session
ashot Dec 4, 2026
6c74e78
docs(web): slug list review
ashot Dec 4, 2026
fd4abd3
feat(web): precache linked objects
ashot Dec 4, 2026
ead7a7e
feat(electron): screen share border
ashot Dec 4, 2026
dae8cf8
fix(web): one-way call audio fix
ashot Dec 4, 2026
0dfb463
feat(web): blog post slug list
ashot Dec 4, 2026
101fecc
feat(web): presence status indicator
ashot Dec 4, 2026
7ccfa52
fix(convex): log error monitoring
ashot Dec 4, 2026
1f0eb68
feat(web): workflow row cleanup
ashot Dec 4, 2026
c65d721
docs(web): blog post slug ideas
ashot Dec 4, 2026
ce059f6
feat(web): inky branch pill labels
ashot Dec 4, 2026
b78c5a9
fix(web): removeChild crash fix
ashot Dec 4, 2026
0d5393b
feat(web): file column behavior
ashot Dec 4, 2026
e95c643
fix(web): store infra revoked-proxy fix
ashot Dec 4, 2026
53ba04f
feat(evals): decision card eval
ashot Dec 4, 2026
11489c2
feat(convex): private call indicators
ashot Dec 4, 2026
40fd355
fix(convex): log error monitoring
ashot Dec 4, 2026
e3e6130
feat(web): changes in web
ashot Dec 4, 2026
f89bd7a
fix(web): cmd-K channel search fix
ashot Dec 4, 2026
127cce4
feat(web): session card copy link
ashot Dec 4, 2026
b9bccc7
feat(web): call overlay pinning
ashot Dec 4, 2026
eb7945f
fix(.github): fix red CI on main
ashot Dec 4, 2026
de87e70
feat(docs): weekly agent comms measure
ashot Dec 4, 2026
10ca493
feat(cli): commit and deploy changes
ashot Dec 4, 2026
d904597
feat(cli): changes in cli
ashot Dec 4, 2026
3b2e416
fix(cli): log error triage
ashot Dec 4, 2026
1c57956
feat(cli): CMO org template
ashot Dec 4, 2026
84ebb16
fix(cli): log error monitoring
ashot Dec 4, 2026
848d8fa
fix(convex): log error triage
ashot Dec 4, 2026
c3996e4
feat(convex): daemon and prod log triage
ashot Dec 4, 2026
dd4f78f
feat(convex): changes in convex
ashot Dec 4, 2026
a422e44
fix(convex): log error monitoring
ashot Dec 4, 2026
998088a
fix(convex): log error monitoring
ashot Dec 4, 2026
189a82d
fix(shared): thread notification bug
ashot Dec 4, 2026
b698fbf
fix(web): chat search jump fix
ashot Dec 4, 2026
1845906
feat(web): fork composer UX redesign
ashot Dec 4, 2026
9e9a2c2
fix(web): bottom message highlight fix
ashot Dec 4, 2026
00cb705
feat(web): calls page cleanup
ashot Dec 4, 2026
dc7d94c
fix(web): decision inbox link fix
ashot Dec 4, 2026
2ca5bd0
feat(web): sidebar nav reorganization
ashot Dec 4, 2026
d5efb5e
feat(web): pinned drag reorder
ashot Dec 4, 2026
0eae28a
feat(web): call header privacy labels
ashot Dec 4, 2026
32a911c
feat(.codecast): worktree guidance gaps
ashot Dec 4, 2026
b7311c8
fix(cli): session move host fix
ashot Dec 4, 2026
4e15788
fix(cli): daemon and prod log errors
ashot Dec 4, 2026
d6dac9a
feat(cli): inbox tmp session cleanup
ashot Dec 4, 2026
8a6bd72
feat(cli): route out CLI prompts
ashot Dec 4, 2026
9080fbc
fix(cli): log error monitoring
ashot Dec 4, 2026
ba9b30e
feat(cli): chrome popup investigation
ashot Dec 4, 2026
7dda314
feat(convex): inky DM showing in Codecast
ashot Dec 4, 2026
bbb99d4
feat(convex): daemon and prod log triage
ashot Dec 4, 2026
3eb68c2
feat(convex): daemon and prod log monitoring
ashot Dec 4, 2026
be57e9b
feat(convex): recall.ai meeting bots
ashot Dec 4, 2026
8a2963b
fix(convex): daemon and prod log fixes
ashot Dec 4, 2026
a0797db
feat(convex): daemon and prod log triage
ashot Dec 4, 2026
354bef3
fix(convex): log error triage
ashot Dec 4, 2026
52a88b9
feat(convex): daemon and prod log monitoring
ashot Dec 4, 2026
7c0a113
fix(convex): daemon and Convex log fixes
ashot Dec 4, 2026
3640cae
fix(convex): log error monitoring
ashot Dec 4, 2026
560ae29
feat(convex): mobile flow context strip
ashot Dec 4, 2026
3e5604b
fix(web): stuck session delivery fix
ashot Dec 4, 2026
1603b4a
feat(web): disable ask feature
ashot Dec 4, 2026
4385d74
feat(web): deal ablation: minus-escalations
ashot Dec 4, 2026
ff2a007
feat(web): decision walkthrough fullscreen
ashot Dec 4, 2026
178dc4c
feat(web): restore inbox label pills
ashot Dec 4, 2026
1ebc282
fix(web): new session loading fix
ashot Dec 4, 2026
ddce35d
feat(web): sweep cl-250 for gaps
ashot Dec 4, 2026
de667e0
feat(web): MCP directory listings
ashot Dec 4, 2026
bf7ea4f
feat(.codecast): postHog metrics flows
ashot Dec 4, 2026
88fde06
docs(docs): weekly steering lessons
ashot Dec 4, 2026
b9b5d07
docs(docs): personal integrations design
ashot Dec 4, 2026
0ececad
fix(cli): fix red CLI CI
ashot Dec 4, 2026
17a8179
feat(convex): org people model redesign
ashot Dec 4, 2026
b119ac3
feat(convex): daemon and prod log triage
ashot Dec 4, 2026
12afe25
feat(web): call board article
ashot Dec 4, 2026
fb87bef
docs(web): weekly blog: Priorities
ashot Dec 4, 2026
e8b70e3
feat(web): changes in web
ashot Dec 4, 2026
6a50d07
feat(web): change flow article
ashot Dec 4, 2026
0e01ce2
feat(web): workflow header cleanup
ashot Dec 4, 2026
ca4a20e
feat(web): inbox scroll on send
ashot Dec 4, 2026
ceb00ab
fix(web): fix red CI on main
ashot Dec 4, 2026
4d5490b
feat(web): session triage state model
ashot Dec 4, 2026
f9446d9
feat(web): remove run rail row
ashot Dec 4, 2026
c873324
feat(web): font size mismatch
ashot Dec 4, 2026
a589a5b
feat(web): inky avatar icon
ashot Dec 4, 2026
67baf63
fix(web): session pill wrap fix
ashot Dec 4, 2026
8e586ec
feat(web): new session button spacing
ashot Dec 4, 2026
f608c6d
feat(web): sidebar unread styling
ashot Dec 4, 2026
1f0c01c
feat(web): precache inbox decisions
ashot Dec 4, 2026
674d2a8
feat(web): huddle button delay
ashot Dec 4, 2026
d4e889a
feat(cli): changes in cli
ashot Dec 4, 2026
23838ce
Keep main's board filter in the guest call view
ashot Dec 5, 2026
712a99f
Revert "Keep main's board filter in the guest call view"
ashot Dec 5, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
35 changes: 35 additions & 0 deletions .codecast/ci.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# codecast's own CI runner (`cast ci run <sha>`): what .github/workflows/ci.yml cannot say. The jobs, their steps,
# matrices and `if:` gates come from ci.yml itself, read for the push or pull_request event the run stands in for;
# this file adds only the host-side facts. Schema: packages/shared/contracts/ciConfig.ts.

repository = "codecast-sh/codecast"
name = "codecast-ci"
# A CI pool host (c8id.16xlarge, 64 vCPU / 128 GB) takes one run at a time; within it, job runners go sixteen at
# once, four cores each, each in a checkout of its own, as GitHub gives each job a runner of its own.
runs_per_host = 1
parallel_jobs = 16

# The pool has no job cap, so ci.yml's matrices run their wide set on a push too (ci.yml, typecheck's note).
[vars]
CI_WIDE = "true"

# Runner setup that needs root on GitHub's image: the pool's host image carries these tools already, and a slot user
# has no sudo.
[skip_steps]
"Install tmux" = "the CI host image has tmux"
"Install tmux (e2e tests need a real tmux server)" = "the CI host image has tmux"
"Allow the Electron sandbox, and a display for it" = "the CI host image has xvfb and allows unprivileged user namespaces"

# ci.yml needs no secrets and no services. Every job counts as ci.yml says: computer-macos is continue-on-error
# (advisory), and verify is the one check GitHub requires; it runs after every gated job and fails when any of them
# did not end as its gate said.

# Each test shard's JUnit report, beside its log: `scripts/ci/test-shards.ts --record` balances the shards from them.
[jobs.test-cli]
keep = ["$RUNNER_TEMP/junit.xml"]

[jobs.test-web]
keep = ["$RUNNER_TEMP/junit.xml"]

[jobs.test-convex]
keep = ["$RUNNER_TEMP/junit.xml"]
3 changes: 3 additions & 0 deletions .codecast/deploy.toml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@ live = "github-status:codecast - web"
name = "cli"
when = ["packages/cli/**", "packages/shared/**", "platform/**"]
unless = ["**/*.test.ts", "**/*.test.tsx", "**/*.test.js", "**/*.test.cjs", "**/*.test.mjs", "**/__tests__/**", "**/__fixtures__/**", "**/*.testkit.ts", "**/Tests/**"]
# GitHub Actions cuts it today. `scripts/cut-cli-release.sh --runner codecast` cuts it on codecast's own machines
# (the signing Mac and a Linux CI host, gated on codecast's own CI verdict): switch this line to it once codecast's CI
# records main's verdicts and the signing certificate is on the signing Mac (pl-1157, ct-103165).
run = "scripts/cut-cli-release.sh"
live = "json:https://dl.codecast.sh/latest.json#sourceCommit,version"
policy = "release"
Expand Down
6 changes: 6 additions & 0 deletions .codecast/flows/codecast-fix.cast
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// Codecast's live flow (sd-3248, 2026-11-14): the Standard line as it ships,
// under its own name so the team can make it live. It changes no station;
// extending keeps it on the shipped line as that line improves.
digraph codecast_fix {
graph [extends="line", label="Codecast fix"]
}
40 changes: 40 additions & 0 deletions .codecast/release/cut.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# The CLI release's macOS half on codecast's own machines: `cast ci run <sha> --workflow
# .github/workflows/cut-cli-release.yml --config .codecast/release/cut.toml --os darwin --unsandboxed`, started by
# scripts/cut-cli-release.sh on the signing Mac. The workflow is the one GitHub ran; this file says what a Mac that is
# not a throwaway runner provides. Schema: packages/shared/contracts/ciConfig.ts. A dispatched run is never recorded
# as the commit's CI.

repository = "codecast-sh/codecast"
name = "codecast-release-cut"
workflow = ".github/workflows/cut-cli-release.yml"

# The workflow leaves finalize to the driver here, and restores the keychain settings it changes.
[vars]
CLI_RELEASE_RUNNER = "codecast"

# The signing identity, only for the job that signs. Where these live is decided in sd-5228; the names are the vault's.
[secrets.MACOS_SIGN_CERT_P12]
vault = "cli-release-sign-cert-p12"
jobs = ["build"]

[secrets.MACOS_SIGN_CERT_PASSPHRASE]
vault = "cli-release-sign-cert-passphrase"
jobs = ["build"]

# The staging upload (the builder's five objects, which finalize checks against the manifest).
[secrets.R2_ACCESS_KEY_ID]
vault = "cli-release-r2-access-key-id"
jobs = ["build"]

[secrets.R2_SECRET_ACCESS_KEY]
vault = "cli-release-r2-secret-access-key"
jobs = ["build"]

[secrets.R2_ENDPOINT]
vault = "r2-endpoint"
jobs = ["build"]

# What the driver hands finalize: the builder's manifest and when its uploads began.
[jobs.build]
os = "darwin"
keep = ["$RUNNER_TEMP/release-manifest.json", "$RUNNER_TEMP/uploaded-after"]
43 changes: 43 additions & 0 deletions .codecast/release/finalize.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# The CLI release's publishing half on codecast's own machines: `cast ci run <sha> --workflow
# .github/workflows/finalize-cli-release.yml --config .codecast/release/finalize.toml` on a Linux CI pool host, started
# by scripts/cut-cli-release.sh once the macOS half is green. Its CI gate is codecast's own verdict (the driver hands it
# in as ci_verdict). Schema: packages/shared/contracts/ciConfig.ts. A dispatched run is never recorded as CI.

repository = "codecast-sh/codecast"
name = "codecast-release-finalize"
workflow = ".github/workflows/finalize-cli-release.yml"

[vars]
CLI_RELEASE_RUNNER = "codecast"

# The codecast GitHub App (2712850) on codecast-sh (installation 105761679): contents write, for the version commit,
# the tag and the GitHub release. Minted per run, an hour long; the key never reaches the job.
[secrets.GITHUB_APP_PRIVATE_KEY]
vault = "github-app-private-key"
jobs = []

[secrets.GITHUB_TOKEN]
github_app = { id = 2712850, installation = 105761679, key_secret = "GITHUB_APP_PRIVATE_KEY" } # ggignore: names another secret entry, holds no value
jobs = ["finalize"]

[secrets.R2_ACCESS_KEY_ID]
vault = "cli-release-r2-access-key-id"
jobs = ["finalize"]

[secrets.R2_SECRET_ACCESS_KEY]
vault = "cli-release-r2-secret-access-key"
jobs = ["finalize"]

[secrets.R2_ENDPOINT]
vault = "r2-endpoint"
jobs = ["finalize"]

# The Ed25519 key latest.json is signed with (docs/architecture/release-signing.md). Where it lives is decided in
# sd-5228; the names are the vault's.
[secrets.RELEASE_MANIFEST_SIGNING_KEY]
vault = "cli-release-manifest-signing-key"
jobs = ["finalize"]

[secrets.RELEASE_MANIFEST_KEY_ID]
vault = "cli-release-manifest-key-id"
jobs = ["finalize"]
3 changes: 2 additions & 1 deletion .codecast/workspace.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@
# Schema: https://codecast.sh/docs/workspace

[setup]
# Gitignored secrets/config a worktree needs to actually run web + convex + cli.
# Gitignored secrets/config a worktree needs to actually run web, convex, cli and mobile.
# (git worktrees do not inherit these — they live outside version control.)
copy = [
".env",
".env.local",
"packages/convex/.env.local",
"packages/web/.env.local",
"packages/cli/.env.local",
"packages/mobile/.env",
]
# A fresh worktree has its own (empty) node_modules — bun doesn't share them
# across worktrees, so install once on creation. If this fails, the daemon
Expand Down
70 changes: 52 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,16 +197,21 @@ jobs:
if: needs.code_paths.outputs.run_typecheck == 'true'
runs-on: ubuntu-latest
timeout-minutes: 20
# The programs in .codecast/check.toml over three jobs of about equal
# cold time (web alone, ~200s; the others pair up below it). mobile is
# left out: `cast check mobile` is its only check (see the contract test).
# The programs in .codecast/check.toml. A push to main checks them all in
# one job: its build info is never more than a push old, so the job takes
# about a minute. A pull request may start further from main, so it spreads
# them over three jobs of about equal cold time (web alone, ~200s). The
# free plan runs 20 jobs at once for the whole repository, and a wide
# matrix on every push to main left whole runs queued behind each other.
# A runner with no such cap sets the repository variable CI_WIDE to true
# (codecast's own pool, in .codecast/ci.toml [vars]) and runs the wide set
# on a push as well; every matrix below follows the same rule.
# mobile is left out: `cast check mobile` is its only check (see the
# contract test).
strategy:
fail-fast: false
matrix:
include:
- { key: web, programs: web }
- { key: cli-evals, programs: cli evals }
- { key: convex-sim-playground, programs: convex sim playground }
include: ${{ fromJSON(github.event_name == 'push' && vars.CI_WIDE != 'true' && '[{"key":"all","programs":"web cli evals convex sim playground"}]' || '[{"key":"web","programs":"web"},{"key":"cli-evals","programs":"cli evals"},{"key":"convex-sim-playground","programs":"convex sim playground"}]') }}
name: typecheck (${{ matrix.programs }})
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
Expand All @@ -223,13 +228,18 @@ jobs:
with:
path: ${{ runner.temp }}/tsbuildinfo
key: tsbuildinfo-${{ matrix.key }}-${{ github.sha }}
restore-keys: tsbuildinfo-${{ matrix.key }}-
# main saves the whole set under "all"; a pull request's group starts from it.
restore-keys: |
tsbuildinfo-all-
tsbuildinfo-${{ matrix.key }}-

- name: Typecheck
# web's program outgrew V8's default ~4 GB heap: on 2026-11-08 its tsc
# died in GC at 4029 MB (exit 134).
# died in GC at 4029 MB (exit 134). A 64 MB young generation (V8's
# default is 16) scavenges less: web's cold check 176s -> 164s on a
# pool runner's four cores.
env:
NODE_OPTIONS: --max-old-space-size=6144
NODE_OPTIONS: --max-old-space-size=6144 --max-semi-space-size=64
# Each program's tsconfig is the one .codecast/check.toml names for it.
run: |
status=0
Expand Down Expand Up @@ -285,14 +295,35 @@ jobs:
if: needs.code_paths.outputs.run_test_convex == 'true'
runs-on: ubuntu-latest
timeout-minutes: 20
# One process for the whole suite on GitHub; a runner with no job cap
# (CI_WIDE, see typecheck) splits it by recorded time.
strategy:
fail-fast: false
matrix:
shard: ${{ fromJSON(vars.CI_WIDE == 'true' && '["1/3","2/3","3/3"]' || '["1/1"]') }}
name: test-convex (${{ matrix.shard }})
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4

- uses: ./.github/actions/setup-bun

- name: Unit tests (convex package)
working-directory: packages/convex
run: bun test convex/ scripts/
# Each shard is one serial process, as the whole suite was: under
# --parallel a test that depended on its neighbours' order failed.
run: |
files="$(bun ../../scripts/ci/test-shards.ts packages/convex ${{ matrix.shard }})"
# shellcheck disable=SC2086 # one argument per file
bun test --reporter=junit --reporter-outfile=${{ runner.temp }}/junit.xml $files

- name: Upload test timings
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
with:
name: junit-convex-${{ strategy.job-index }}
path: ${{ runner.temp }}/junit.xml
if-no-files-found: ignore
retention-days: 7

test-web:
needs: [code_paths]
Expand All @@ -306,8 +337,9 @@ jobs:
strategy:
fail-fast: false
matrix:
shard: [1, 2, 3, 4]
name: test-web (${{ matrix.shard }}/4)
# Two shards on a push to main, four on a pull request (see typecheck).
shard: ${{ fromJSON(github.event_name == 'push' && vars.CI_WIDE != 'true' && '["1/2","2/2"]' || '["1/4","2/4","3/4","4/4"]') }}
name: test-web (${{ matrix.shard }})
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4

Expand All @@ -325,22 +357,22 @@ jobs:
env:
SIM_OUT: ${{ runner.temp }}/sim
run: |
files="$(bun ../../scripts/ci/test-shards.ts packages/web ${{ matrix.shard }}/4)"
files="$(bun ../../scripts/ci/test-shards.ts packages/web ${{ matrix.shard }})"
# shellcheck disable=SC2086 # one argument per file
bun test --parallel --reporter=junit --reporter-outfile=${{ runner.temp }}/junit.xml $files

# The exact counts behind the perf benches (packages/web/perf/README.md).
# Plain bun, not bun test: the test preload stands in for the diff viewer.
- name: Perf budgets (web)
if: matrix.shard == 1
if: startsWith(matrix.shard, '1/')
working-directory: packages/web
run: scripts/perf-budgets.sh

- name: Upload test timings
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
with:
name: junit-web-${{ matrix.shard }}
name: junit-web-${{ strategy.job-index }}
path: ${{ runner.temp }}/junit.xml
if-no-files-found: ignore
retention-days: 7
Expand All @@ -349,7 +381,7 @@ jobs:
if: failure()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
with:
name: sim-artifacts-${{ matrix.shard }}
name: sim-artifacts-${{ strategy.job-index }}
path: ${{ runner.temp }}/sim
if-no-files-found: ignore
retention-days: 14
Expand All @@ -364,7 +396,9 @@ jobs:
strategy:
fail-fast: false
matrix:
part: ["1/3", "2/3", "3/3", "e2e"]
# Fewer unit shards on a push to main than on a pull request (see
# typecheck), and more on a runner with no job cap (CI_WIDE).
part: ${{ fromJSON(vars.CI_WIDE == 'true' && '["1/4","2/4","3/4","4/4","e2e"]' || github.event_name == 'push' && '["1/2","2/2","e2e"]' || '["1/3","2/3","3/3","e2e"]') }}
name: test-cli (${{ matrix.part }})
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
Expand Down
30 changes: 29 additions & 1 deletion .github/workflows/cut-cli-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ name: Cut signed CLI release
#
# Not covered here: npm publish and the Homebrew tap. Those remain laptop-only
# mirrors in packages/cli/scripts/deploy.sh.
#
# The same workflow runs on codecast's own machines (`cast ci run --workflow`,
# started by scripts/cut-cli-release.sh with vars.CLI_RELEASE_RUNNER=codecast,
# .codecast/release/cut.toml): on a Mac that is not a throwaway VM. There the
# driver, not this job, starts finalize, and every keychain change below is
# undone when the job ends.

on:
workflow_dispatch:
Expand Down Expand Up @@ -126,6 +132,9 @@ jobs:
cert="$RUNNER_TEMP/codecast-sign.p12"
printf '%s' "$CERT_P12_BASE64" | base64 --decode > "$cert"

# A Mac that outlives the job (codecast's signing Mac) gets its search
# list back when the keychain is removed.
security list-keychains -d user | tr -d '"' | xargs > "$RUNNER_TEMP/keychains-before"
security create-keychain -p "$keychain_password" "$keychain"
security set-keychain-settings -lut 5400 "$keychain"
security unlock-keychain -p "$keychain_password" "$keychain"
Expand Down Expand Up @@ -163,6 +172,10 @@ jobs:
if [[ -n "${SIGN_KEYCHAIN:-}" && -f "$SIGN_KEYCHAIN" ]]; then
security delete-keychain "$SIGN_KEYCHAIN"
fi
if [[ -s "$RUNNER_TEMP/keychains-before" ]]; then
# shellcheck disable=SC2046
security list-keychains -d user -s $(cat "$RUNNER_TEMP/keychains-before")
fi

- name: Verify the signatures and embedded version
shell: bash
Expand Down Expand Up @@ -210,6 +223,10 @@ jobs:
cd packages/cli
bun test src/browser/appIdentity.test.ts src/browser/appIdentity.native.test.ts --timeout 30000
browser_keychain="$RUNNER_TEMP/browser-test.keychain-db"
# The test swaps the user's default keychain and search list; a Mac
# that outlives the job gets both back in the removal step.
security default-keychain -d user | tr -d '" ' > "$RUNNER_TEMP/default-keychain-before"
security list-keychains -d user | tr -d '"' | xargs > "$RUNNER_TEMP/browser-keychains-before"
security create-keychain -p '' "$browser_keychain"
security unlock-keychain -p '' "$browser_keychain"
security default-keychain -d user -s "$browser_keychain"
Expand Down Expand Up @@ -268,6 +285,13 @@ jobs:
if: always()
shell: bash
run: |
if [[ -s "$RUNNER_TEMP/default-keychain-before" ]]; then
security default-keychain -d user -s "$(cat "$RUNNER_TEMP/default-keychain-before")"
fi
if [[ -s "$RUNNER_TEMP/browser-keychains-before" ]]; then
# shellcheck disable=SC2046
security list-keychains -d user -s $(cat "$RUNNER_TEMP/browser-keychains-before")
fi
if [[ -f "$RUNNER_TEMP/browser-test.keychain-db" ]]; then
security delete-keychain "$RUNNER_TEMP/browser-test.keychain-db"
fi
Expand Down Expand Up @@ -351,6 +375,8 @@ jobs:
# cutoff second.
uploaded_after=$(date -u +%Y-%m-%dT%H:%M:%SZ)
echo "UPLOADED_AFTER=$uploaded_after" >> "$GITHUB_ENV"
# Finalize's input when codecast's driver starts it (it reads the job's kept files).
echo "$uploaded_after" > "$RUNNER_TEMP/uploaded-after"
sleep 2
cd packages/web/binaries
for artifact in \
Expand All @@ -365,8 +391,10 @@ jobs:
--no-progress
done

# On codecast's machines the driver starts finalize itself, once this job
# is green, from the manifest and upload time the job kept.
- name: Dispatch the finalize workflow
if: ${{ !inputs.dry_run }}
if: ${{ !inputs.dry_run && vars.CLI_RELEASE_RUNNER != 'codecast' }}
env:
GH_TOKEN: ${{ github.token }}
shell: bash
Expand Down
Loading
Loading