Files
software-mansion__argent/package.json
T
Juliusz Wajgelt b90970ffa8 ci: ship TCP-transport iOS binaries in the published package (#487)
## Why

argent's `ios-remote` (sim-remote) support drives **ax-service** and
**native-devtools** over a TCP socket, resolving them from
`bin/darwin/tcp/ax-service` and `dylibs/tcp/*.dylib`. `bundle-tools.cjs`
already stages those into the published package **when present**, but
`download-native-binaries.sh` never fetched them — so
`@swmansion/argent` 0.15.0 shipped with no TCP variant at all, and every
`ios-remote` `describe` / `native-*` call failed with "not found".

## What

- **`download-native-binaries.sh`** — fetch the TCP dylibs tarball into
`dylibs/tcp/` and `tcp-ax-service` into `bin/darwin/tcp/ax-service`
(best-effort: skipped with a warning on pre-sim-remote release tags),
with the same Mach-O platform + codesign verification applied to the
iOS/tvOS assets.
- **`publish.yml` / `publish-next.yml`** — hard `test -x`/`test -f`
gates for the four TCP files so a missing build fails the publish loudly
instead of silently regressing (mirrors the existing tvOS gates).
- **`package.json`** — add `build:ios-binaries:tcp` and wire it into
`pack:mcp:local` so local packs match CI.

`bundle-tools.cjs` needs no change — its `ax-service (tcp)` asset entry
and recursive `dylibs/` copy already handle the `tcp/` slot.

## Verified locally

- `npm pack --dry-run -w @swmansion/argent` now lists
`bin/darwin/tcp/ax-service` +
`dylibs/tcp/{libArgentInjectionBootstrap,libKeyboardPatch,libNativeDevtoolsIos}.dylib`.
- `package-manifest.test.ts` (download↔bundle-tools path agreement) and
`native-devtools-ios/index.test.ts` (TCP path resolution) pass.
- End-to-end against a real sim-remote device: with the TCP binaries in
place, `describe` returns the full ax tree and `native-describe-screen`
/ `native-find-views` / `native-full-hierarchy` all return `status: ok`.

## Paired PR

The producer side — the workflow that builds, signs, and uploads these
TCP release assets — is **software-mansion/argent-private#26**. Both
must land for a release to ship the TCP binaries.

## Known follow-up (out of scope here)

`axServiceBinaryPathTcp()` resolves
`bin/<hostPlatformKey()>/tcp/ax-service`, and `bundle-tools.cjs` stages
the TCP ax-service **darwin-only**. So `describe` via ios-remote works
from a macOS argent host (verified), but a **Linux** host would hit "not
found" at `bin/linux/tcp/`. The TCP dylibs are fine cross-host (flat
`dylibs/tcp/`, un-gated). Full Linux-host support means staging the
darwin TCP ax-service into each host's `tcp/` dir, modeled on the
per-platform `simulator-server` loop — left as a follow-up.
2026-07-10 12:42:47 +02:00

37 lines
1.8 KiB
JSON

{
"name": "argent-workspace",
"private": true,
"workspaces": [
"packages/*"
],
"scripts": {
"build": "tsc --build",
"start": "npm run build -w @argent/registry && npm run dev -w @argent/tool-server",
"start:tool-server": "npm run build -w @argent/registry && npm run dev -w @argent/tool-server",
"download:simulator-server": "bash scripts/download-simulator-server.sh",
"download:native-binaries": "bash scripts/download-native-binaries.sh",
"download:trace-processor": "bash scripts/download-trace-processor.sh",
"build:ios-binaries": "bash packages/native-devtools-ios/scripts/build.sh dev",
"build:ios-binaries:tcp": "bash packages/native-devtools-ios/scripts/build.sh dev --transport tcp",
"build:android-binaries": "bash packages/native-devtools-android/scripts/build.sh",
"pack": "node scripts/pack-mcp.cjs",
"pack:mcp": "node scripts/pack-mcp.cjs",
"pack:mcp:local": "npm run download:simulator-server && npm run build:ios-binaries && npm run build:ios-binaries:tcp && npm run build:android-binaries && npm run download:trace-processor && npm run build && npm run build -w @swmansion/argent && npm pack -w @swmansion/argent --pack-destination .",
"dev": "node scripts/dev.cjs",
"format": "prettier --write .",
"lint": "eslint . --max-warnings 0",
"lint:fix": "eslint . --fix",
"typecheck:scripts": "tsc --noEmit -p tsconfig.scripts.json",
"test:scripts": "node --test scripts/sync-next-dist-tag.test.mjs scripts/next-canary-version.test.mjs",
"check:versions": "node scripts/check-workspace-versions.mjs"
},
"devDependencies": {
"@eslint/js": "^10.0.1",
"eslint": "^10.5.0",
"globals": "^17.7.0",
"prettier": "^3.8.5",
"semver": "^7.8.5",
"typescript-eslint": "^8.62.0"
}
}