Compare commits
84 commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 6d14eda8cc | |||
| af61adb9d1 | |||
| 73e4614b34 | |||
| 108b362cd9 | |||
| 5cc3da486d | |||
| 7e362ef962 | |||
| c1bed9440e | |||
| 793c322f99 | |||
| ab97d6d72f | |||
| c5173e4cae | |||
| f637c5e4e7 | |||
| 3a22d7f455 | |||
| 96458bba5c | |||
| b361e22631 | |||
| b18d480d65 | |||
| f6f9fc3c41 | |||
| 8573c9f6ae | |||
| 1ce4f026e9 | |||
| 73a962fbdc | |||
| b1043f5d79 | |||
| 01ea264a21 | |||
| ec381e8664 | |||
| f34192b546 | |||
| d71368e886 | |||
| 07052cffd2 | |||
| b82becf7fb | |||
| 9081ac921d | |||
| 9c001d1ca9 | |||
| 83d351cf42 | |||
| d05294ebcd | |||
| 36ef9c2c5c | |||
| 0950ef2c99 | |||
| 31f863ed06 | |||
| 64cb16e337 | |||
| 700fcc4d66 | |||
| f1a9229cf9 | |||
| 68467ffe9b | |||
| d88ed3ec55 | |||
| 1e47c2ee60 | |||
| 53d57544bf | |||
| d0f568ebc2 | |||
| cdd9321794 | |||
| 3a8d9d7551 | |||
| f5da7c9f7a | |||
| b1f1b206d3 | |||
| 4b6c28aff2 | |||
| a850ba6670 | |||
| 152e40fb8a | |||
| 724f5b9763 | |||
| 064a708fdb | |||
| 9b0cc0bf10 | |||
| 1abd0936c3 | |||
| e185b61c8e | |||
| edbcdad15d | |||
| 1c64320b65 | |||
| 6ebb656018 | |||
| f5296cc9e9 | |||
| ab69ce020c | |||
| 0ea7292164 | |||
| 02435de966 | |||
| 96ec7ba60f | |||
| 17f57c6fb6 | |||
| 3b1c6160b5 | |||
| 9620768897 | |||
| c500866295 | |||
| 398d8cd375 | |||
| a108aae53f | |||
| 164ba390dd | |||
| f2d7beb7ce | |||
| 8068993917 | |||
| 5f73fcbcf4 | |||
| 28a50e7d2e | |||
| 9a878d6562 | |||
| ef80cd2760 | |||
| bf95ee55c4 | |||
| 2dc20b61de | |||
| f64f125de6 | |||
| 5f2e03dc7d | |||
| 85cf494c0a | |||
| 4763862178 | |||
| 3dc3104bbc | |||
| 0858f4e538 | |||
| efa9503a50 | |||
| f109c519ae |
133 changed files with 5850 additions and 428 deletions
|
|
@ -9,7 +9,7 @@
|
||||||
"name": "storebound",
|
"name": "storebound",
|
||||||
"source": ".",
|
"source": ".",
|
||||||
"description": "Take a mobile app or game from nothing to Submit for review on both stores: skills for every store step and questionnaire plus the storebound CLI and MCP server.",
|
"description": "Take a mobile app or game from nothing to Submit for review on both stores: skills for every store step and questionnaire plus the storebound CLI and MCP server.",
|
||||||
"version": "0.8.53",
|
"version": "0.8.78",
|
||||||
"category": "development",
|
"category": "development",
|
||||||
"tags": [
|
"tags": [
|
||||||
"mobile",
|
"mobile",
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "storebound",
|
"name": "storebound",
|
||||||
"version": "0.8.53",
|
"version": "0.8.78",
|
||||||
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every questionnaire (Data safety, App access and demo accounts, account deletion, IARC, target audience, ads, App Privacy, age rating, export compliance), privacy, icons, screenshots and previews, validate, TestFlight, release management, and after launch: crash vitals, review replies, price sheets, store analytics, Product Page Optimization. Agent Skills plus a Bun CLI and MCP server (storebound); you press Submit. CRTkafa's own toolchain, open-sourced.",
|
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every questionnaire (Data safety, App access and demo accounts, account deletion, IARC, target audience, ads, App Privacy, age rating, export compliance), privacy, icons, screenshots and previews, validate, TestFlight, release management, and after launch: crash vitals, review replies, price sheets, store analytics, Product Page Optimization. Agent Skills plus a Bun CLI and MCP server (storebound); you press Submit. CRTkafa's own toolchain, open-sourced.",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "CRTkafa"
|
"name": "CRTkafa"
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "storebound",
|
"name": "storebound",
|
||||||
"version": "0.8.53",
|
"version": "0.8.78",
|
||||||
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every questionnaire (Data safety, App access and demo accounts, account deletion, IARC, target audience, ads, App Privacy, age rating, export compliance), privacy, icons, screenshots and previews, validate, TestFlight, release management, and after launch: crash vitals, review replies, price sheets, store analytics, Product Page Optimization. Agent Skills plus a Bun CLI and MCP server (storebound); you press Submit. CRTkafa's own toolchain, open-sourced.",
|
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every questionnaire (Data safety, App access and demo accounts, account deletion, IARC, target audience, ads, App Privacy, age rating, export compliance), privacy, icons, screenshots and previews, validate, TestFlight, release management, and after launch: crash vitals, review replies, price sheets, store analytics, Product Page Optimization. Agent Skills plus a Bun CLI and MCP server (storebound); you press Submit. CRTkafa's own toolchain, open-sourced.",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "CRTkafa"
|
"name": "CRTkafa"
|
||||||
|
|
|
||||||
|
|
@ -26,6 +26,7 @@ runs:
|
||||||
with:
|
with:
|
||||||
path: |
|
path: |
|
||||||
~/.bun/install/cache
|
~/.bun/install/cache
|
||||||
|
~/.cache/tauri
|
||||||
~/.cargo/registry/index
|
~/.cargo/registry/index
|
||||||
~/.cargo/registry/cache
|
~/.cargo/registry/cache
|
||||||
~/.cargo/git/db
|
~/.cargo/git/db
|
||||||
|
|
@ -35,7 +36,7 @@ runs:
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
P="${FORGEJO_PATH:-$GITHUB_PATH}"
|
P="${FORGEJO_PATH:-$GITHUB_PATH}"
|
||||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
bash tools/ci-install-bun.sh
|
||||||
echo "$HOME/.bun/bin" >> "$P"
|
echo "$HOME/.bun/bin" >> "$P"
|
||||||
command -v rustup || curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal
|
command -v rustup || curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal
|
||||||
echo "$HOME/.cargo/bin" >> "$P"
|
echo "$HOME/.cargo/bin" >> "$P"
|
||||||
|
|
|
||||||
|
|
@ -33,7 +33,7 @@ jobs:
|
||||||
if: ${{ matrix.platform == 'Linux' }}
|
if: ${{ matrix.platform == 'Linux' }}
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
bash tools/ci-install-bun.sh
|
||||||
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
||||||
- name: Acceptance matrix (Linux)
|
- name: Acceptance matrix (Linux)
|
||||||
if: ${{ matrix.platform == 'Linux' }}
|
if: ${{ matrix.platform == 'Linux' }}
|
||||||
|
|
@ -97,7 +97,7 @@ jobs:
|
||||||
path: acceptance-runs/Windows-bun
|
path: acceptance-runs/Windows-bun
|
||||||
- name: Matrix (markdown), red cells fail the job
|
- name: Matrix (markdown), red cells fail the job
|
||||||
run: |
|
run: |
|
||||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
bash tools/ci-install-bun.sh
|
||||||
export PATH="$HOME/.bun/bin:$PATH"
|
export PATH="$HOME/.bun/bin:$PATH"
|
||||||
V=$(bun tools/desktop-version.ts --print)
|
V=$(bun tools/desktop-version.ts --print)
|
||||||
mkdir -p out
|
mkdir -p out
|
||||||
|
|
|
||||||
|
|
@ -102,7 +102,7 @@ jobs:
|
||||||
if: ${{ matrix.platform == 'Linux' }}
|
if: ${{ matrix.platform == 'Linux' }}
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
bash tools/ci-install-bun.sh
|
||||||
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
||||||
- name: Acceptance matrix (Linux)
|
- name: Acceptance matrix (Linux)
|
||||||
if: ${{ matrix.platform == 'Linux' }}
|
if: ${{ matrix.platform == 'Linux' }}
|
||||||
|
|
@ -173,7 +173,9 @@ jobs:
|
||||||
working-directory: apps/desktop
|
working-directory: apps/desktop
|
||||||
run: |
|
run: |
|
||||||
rm -rf "$CARGO_TARGET_DIR/release/bundle"
|
rm -rf "$CARGO_TARGET_DIR/release/bundle"
|
||||||
bun ../../tools/desktop-release.ts exec -- bunx tauri build --bundles appimage,deb --ci
|
# the AppImage tools come from GitHub releases, which answer 504 now and then (cached in ~/.cache/tauri)
|
||||||
|
bash ../../tools/ci-tauri-tools.sh
|
||||||
|
for i in 1 2 3; do bun ../../tools/desktop-release.ts exec -- bunx tauri build --bundles appimage,deb --ci && break; [ $i = 3 ] && exit 1; sleep 30; done
|
||||||
- name: Self-test the exact artifacts
|
- name: Self-test the exact artifacts
|
||||||
run: |
|
run: |
|
||||||
V=$(bun tools/desktop-version.ts --print)
|
V=$(bun tools/desktop-version.ts --print)
|
||||||
|
|
@ -237,7 +239,8 @@ jobs:
|
||||||
bun tools/build-sidecars.ts --target bun-linux-x64
|
bun tools/build-sidecars.ts --target bun-linux-x64
|
||||||
patchelf --set-rpath '$ORIGIN/../lib' apps/desktop/src-tauri/binaries/storebound-x86_64-unknown-linux-gnu
|
patchelf --set-rpath '$ORIGIN/../lib' apps/desktop/src-tauri/binaries/storebound-x86_64-unknown-linux-gnu
|
||||||
B="$CARGO_TARGET_DIR/release/bundle"; rm -rf "$B"
|
B="$CARGO_TARGET_DIR/release/bundle"; rm -rf "$B"
|
||||||
(cd apps/desktop && bun ../../tools/desktop-release.ts exec -- bunx tauri build --bundles appimage,deb --ci)
|
bash tools/ci-tauri-tools.sh
|
||||||
|
for i in 1 2 3; do (cd apps/desktop && bun ../../tools/desktop-release.ts exec -- bunx tauri build --bundles appimage,deb --ci) && break; [ $i = 3 ] && exit 1; sleep 30; done
|
||||||
mkdir -p dev && cp "$B/appimage/storebound_${V}_amd64.AppImage" "$B/deb/storebound_${V}_amd64.deb" dev/
|
mkdir -p dev && cp "$B/appimage/storebound_${V}_amd64.AppImage" "$B/deb/storebound_${V}_amd64.deb" dev/
|
||||||
chmod +x dev/*.AppImage
|
chmod +x dev/*.AppImage
|
||||||
(cd /tmp && rm -rf squashfs-root && "$GITHUB_WORKSPACE/dev/storebound_${V}_amd64.AppImage" --appimage-extract >/dev/null && squashfs-root/usr/bin/storebound-desktop --self-test)
|
(cd /tmp && rm -rf squashfs-root && "$GITHUB_WORKSPACE/dev/storebound_${V}_amd64.AppImage" --appimage-extract >/dev/null && squashfs-root/usr/bin/storebound-desktop --self-test)
|
||||||
|
|
@ -371,7 +374,7 @@ jobs:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- name: Tools
|
- name: Tools
|
||||||
run: |
|
run: |
|
||||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
bash tools/ci-install-bun.sh
|
||||||
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
|
|
@ -406,7 +409,7 @@ jobs:
|
||||||
# no apt: the installers were scanned with the private terms in their own jobs; this job only records
|
# no apt: the installers were scanned with the private terms in their own jobs; this job only records
|
||||||
- name: Tools
|
- name: Tools
|
||||||
run: |
|
run: |
|
||||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
bash tools/ci-install-bun.sh
|
||||||
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
||||||
[ -n "$FORGEJO_TOKEN" ] || { echo "secret RELEASE_TOKEN is missing (repo Settings > Actions > Secrets)" >&2; exit 1; }
|
[ -n "$FORGEJO_TOKEN" ] || { echo "secret RELEASE_TOKEN is missing (repo Settings > Actions > Secrets)" >&2; exit 1; }
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ jobs:
|
||||||
- name: Tag, package.json version, every version copy and the CHANGELOG agree
|
- name: Tag, package.json version, every version copy and the CHANGELOG agree
|
||||||
id: check
|
id: check
|
||||||
run: |
|
run: |
|
||||||
curl -fsSL https://bun.sh/install | bash -s "bun-v${BUN_VERSION}" >/dev/null
|
bash tools/ci-install-bun.sh
|
||||||
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
echo "$HOME/.bun/bin" >> "${FORGEJO_PATH:-$GITHUB_PATH}"
|
||||||
export PATH="$HOME/.bun/bin:$PATH"
|
export PATH="$HOME/.bun/bin:$PATH"
|
||||||
bun tools/desktop-version.ts
|
bun tools/desktop-version.ts
|
||||||
|
|
|
||||||
117
CHANGELOG.md
117
CHANGELOG.md
|
|
@ -3,6 +3,123 @@
|
||||||
|
|
||||||
## Unreleased
|
## Unreleased
|
||||||
|
|
||||||
|
## 0.8.78 · 2026-11-16
|
||||||
|
|
||||||
|
- **apple build:** the device-family stop prints short `fix:` lines first (e.g. `fix: apple.ipad: true in storebound.config.ts`); a test proves a stopped build exits non-zero through the ship-step path.
|
||||||
|
|
||||||
|
## 0.8.77 · 2026-11-08
|
||||||
|
|
||||||
|
- **iPhone Duo:** outer and inner files are no longer cut to the first 10: the limit comes from Apple's reference data, and over it nothing changes and nothing is dropped. `apple screenshots --duo-only` writes only the Duo set. `apple cpp` no longer lists creative-assets flags.
|
||||||
|
|
||||||
|
## 0.8.76 · 2026-11-08
|
||||||
|
|
||||||
|
- 0.8.75 was tagged but not published (GitHub 502/504 in the Linux AppImage bundling). CI now takes the AppImage tools from a checked mirror instead of GitHub.
|
||||||
|
|
||||||
|
## 0.8.75 · 2026-11-08
|
||||||
|
|
||||||
|
- 0.8.74 was tagged but not published (GitHub release downloads answered 504 during the Linux AppImage bundling); 0.8.75 ships its section.
|
||||||
|
|
||||||
|
## 0.8.74 · 2026-11-08
|
||||||
|
|
||||||
|
- 0.8.73 was tagged but not published (a GitHub 504 in the Linux AppImage bundling); 0.8.74 ships its section below. CI caches the AppImage tools and retries the Linux bundle.
|
||||||
|
|
||||||
|
## 0.8.73 · 2026-11-08
|
||||||
|
|
||||||
|
- **iPhone Duo:** the live API names the platform IPHONE_APP_STORE (not IOS); accepted. A Duo problem now warns and the other screenshot sets still upload.
|
||||||
|
|
||||||
|
## 0.8.72 · 2026-11-08
|
||||||
|
|
||||||
|
- **iPhone Duo screenshots upload.** `apple screenshots` now sends them through the App Asset Library (display class
|
||||||
|
IPHONE_DUO, placement APP_SCREENSHOT) instead of skipping them as "not in the API" (pitfall 130).
|
||||||
|
|
||||||
|
## 0.8.71 · 2026-11-07
|
||||||
|
|
||||||
|
- 0.8.69 and 0.8.70 were tagged but not published (the desktop release check stopped them); 0.8.71 ships both sections below. Desktop Portfolio: the Play state of an app uses the same words as Releases ("Not live yet: in review or blocked before review").
|
||||||
|
|
||||||
|
## 0.8.70 · 2026-11-07
|
||||||
|
|
||||||
|
- Public MCP server: the bare host is the endpoint too. `POST /` answers MCP like `/mcp` (someone who pastes `https://mcp.example.com` into a connector gets connected), `GET /` sends a browser to the landing page and names the connect URL to any other client. A signed-in server keeps `/` closed.
|
||||||
|
|
||||||
|
## 0.8.69 · 2026-11-07
|
||||||
|
|
||||||
|
- Play: `play status` and `validate` list every build still active on a testing track below the production build, with the `play release --version-code <n> --<track> completed` that replaces it (an old build with a policy issue, e.g. READ_MEDIA_IMAGES, blocks Send changes for review for the whole app). A completed production release the store page does not show yet reads "Not live yet: in review or blocked before review" instead of "In review" (CLI and desktop). A commit with `--not-sent-for-review` that Play answers with 400 "Changes are sent for review automatically" is redone without the parameter (pitfalls #129).
|
||||||
|
|
||||||
|
## 0.8.68 · 2026-11-07
|
||||||
|
|
||||||
|
- Desktop app: `storebound` works in a terminal with only the app installed. On every start the app puts a launcher for its own CLI on the PATH (Windows: `%LOCALAPPDATA%\storebound\bin`, added to the user PATH once; macOS / Linux: `~/.local/bin`, added to `~/.zprofile` / `~/.profile` when missing). An npm / bun install stays first, a file that is not the app's launcher is never overwritten, AppImage runs skip it, `STOREBOUND_NO_CLI_SHIM=1` turns it off.
|
||||||
|
- `apple resubmit` / `apple submit --platform macos`: `apple.macos.noIap` leaves every in-app purchase out of the macOS submission and, without `apple.macos.gameCenter: true`, the Game Center switch is not touched (no `gameCenterAppVersions` call); the dry run names what it left out and why (pitfalls #128).
|
||||||
|
|
||||||
|
## 0.8.67 · 2026-11-03
|
||||||
|
|
||||||
|
- `apple build --platform macos`: runs `apple.macos.prebuild` (new) before `tauri build`, no longer `build.prebuild` / `apple.prebuild`, which belong to the iOS project (a Capacitor sync or OTA gate ran for a Tauri Mac build); the dry run names the skipped one.
|
||||||
|
|
||||||
|
## 0.8.66 · 2026-11-03
|
||||||
|
|
||||||
|
- `apple.macos: { listing, reviewNotes, gameCenter, noIap }`: an app with iOS and macOS versions gets its own Mac listing file and review notes (`apple listing --platform macos`, `apple review-details --platform macos`, new there); `validate` warns about iOS-only claims in a macOS version's texts (Game Center, tap / swipe, iPhone / iPad, in-app purchases with `noIap`).
|
||||||
|
- `apple upload <pkg>`: reading the package is bounded (pkgutil signature check 90 s, expand 5 min, then the `apple build` .json) and logged; the processing wait finds macOS builds (it looked only at iOS and sat silently until --timeout); every slow read prints a heartbeat; an SSH / non-GUI session is warned about up front.
|
||||||
|
- `apple build --platform macos`: `--tauri` takes a `tauri.<name>.conf.json` overlay (merged over tauri.conf.json and passed to `tauri build --config`; `tauri.appstore.conf.json` / `tauri.mas.conf.json` next to it are used by themselves); the Mac App Store entitlements come from `--entitlements`, `apple.macos.entitlements` or the merged config (a two-channel project signed the App Store app with its Developer ID plist); the plan lists the final keys, `get-task-allow` / `cs.disable-library-validation` stop the build (`--allow-entitlements`), other hardened-runtime exceptions warn.
|
||||||
|
- MCP `apple_review_details` takes `platform`.
|
||||||
|
- `apple release`: a 409 on a release type change is recognized again (a stray control character had broken the pattern).
|
||||||
|
|
||||||
|
## 0.8.65 · 2026-11-03
|
||||||
|
|
||||||
|
- `validate`: in-app purchases removed from sale (DEVELOPER_REMOVED_FROM_SALE, REMOVED_FROM_SALE) are no blockers; a warning only when the config still sells one.
|
||||||
|
- `shots capture --device landscape`: Mac App Store / Chromebook frames from a web build (desktop viewport at `shots.landscape.size`, default 1440x900 @2x) into `<lang>/landscape/`; on by default when the project renders a landscape size. The simulator and emulator sources skip it with a warning.
|
||||||
|
- `shots render` / `capture`: "playwright not found" now lists each place looked at and why it failed (an import error was reported as not found).
|
||||||
|
|
||||||
|
## 0.8.64 · 2026-11-02
|
||||||
|
|
||||||
|
- `validate` / `release plan`: a macOS version is checked against Mac screenshots (APP_DESKTOP, with `apple.mac`), not the iPhone / iPad sets; with no editable version, iOS is picked over macOS.
|
||||||
|
- `validate --play`: reads go through the locked read-only edit and retry once on a fresh edit when Play ends it ("This Edit has been deleted" was shown as a blocker; it is now a warning to re-run at most).
|
||||||
|
- Build numbers for macOS (`apple build --platform macos`, `apple upload` of a .pkg) come from every build of the app, as `apple next-build` does (a macOS-only list proposed a number an iOS build already had).
|
||||||
|
- `apple build --platform macos` runs `build.prebuild` / `apple.prebuild` before `tauri build` (`--no-prebuild` skips it), and the new `apple.macAppCheck` command on the built .app before productbuild ({file} = the .app; a nonzero exit stops the build).
|
||||||
|
- `apple signing status` / the Mac build dry run on Windows or Linux say the keys live on the Mac that made the certificates (build there) instead of suggesting a new certificate.
|
||||||
|
- Flows: a dry `flow run` plans the upload, TestFlight wait and distribute steps after a dry build instead of failing on the missing IPA; `beta` and `release` need VERSION (no silent 1.0.0); `beta` distributes to the config's internal TestFlight group when GROUP is empty; `release` has optional macOS steps (MAC_TAURI), PLAY_TRACK (e.g. beta = open testing) and a promote owner step.
|
||||||
|
## 0.8.63 · 2026-11-02
|
||||||
|
|
||||||
|
- Desktop: a second start at logon (`--hidden`, e.g. a Startup folder shortcut next to the Run entry) keeps the app in the tray instead of opening its window.
|
||||||
|
|
||||||
|
## 0.8.62 · 2026-10-29
|
||||||
|
|
||||||
|
- `doctor` warns when storebound runs from a folder macOS guards (~/Desktop, ~/Documents, ~/Downloads, iCloud Drive; e.g. a `bun link` to a checkout there): a launchd job or CI agent without access to it blocks in open() with no output.
|
||||||
|
- `apple build` prints a line before each slow step (App Store Connect reads, device families, web build), so a run without a terminal that stalls shows where.
|
||||||
|
## 0.8.61 · 2026-10-29
|
||||||
|
|
||||||
|
- TestFlight: `apple.testflight.description` takes a language id or its App Store locale (`en` or `en-US`; an `en-US` key was skipped silently), `check` names an unknown key, and `distribute --submit-review` stops (dry run: warns) when the app's primary locale has no beta localization (Beta App Review answers 422 MISSING_BETA_APP_LOCALIZATION).
|
||||||
|
## 0.8.60 · 2026-10-29
|
||||||
|
|
||||||
|
- `apple listing` creates a new version with the release type of the newest version before it (MANUAL or AFTER_APPROVAL) when `apple.releaseType` is not set; a first version stays MANUAL. The plan names where the type came from, and warns when `apple.releaseType` differs from the previous version's.
|
||||||
|
- `play release <aab> --dry` uploads nothing: it names the versionCode it would upload and the track changes it would make (the bundle went into a discarded edit, and a long upload could outlive the edit: "This edit has expired").
|
||||||
|
- `play build`: an absolute `--dir` / `play.build.dir` stays absolute (it was taken as a folder under the project and lost its leading slash); a `gradlew` without the exec bit (committed from Windows) is made executable with a note to commit the mode. The desktop release signs by key path only.
|
||||||
|
|
||||||
|
## 0.8.59 · 2026-10-29
|
||||||
|
|
||||||
|
- `mcp --http`: a `tools/call` that accepts `text/event-stream` gets SSE keepalive comments every 20 s and then its result, so long calls survive proxies that cut silent responses. The public server's App Store search keeps one budget of 20 calls a minute (Apple's limit).
|
||||||
|
- `storebound mcp --http --public`: a public, key-less MCP server (no sign-in, no store credentials, no project folders, no child processes, read-only). Tools: `skills_list`, `skill_get`, `pitfalls_search`, `store_limits`, `listing_lint` and `aso_search` (the public iTunes Search API, the only network call). Rate limit per client (`--rate`, 429 with Retry-After; `--trust-proxy` for X-Forwarded-For), 64 KB request bodies, CORS preflight. docs/mcp.md.
|
||||||
|
|
||||||
|
## 0.8.58 · 2026-10-29
|
||||||
|
|
||||||
|
- `check` and `scan` are fast on big repos: project walks skip dot folders (tool state, worktree copies), linked git worktrees and the folders git ignores (Pods, Carthage, SourcePackages and ios / android stay in), and read entry types from the listing instead of a stat per file. A game repo with worktree copies went from 244 s to 46 s for `check`.
|
||||||
|
- `storebound mcp --http`: one Streamable HTTP MCP server that every agent session of a machine shares (no process per session). Each tool gets a `project` argument (absolute path inside `--roots`); auth is a local bearer token (`~/.storebound/mcp-token`, made on first start) or, for a server behind TLS, OAuth bearer tokens checked by introspection (RFC 7662) with protected resource metadata (RFC 9728). docs/mcp.md.
|
||||||
|
|
||||||
|
## 0.8.57 · 2026-10-27
|
||||||
|
|
||||||
|
- `apple upload` finds the IPA of a build made with `--out`: `apple build` notes its IPA and out folder in `.storebound/last-apple-build.json`, and upload searches `--out` (new flag), then that last build's out, then `apple.build.out` / `build/ios`. When nothing is found, the error names every folder it searched and the last build's IPA.
|
||||||
|
|
||||||
|
## 0.8.56 · 2026-10-27
|
||||||
|
|
||||||
|
- Release type. `apple.releaseType: afterApproval | manual | scheduled` (+ `apple.earliestReleaseDate`): `apple listing` creates versions with it (MANUAL when unset, existing versions untouched) and `apple submit` / `resubmit` set it before submitting when it differs, the dry run showing old -> new. New `apple release --after-approval | --manual | --scheduled <ISO date> [--platform] [--version] [--first-release] --yes` changes it on a version App Review has not approved yet (clear refusal otherwise, with `--manual-release` as the way out); exit 7 when it already has that type; an update is an agent step, after-approval on the first version of an app is exit 3 OWNER_STEP. Pitfall 125.
|
||||||
|
- Device families. `validate` and `apple build` read the device families of the last live version (build bundle `deviceProtocols`, device models, iPad screenshot sets) and compare them with TARGETED_DEVICE_FAMILY in the Xcode project and `apple.ipad`; a gap stops `apple build` before the archive with the exact fix (ITMS-90101 otherwise comes after the build; `--allow-device-gap` overrides). Offline `check` warns when the live families are unknown or the config and project disagree. Pitfall 126.
|
||||||
|
- TestFlight. `apple testflight testers --invite` checks that the tester's group has an installable build (past Beta App Review for external groups); without one it adds the tester, skips the invite and prints when it can go out (exit 0). Apple's 409 NO_INSTALLABLE_BUILDS is handled the same way; `distribute --submit-review` prints the hint for testers not invited yet. Pitfall 127.
|
||||||
|
|
||||||
|
## 0.8.55 · 2026-10-26
|
||||||
|
|
||||||
|
- `apple build --path-free`: a checkout in a shared build folder outside the home folder is no longer a leak needle (dsymutil and the module cache record it; only home and user-name paths count).
|
||||||
|
|
||||||
|
## 0.8.54 · 2026-10-26
|
||||||
|
|
||||||
|
- `apple build` is hermetic and can be path-free. `--derived-data <dir>` (`apple.build.derivedData`) is xcodebuild `-derivedDataPath`; with `--out` (or `apple.build.out`) it defaults to `<out>/DerivedData` instead of `~/Library/Developer/Xcode/DerivedData` (without `--out` Xcode's folder stays). `--path-free` (`apple.build.pathFree`) remaps the home folder, checkout, out and DerivedData out of the app binary and the archive's dSYMs / Symbols (Swift `-debug-prefix-map` / `-file-prefix-map`, clang `-ffile-prefix-map`; dwarf-with-dsym stays, symbol upload keeps working), scans the archive and stops before the export with the hit count and the first file + offsets (never the paths). `--scan-paths` only scans and warns. A `--out` outside the home folder prints a hint. `--json` / `latest.json` carry `derivedData`, `pathFree` and `leaks`. Store-pitfalls 124.
|
||||||
|
|
||||||
## 0.8.53 · 2026-10-26
|
## 0.8.53 · 2026-10-26
|
||||||
|
|
||||||
- Updates are agent steps (the owner's standing rule), first releases stay the owner's. `play release <aab> --production completed|inProgress --yes`, `play upload --track production --yes`, `apple submit --build <n> --yes` and `apple release --manual-release --yes` run without an owner gate, in a terminal and in a pipeline, when the store says the app is already live (Play: the production track holds a completed / inProgress / halted release; App Store: a version of the platform is or was `READY_FOR_SALE` / `READY_FOR_DISTRIBUTION` / `REPLACED_WITH_NEW_VERSION`; `cli/lib/release-kind.ts`). The result line carries `releaseKind`; a re-run is exit 7. The first-ever release of an app with `--yes` is exit 3 `OWNER_STEP` ("first release of this app: the owner approves it once"), approved by `--first-release` (after the owner's yes) or bypass mode; a person answering the prompt (no `--yes`) is the approval too. `apple release` is now a ship step (`--json`, `--result-file`, exit 7 when the version is released already). Policy in docs/bypass.md ("Updates are agent steps"), docs/ship-step.md, the release-management and play-first-release skills, AGENTS.md; pitfall 123 / 96.
|
- Updates are agent steps (the owner's standing rule), first releases stay the owner's. `play release <aab> --production completed|inProgress --yes`, `play upload --track production --yes`, `apple submit --build <n> --yes` and `apple release --manual-release --yes` run without an owner gate, in a terminal and in a pipeline, when the store says the app is already live (Play: the production track holds a completed / inProgress / halted release; App Store: a version of the platform is or was `READY_FOR_SALE` / `READY_FOR_DISTRIBUTION` / `REPLACED_WITH_NEW_VERSION`; `cli/lib/release-kind.ts`). The result line carries `releaseKind`; a re-run is exit 7. The first-ever release of an app with `--yes` is exit 3 `OWNER_STEP` ("first release of this app: the owner approves it once"), approved by `--first-release` (after the owner's yes) or bypass mode; a person answering the prompt (no `--yes`) is the approval too. `apple release` is now a ship step (`--json`, `--result-file`, exit 7 when the version is released already). Policy in docs/bypass.md ("Updates are agent steps"), docs/ship-step.md, the release-management and play-first-release skills, AGENTS.md; pitfall 123 / 96.
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@storebound/desktop",
|
"name": "@storebound/desktop",
|
||||||
"version": "0.8.53",
|
"version": "0.8.78",
|
||||||
"private": true,
|
"private": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
|
|
|
||||||
2
apps/desktop/src-tauri/Cargo.lock
generated
2
apps/desktop/src-tauri/Cargo.lock
generated
|
|
@ -4096,7 +4096,7 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "storebound-desktop"
|
name = "storebound-desktop"
|
||||||
version = "0.8.53"
|
version = "0.8.78"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"base64 0.22.1",
|
"base64 0.22.1",
|
||||||
"getrandom 0.3.4",
|
"getrandom 0.3.4",
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "storebound-desktop"
|
name = "storebound-desktop"
|
||||||
version = "0.8.53"
|
version = "0.8.78"
|
||||||
description = "storebound desktop: every game's releases on both stores in one window"
|
description = "storebound desktop: every game's releases on both stores in one window"
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|
|
||||||
|
|
@ -322,8 +322,9 @@ pub fn run() {
|
||||||
early_trace();
|
early_trace();
|
||||||
linux_webkit_env();
|
linux_webkit_env();
|
||||||
let app = tauri::Builder::default()
|
let app = tauri::Builder::default()
|
||||||
// single-instance first: a second start (or a storebound:// link) focuses the running app instead
|
// single-instance first: a second start (or a storebound:// link) focuses the running app instead; a second
|
||||||
.plugin(tauri_plugin_single_instance::init(|app, _argv, _cwd| show_main(app)))
|
// logon start (--hidden: the Run entry plus a Startup folder shortcut) stays in the tray
|
||||||
|
.plugin(tauri_plugin_single_instance::init(|app, argv, _cwd| if !argv.iter().any(|a| a == "--hidden") { show_main(app) }))
|
||||||
.plugin(tauri_plugin_deep_link::init())
|
.plugin(tauri_plugin_deep_link::init())
|
||||||
// never restore "visible": a --hidden start would otherwise pop the window up
|
// never restore "visible": a --hidden start would otherwise pop the window up
|
||||||
.plugin(tauri_plugin_window_state::Builder::new().with_filter(|label| !label.starts_with(menu_panel::LABEL_PREFIX)).with_state_flags(tauri_plugin_window_state::StateFlags::all() & !tauri_plugin_window_state::StateFlags::VISIBLE).build())
|
.plugin(tauri_plugin_window_state::Builder::new().with_filter(|label| !label.starts_with(menu_panel::LABEL_PREFIX)).with_state_flags(tauri_plugin_window_state::StateFlags::all() & !tauri_plugin_window_state::StateFlags::VISIBLE).build())
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
"$schema": "https://schema.tauri.app/config/2",
|
"$schema": "https://schema.tauri.app/config/2",
|
||||||
"productName": "storebound",
|
"productName": "storebound",
|
||||||
"mainBinaryName": "storebound-desktop",
|
"mainBinaryName": "storebound-desktop",
|
||||||
"version": "0.8.53",
|
"version": "0.8.78",
|
||||||
"identifier": "dev.storebound.desktop",
|
"identifier": "dev.storebound.desktop",
|
||||||
"build": {
|
"build": {
|
||||||
"frontendDist": "../dist",
|
"frontendDist": "../dist",
|
||||||
|
|
|
||||||
|
|
@ -153,7 +153,8 @@ export const en = {
|
||||||
'phase.releasedUnknown': "Couldn't check the store page",
|
'phase.releasedUnknown': "Couldn't check the store page",
|
||||||
'phase.pageUnknown': "Couldn't check the store page",
|
'phase.pageUnknown': "Couldn't check the store page",
|
||||||
'phase.pageStale': "couldn't check the store page, as of {when}",
|
'phase.pageStale': "couldn't check the store page, as of {when}",
|
||||||
'phase.reviewLive': 'In review (live: {version})',
|
'phase.reviewLive': 'Not live yet (live: {version}): in review or blocked before review',
|
||||||
|
'phase.playPending': 'Not live yet: in review or blocked before review',
|
||||||
'roll.publishReady': 'If the release is approved, publish it in Publishing overview ("Publish N changes"). The agent prepares it with `{cmd}`; the final press is for the owner.',
|
'roll.publishReady': 'If the release is approved, publish it in Publishing overview ("Publish N changes"). The agent prepares it with `{cmd}`; the final press is for the owner.',
|
||||||
'roll.publishOpen': 'Open Publishing overview',
|
'roll.publishOpen': 'Open Publishing overview',
|
||||||
'phase.reviewManaged': 'In review / ready to publish (managed publishing)',
|
'phase.reviewManaged': 'In review / ready to publish (managed publishing)',
|
||||||
|
|
|
||||||
|
|
@ -155,7 +155,8 @@ export const tr: Record<keyof typeof en, string> = {
|
||||||
'phase.releasedUnknown': 'Mağaza sayfası kontrol edilemedi',
|
'phase.releasedUnknown': 'Mağaza sayfası kontrol edilemedi',
|
||||||
'phase.pageUnknown': 'Mağaza sayfası kontrol edilemedi',
|
'phase.pageUnknown': 'Mağaza sayfası kontrol edilemedi',
|
||||||
'phase.pageStale': 'mağaza sayfası kontrol edilemedi, {when} itibarıyla',
|
'phase.pageStale': 'mağaza sayfası kontrol edilemedi, {when} itibarıyla',
|
||||||
'phase.reviewLive': 'İncelemede (yayında: {version})',
|
'phase.reviewLive': 'Henüz yayında değil (yayında: {version}): incelemede ya da incelemeden önce takıldı',
|
||||||
|
'phase.playPending': 'Henüz yayında değil: incelemede ya da incelemeden önce takıldı',
|
||||||
'roll.publishReady': 'Sürüm onaylandıysa Yayınlama özetinde yayınlayın ("Publish N changes"). Ajan `{cmd}` ile hazırlar; son basış sahibine aittir.',
|
'roll.publishReady': 'Sürüm onaylandıysa Yayınlama özetinde yayınlayın ("Publish N changes"). Ajan `{cmd}` ile hazırlar; son basış sahibine aittir.',
|
||||||
'roll.publishOpen': 'Yayınlama özetini aç',
|
'roll.publishOpen': 'Yayınlama özetini aç',
|
||||||
'phase.reviewManaged': 'İncelemede / yayına hazır (yönetilen yayınlama)',
|
'phase.reviewManaged': 'İncelemede / yayına hazır (yönetilen yayınlama)',
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@ import { useExports } from '../ui/Exports';
|
||||||
import { Icon, StoreGlyph } from '../ui/icons';
|
import { Icon, StoreGlyph } from '../ui/icons';
|
||||||
import { nextStep, Pipeline, tintStyle, useShots, useTint } from '../ui/ds';
|
import { nextStep, Pipeline, tintStyle, useShots, useTint } from '../ui/ds';
|
||||||
export { nextStep } from '../ui/ds';
|
export { nextStep } from '../ui/ds';
|
||||||
import { AppIcon, Card, Chip, Empty, Kpi, Notice, PhaseChip, Seg, Skeleton, Sparkline, StudioMark } from '../ui/kit';
|
import { AppIcon, Card, Chip, Empty, Kpi, Notice, PhaseChip, phaseLabel, Seg, Skeleton, Sparkline, StudioMark } from '../ui/kit';
|
||||||
|
|
||||||
/** Tag of one app's offline config check. */
|
/** Tag of one app's offline config check. */
|
||||||
export function checkState(e: Pick<AppStatus, 'errors' | 'check'> | undefined): { text: string; tone: Tone } {
|
export function checkState(e: Pick<AppStatus, 'errors' | 'check'> | undefined): { text: string; tone: Tone } {
|
||||||
|
|
@ -72,7 +72,7 @@ function NextCell({ e }: { e: AppStatus | undefined }) {
|
||||||
<span className="strong num">{n.version}</span>
|
<span className="strong num">{n.version}</span>
|
||||||
<div className="row small muted" style={{ gap: 10 }}>
|
<div className="row small muted" style={{ gap: 10 }}>
|
||||||
{n.ios && <span className="row" style={{ gap: 4 }}><StoreGlyph store="ios" className="ic13" />{t(`phase.${n.ios.phase}`)}</span>}
|
{n.ios && <span className="row" style={{ gap: 4 }}><StoreGlyph store="ios" className="ic13" />{t(`phase.${n.ios.phase}`)}</span>}
|
||||||
{n.android && <span className="row" style={{ gap: 4 }}><StoreGlyph store="android" className="ic13" />{t(`phase.${n.android.phase}`)}</span>}
|
{n.android && <span className="row" style={{ gap: 4 }}><StoreGlyph store="android" className="ic13" />{phaseLabel(n.android).text}</span>}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ export function phaseLabel(r: StoreRelease | null | undefined): { text: string;
|
||||||
const stale = r.pageStaleAt ? ` · ${t('phase.pageStale', { when: ago(r.pageStaleAt) })}` : '';
|
const stale = r.pageStaleAt ? ` · ${t('phase.pageStale', { when: ago(r.pageStaleAt) })}` : '';
|
||||||
if (r.store === 'android' && r.phase === 'released') return { text: t('phase.pageUnknown') + stale, tone: 'neutral' };
|
if (r.store === 'android' && r.phase === 'released') return { text: t('phase.pageUnknown') + stale, tone: 'neutral' };
|
||||||
if (r.store === 'android' && (r.phase === 'review' || r.phase === 'sent'))
|
if (r.store === 'android' && (r.phase === 'review' || r.phase === 'sent'))
|
||||||
return { text: (r.managed ? t('phase.reviewManaged') : r.liveVersion ? t('phase.reviewLive', { version: r.liveVersion }) : t('phase.review')) + stale, tone: 'warn' };
|
return { text: (r.managed ? t('phase.reviewManaged') : r.liveVersion ? t('phase.reviewLive', { version: r.liveVersion }) : t('phase.playPending')) + stale, tone: 'warn' };
|
||||||
if (r.store === 'android' && r.phase === 'live' && stale) return { text: t('phase.live') + stale, tone: 'ok' };
|
if (r.store === 'android' && r.phase === 'live' && stale) return { text: t('phase.live') + stale, tone: 'ok' };
|
||||||
if (r.phase === 'testing' && r.track) return { text: `${t('phase.testing')} · ${r.track}`, tone: 'info' };
|
if (r.phase === 'testing' && r.track) return { text: `${t('phase.testing')} · ${r.track}`, tone: 'info' };
|
||||||
return { text: t(`phase.${r.phase}`), tone: PHASE_TONE[r.phase] };
|
return { text: t(`phase.${r.phase}`), tone: PHASE_TONE[r.phase] };
|
||||||
|
|
|
||||||
830
bun.lock
Normal file
830
bun.lock
Normal file
|
|
@ -0,0 +1,830 @@
|
||||||
|
{
|
||||||
|
"lockfileVersion": 2,
|
||||||
|
"configVersion": 1,
|
||||||
|
"workspaces": {
|
||||||
|
"": {
|
||||||
|
"name": "storebound",
|
||||||
|
"devDependencies": {
|
||||||
|
"@mermaid-js/mermaid-cli": "12.0.0",
|
||||||
|
"@phosphor-icons/core": "2.1.1",
|
||||||
|
"@types/bun": "1.3.0",
|
||||||
|
"playwright": "1.55.0",
|
||||||
|
"playwright-core": "1.55.0",
|
||||||
|
"simple-icons": "16.34.0",
|
||||||
|
"typescript": "5.9.3",
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"playwright": ">=1.45",
|
||||||
|
},
|
||||||
|
"optionalPeers": [
|
||||||
|
"playwright",
|
||||||
|
],
|
||||||
|
},
|
||||||
|
"apps/desktop": {
|
||||||
|
"name": "@storebound/desktop",
|
||||||
|
"version": "0.8.69",
|
||||||
|
"dependencies": {
|
||||||
|
"@phosphor-icons/react": "^2.1.10",
|
||||||
|
"@tauri-apps/api": "^2.12.0",
|
||||||
|
"@visx/axis": "^4.0.0",
|
||||||
|
"@visx/curve": "^4.0.0",
|
||||||
|
"@visx/event": "^4.0.0",
|
||||||
|
"@visx/gradient": "^4.0.0",
|
||||||
|
"@visx/group": "^4.0.0",
|
||||||
|
"@visx/responsive": "^4.0.0",
|
||||||
|
"@visx/scale": "^4.0.0",
|
||||||
|
"@visx/shape": "^4.0.0",
|
||||||
|
"@visx/tooltip": "^4.0.0",
|
||||||
|
"react": "^19.2.0",
|
||||||
|
"react-dom": "^19.2.0",
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"@tauri-apps/cli": "^2.12.1",
|
||||||
|
"@types/react": "^19.2.0",
|
||||||
|
"@types/react-dom": "^19.2.0",
|
||||||
|
"@vitejs/plugin-react": "^4.7.0",
|
||||||
|
"typescript": "5.9.3",
|
||||||
|
"vite": "^6.3.0",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
"packages": {
|
||||||
|
"@antfu/install-pkg": ["@antfu/install-pkg@2.1.0", "", { "dependencies": { "package-manager-detector": "^1.8.0", "tinyexec": "^1.3.1" } }, "sha512-sdg9NxU3zR4Mnawfbc/x6GB5Wf17WYud5qOuEuxXjaKpYpMkISSJEjItGebXJ2bQ4DIcly4NYH23mtkGJjvKUw=="],
|
||||||
|
|
||||||
|
"@babel/code-frame": ["@babel/code-frame@7.29.7", "", { "dependencies": { "@babel/helper-validator-identifier": "^7.29.7", "js-tokens": "^4.0.0", "picocolors": "^1.1.1" } }, "sha512-Aup7aUOfpbAUg2ROOJN6Iw5f9DMBlzu0mIkm/malLQFN/YQgO48wCj0Kxa3sEHJvPVFg7siR+qRInwXd2qhQKw=="],
|
||||||
|
|
||||||
|
"@babel/compat-data": ["@babel/compat-data@7.29.7", "", {}, "sha512-locTkQyKvwIEgBzVrn8693ebc97F2U8ZHjbXwDXJ5Fn2TCpNwTlKcaKLkdHop5c/icOFE7qt7Q9JC5hnKNa6Gg=="],
|
||||||
|
|
||||||
|
"@babel/core": ["@babel/core@7.29.7", "", { "dependencies": { "@babel/code-frame": "^7.29.7", "@babel/generator": "^7.29.7", "@babel/helper-compilation-targets": "^7.29.7", "@babel/helper-module-transforms": "^7.29.7", "@babel/helpers": "^7.29.7", "@babel/parser": "^7.29.7", "@babel/template": "^7.29.7", "@babel/traverse": "^7.29.7", "@babel/types": "^7.29.7", "@jridgewell/remapping": "^2.3.5", "convert-source-map": "^2.0.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", "json5": "^2.2.3", "semver": "^6.3.1" } }, "sha512-RgHBCvtjbOK2gXSNBNIkNoEc9qoVEtau3hj8gEqKQuL3HZAibKarWFEI3Lfm6EYKkLalOh8eSrj9b+ch9H/VBA=="],
|
||||||
|
|
||||||
|
"@babel/generator": ["@babel/generator@7.29.8", "", { "dependencies": { "@babel/parser": "^7.29.8", "@babel/types": "^7.29.8", "@jridgewell/gen-mapping": "^0.3.12", "@jridgewell/trace-mapping": "^0.3.28", "jsesc": "^3.0.2" } }, "sha512-gZbepsdh3WDtgZKWL+vTPh71LSBrm/Y4/QDZBVCcYfmeTEEuoOYwlSy+G1StfJg+/Zy550u/3TATbm7qDbbMtg=="],
|
||||||
|
|
||||||
|
"@babel/helper-compilation-targets": ["@babel/helper-compilation-targets@7.29.7", "", { "dependencies": { "@babel/compat-data": "^7.29.7", "@babel/helper-validator-option": "^7.29.7", "browserslist": "^4.24.0", "lru-cache": "^5.1.1", "semver": "^6.3.1" } }, "sha512-wem6WaBj4NaVYVdNhLPPVacES6ZJ+KBBfSkTMD3YZxbP3rm3Di85tJU5ljaUNhaOynt+Aj0xruhYuzQBt8n71g=="],
|
||||||
|
|
||||||
|
"@babel/helper-globals": ["@babel/helper-globals@7.29.7", "", {}, "sha512-3nQVUAtvkKH9zahfWgw96Jc/uFOmjACE1kQz82E2lqWmHBgjzbNlsC22nuQTfahmWeQtTq5nQ/4Nnd2A1wj4zA=="],
|
||||||
|
|
||||||
|
"@babel/helper-module-imports": ["@babel/helper-module-imports@7.29.7", "", { "dependencies": { "@babel/traverse": "^7.29.7", "@babel/types": "^7.29.7" } }, "sha512-ejHwrQQYcm9xnTivShn2IDOlIzInN34AXskvq9QicvCtEzq1Vzclu/tKF8Jq1Cg8JG2GL6/EmjgsCT7lXepE3g=="],
|
||||||
|
|
||||||
|
"@babel/helper-module-transforms": ["@babel/helper-module-transforms@7.29.7", "", { "dependencies": { "@babel/helper-module-imports": "^7.29.7", "@babel/helper-validator-identifier": "^7.29.7", "@babel/traverse": "^7.29.7" }, "peerDependencies": { "@babel/core": "^7.0.0" } }, "sha512-UPUVSyXbOh627KiCIGQSgwWzGeBKLkaJ9PJEdrngIwMSzxLR4jS4+f1f1jb7VzBbg8nFLaYotvVPFCTqdrmTAg=="],
|
||||||
|
|
||||||
|
"@babel/helper-plugin-utils": ["@babel/helper-plugin-utils@7.29.7", "", {}, "sha512-G7sHYigPY17oO5SYWnfD/0MTBwVR781S/JI643e/JhUYgVgWE/61SoW3NH9KWUKyKq5LVh3npif99Wkt6j86Jw=="],
|
||||||
|
|
||||||
|
"@babel/helper-string-parser": ["@babel/helper-string-parser@7.29.11", "", {}, "sha512-snZbO7MEDOof+hvNa97EjEY7qD7h2kwvQr5AJC3ZhQudKW5dnej6k3kP9NQV88hJwaS8vDqRLFo9rivLEhle2g=="],
|
||||||
|
|
||||||
|
"@babel/helper-validator-identifier": ["@babel/helper-validator-identifier@7.29.7", "", {}, "sha512-qehxGkRj55h/ff8EMaJ+cYhyaKlHIxqYDn682wQD7RNp9UujOQsHog2uS0r2vzr4pW+sXf90NeeayjcNaX3fFg=="],
|
||||||
|
|
||||||
|
"@babel/helper-validator-option": ["@babel/helper-validator-option@7.29.7", "", {}, "sha512-N9ZErrD+yW5geCDtBqnOoxmR8+tNKiGuxKlDpuJxfsqpa2dFcexaziGAE/qoHLiDDreVNMupxGmSoNlyvsA3gw=="],
|
||||||
|
|
||||||
|
"@babel/helpers": ["@babel/helpers@7.29.10", "", { "dependencies": { "@babel/template": "^7.29.7", "@babel/types": "^7.29.8" } }, "sha512-EMCx3AGZ3WfAl6ht7AyQoPm2Lh+BGYEMdc4Q6Hf7uSCDOZFuLq44qNwL+iaim8VlyYhRAo4X43+weadK8ZB4Yg=="],
|
||||||
|
|
||||||
|
"@babel/parser": ["@babel/parser@7.29.11", "", { "dependencies": { "@babel/types": "^7.29.11" }, "bin": "./bin/babel-parser.js" }, "sha512-OZ6+oaK7GMyg3IfCpj8JOmn8n+w2rJbDT0LLfVDTLb1ZFeKDh3AiNELgCMUw175IJHSkLl74hG0M0VLsvx+gag=="],
|
||||||
|
|
||||||
|
"@babel/plugin-transform-react-jsx-self": ["@babel/plugin-transform-react-jsx-self@7.29.7", "", { "dependencies": { "@babel/helper-plugin-utils": "^7.29.7" }, "peerDependencies": { "@babel/core": "^7.0.0-0" } }, "sha512-TL0hMc9xzy86VD31nUiwzd5otRAcyEPcsegCxolO0PvcXuH1v0kECe/UIznYFihpkvU5wg/jk4v0TTEFfm53fw=="],
|
||||||
|
|
||||||
|
"@babel/plugin-transform-react-jsx-source": ["@babel/plugin-transform-react-jsx-source@7.29.7", "", { "dependencies": { "@babel/helper-plugin-utils": "^7.29.7" }, "peerDependencies": { "@babel/core": "^7.0.0-0" } }, "sha512-06IyK09H3wi4cGbhDBwp5gUGo0IKtnYa8tyTiephirPCK6fbobVGiXMMI5zLQ4aKEYP3wZ3ArU44o+8KMrSG/Q=="],
|
||||||
|
|
||||||
|
"@babel/template": ["@babel/template@7.29.7", "", { "dependencies": { "@babel/code-frame": "^7.29.7", "@babel/parser": "^7.29.7", "@babel/types": "^7.29.7" } }, "sha512-puq+Gf35oI24FeN11LkoUQFqv9uwNeWpxXZi/Ji3rRIoKAzKnxRaZ+Gkj0vKS9ZCiTESfng1N9LyOyXvo+m+Gg=="],
|
||||||
|
|
||||||
|
"@babel/traverse": ["@babel/traverse@7.29.10", "", { "dependencies": { "@babel/code-frame": "^7.29.7", "@babel/generator": "^7.29.8", "@babel/helper-globals": "^7.29.7", "@babel/parser": "^7.29.9", "@babel/template": "^7.29.7", "@babel/types": "^7.29.8", "debug": "^4.3.1" } }, "sha512-B3lYAs2nkKskbgQ1nfy8Ma9ao9Q1rntTAQHrzzyDuj+TSO+X3le6PfWwqDvodsb+OumE10eMFfuMCTQSQ5iuIQ=="],
|
||||||
|
|
||||||
|
"@babel/types": ["@babel/types@7.29.11", "", { "dependencies": { "@babel/helper-string-parser": "^7.29.11", "@babel/helper-validator-identifier": "^7.29.7" } }, "sha512-WCsemW40Cpc6gouC1SrY6PBaZ+oLRlEVY9XBvZBI7il/HyUrb2nJ505wE1MHEFyDZNnrWDEuy4jL50WVHfTTSQ=="],
|
||||||
|
|
||||||
|
"@braintree/sanitize-url": ["@braintree/sanitize-url@7.1.2", "", {}, "sha512-jigsZK+sMF/cuiB7sERuo9V7N9jx+dhmHHnQyDSVdpZwVutaBu7WvNYqMDLSgFgfB30n452TP3vjDAvFC973mA=="],
|
||||||
|
|
||||||
|
"@chevrotain/cst-dts-gen": ["@chevrotain/cst-dts-gen@13.2.0", "", { "dependencies": { "@chevrotain/gast": "13.2.0", "@chevrotain/types": "13.2.0" } }, "sha512-bA9dvWlhAUcHkNwU+8w9yiUxJPlj/Lm3VqS7MD+NbIR/7LmpNLuK/AWNFdCo/T3SK5ND0/UHf3IJvl/Jn/i6yg=="],
|
||||||
|
|
||||||
|
"@chevrotain/gast": ["@chevrotain/gast@13.2.0", "", { "dependencies": { "@chevrotain/types": "13.2.0" } }, "sha512-bCARdAsG+eEbOveSXcOAC7pVxA04I1ionzeMOwIYf5NX7SaS7zgn4Dgug2BSqoL+iyKeMNSorQjsFSHJHsCNwg=="],
|
||||||
|
|
||||||
|
"@chevrotain/regexp-to-ast": ["@chevrotain/regexp-to-ast@13.2.0", "", {}, "sha512-kxpUkLtiaK09ph+dib+Yvm+3sWSnuwlo25gqfKRgTPNmF6H7uW4gVkMjaRdtnN783S9sM6vUNWh9CsxYX4QwKw=="],
|
||||||
|
|
||||||
|
"@chevrotain/types": ["@chevrotain/types@13.2.0", "", {}, "sha512-7qrYHRlKfWf2AvBfJi5eVOrKAkbxvMFsy/iIHTGIiApNcEecCaVIdR+mIQhyCBsTDJxBz4JWXHMo6krbhR9hVg=="],
|
||||||
|
|
||||||
|
"@chevrotain/utils": ["@chevrotain/utils@13.2.0", "", {}, "sha512-SzKYY68rseOrb9KILVzPsl6SjkQtdWw01SRGB5aCVI5kFcHltQsOYV3JB0Ffst72DgkvHCyDQ0NLwxtmCCf97Q=="],
|
||||||
|
|
||||||
|
"@esbuild/aix-ppc64": ["@esbuild/aix-ppc64@0.25.12", "", { "os": "aix", "cpu": "ppc64" }, "sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA=="],
|
||||||
|
|
||||||
|
"@esbuild/android-arm": ["@esbuild/android-arm@0.25.12", "", { "os": "android", "cpu": "arm" }, "sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg=="],
|
||||||
|
|
||||||
|
"@esbuild/android-arm64": ["@esbuild/android-arm64@0.25.12", "", { "os": "android", "cpu": "arm64" }, "sha512-6AAmLG7zwD1Z159jCKPvAxZd4y/VTO0VkprYy+3N2FtJ8+BQWFXU+OxARIwA46c5tdD9SsKGZ/1ocqBS/gAKHg=="],
|
||||||
|
|
||||||
|
"@esbuild/android-x64": ["@esbuild/android-x64@0.25.12", "", { "os": "android", "cpu": "x64" }, "sha512-5jbb+2hhDHx5phYR2By8GTWEzn6I9UqR11Kwf22iKbNpYrsmRB18aX/9ivc5cabcUiAT/wM+YIZ6SG9QO6a8kg=="],
|
||||||
|
|
||||||
|
"@esbuild/darwin-arm64": ["@esbuild/darwin-arm64@0.25.12", "", { "os": "darwin", "cpu": "arm64" }, "sha512-N3zl+lxHCifgIlcMUP5016ESkeQjLj/959RxxNYIthIg+CQHInujFuXeWbWMgnTo4cp5XVHqFPmpyu9J65C1Yg=="],
|
||||||
|
|
||||||
|
"@esbuild/darwin-x64": ["@esbuild/darwin-x64@0.25.12", "", { "os": "darwin", "cpu": "x64" }, "sha512-HQ9ka4Kx21qHXwtlTUVbKJOAnmG1ipXhdWTmNXiPzPfWKpXqASVcWdnf2bnL73wgjNrFXAa3yYvBSd9pzfEIpA=="],
|
||||||
|
|
||||||
|
"@esbuild/freebsd-arm64": ["@esbuild/freebsd-arm64@0.25.12", "", { "os": "freebsd", "cpu": "arm64" }, "sha512-gA0Bx759+7Jve03K1S0vkOu5Lg/85dou3EseOGUes8flVOGxbhDDh/iZaoek11Y8mtyKPGF3vP8XhnkDEAmzeg=="],
|
||||||
|
|
||||||
|
"@esbuild/freebsd-x64": ["@esbuild/freebsd-x64@0.25.12", "", { "os": "freebsd", "cpu": "x64" }, "sha512-TGbO26Yw2xsHzxtbVFGEXBFH0FRAP7gtcPE7P5yP7wGy7cXK2oO7RyOhL5NLiqTlBh47XhmIUXuGciXEqYFfBQ=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-arm": ["@esbuild/linux-arm@0.25.12", "", { "os": "linux", "cpu": "arm" }, "sha512-lPDGyC1JPDou8kGcywY0YILzWlhhnRjdof3UlcoqYmS9El818LLfJJc3PXXgZHrHCAKs/Z2SeZtDJr5MrkxtOw=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-arm64": ["@esbuild/linux-arm64@0.25.12", "", { "os": "linux", "cpu": "arm64" }, "sha512-8bwX7a8FghIgrupcxb4aUmYDLp8pX06rGh5HqDT7bB+8Rdells6mHvrFHHW2JAOPZUbnjUpKTLg6ECyzvas2AQ=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-ia32": ["@esbuild/linux-ia32@0.25.12", "", { "os": "linux", "cpu": "ia32" }, "sha512-0y9KrdVnbMM2/vG8KfU0byhUN+EFCny9+8g202gYqSSVMonbsCfLjUO+rCci7pM0WBEtz+oK/PIwHkzxkyharA=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-loong64": ["@esbuild/linux-loong64@0.25.12", "", { "os": "linux", "cpu": "none" }, "sha512-h///Lr5a9rib/v1GGqXVGzjL4TMvVTv+s1DPoxQdz7l/AYv6LDSxdIwzxkrPW438oUXiDtwM10o9PmwS/6Z0Ng=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-mips64el": ["@esbuild/linux-mips64el@0.25.12", "", { "os": "linux", "cpu": "none" }, "sha512-iyRrM1Pzy9GFMDLsXn1iHUm18nhKnNMWscjmp4+hpafcZjrr2WbT//d20xaGljXDBYHqRcl8HnxbX6uaA/eGVw=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-ppc64": ["@esbuild/linux-ppc64@0.25.12", "", { "os": "linux", "cpu": "ppc64" }, "sha512-9meM/lRXxMi5PSUqEXRCtVjEZBGwB7P/D4yT8UG/mwIdze2aV4Vo6U5gD3+RsoHXKkHCfSxZKzmDssVlRj1QQA=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-riscv64": ["@esbuild/linux-riscv64@0.25.12", "", { "os": "linux", "cpu": "none" }, "sha512-Zr7KR4hgKUpWAwb1f3o5ygT04MzqVrGEGXGLnj15YQDJErYu/BGg+wmFlIDOdJp0PmB0lLvxFIOXZgFRrdjR0w=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-s390x": ["@esbuild/linux-s390x@0.25.12", "", { "os": "linux", "cpu": "s390x" }, "sha512-MsKncOcgTNvdtiISc/jZs/Zf8d0cl/t3gYWX8J9ubBnVOwlk65UIEEvgBORTiljloIWnBzLs4qhzPkJcitIzIg=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-x64": ["@esbuild/linux-x64@0.25.12", "", { "os": "linux", "cpu": "x64" }, "sha512-uqZMTLr/zR/ed4jIGnwSLkaHmPjOjJvnm6TVVitAa08SLS9Z0VM8wIRx7gWbJB5/J54YuIMInDquWyYvQLZkgw=="],
|
||||||
|
|
||||||
|
"@esbuild/netbsd-arm64": ["@esbuild/netbsd-arm64@0.25.12", "", { "os": "none", "cpu": "arm64" }, "sha512-xXwcTq4GhRM7J9A8Gv5boanHhRa/Q9KLVmcyXHCTaM4wKfIpWkdXiMog/KsnxzJ0A1+nD+zoecuzqPmCRyBGjg=="],
|
||||||
|
|
||||||
|
"@esbuild/netbsd-x64": ["@esbuild/netbsd-x64@0.25.12", "", { "os": "none", "cpu": "x64" }, "sha512-Ld5pTlzPy3YwGec4OuHh1aCVCRvOXdH8DgRjfDy/oumVovmuSzWfnSJg+VtakB9Cm0gxNO9BzWkj6mtO1FMXkQ=="],
|
||||||
|
|
||||||
|
"@esbuild/openbsd-arm64": ["@esbuild/openbsd-arm64@0.25.12", "", { "os": "openbsd", "cpu": "arm64" }, "sha512-fF96T6KsBo/pkQI950FARU9apGNTSlZGsv1jZBAlcLL1MLjLNIWPBkj5NlSz8aAzYKg+eNqknrUJ24QBybeR5A=="],
|
||||||
|
|
||||||
|
"@esbuild/openbsd-x64": ["@esbuild/openbsd-x64@0.25.12", "", { "os": "openbsd", "cpu": "x64" }, "sha512-MZyXUkZHjQxUvzK7rN8DJ3SRmrVrke8ZyRusHlP+kuwqTcfWLyqMOE3sScPPyeIXN/mDJIfGXvcMqCgYKekoQw=="],
|
||||||
|
|
||||||
|
"@esbuild/openharmony-arm64": ["@esbuild/openharmony-arm64@0.25.12", "", { "os": "none", "cpu": "arm64" }, "sha512-rm0YWsqUSRrjncSXGA7Zv78Nbnw4XL6/dzr20cyrQf7ZmRcsovpcRBdhD43Nuk3y7XIoW2OxMVvwuRvk9XdASg=="],
|
||||||
|
|
||||||
|
"@esbuild/sunos-x64": ["@esbuild/sunos-x64@0.25.12", "", { "os": "sunos", "cpu": "x64" }, "sha512-3wGSCDyuTHQUzt0nV7bocDy72r2lI33QL3gkDNGkod22EsYl04sMf0qLb8luNKTOmgF/eDEDP5BFNwoBKH441w=="],
|
||||||
|
|
||||||
|
"@esbuild/win32-arm64": ["@esbuild/win32-arm64@0.25.12", "", { "os": "win32", "cpu": "arm64" }, "sha512-rMmLrur64A7+DKlnSuwqUdRKyd3UE7oPJZmnljqEptesKM8wx9J8gx5u0+9Pq0fQQW8vqeKebwNXdfOyP+8Bsg=="],
|
||||||
|
|
||||||
|
"@esbuild/win32-ia32": ["@esbuild/win32-ia32@0.25.12", "", { "os": "win32", "cpu": "ia32" }, "sha512-HkqnmmBoCbCwxUKKNPBixiWDGCpQGVsrQfJoVGYLPT41XWF8lHuE5N6WhVia2n4o5QK5M4tYr21827fNhi4byQ=="],
|
||||||
|
|
||||||
|
"@esbuild/win32-x64": ["@esbuild/win32-x64@0.25.12", "", { "os": "win32", "cpu": "x64" }, "sha512-alJC0uCZpTFrSL0CCDjcgleBXPnCrEAhTBILpeAp7M/OFgoqtAetfBzX0xM00MUsVVPpVjlPuMbREqnZCXaTnA=="],
|
||||||
|
|
||||||
|
"@floating-ui/core": ["@floating-ui/core@1.8.0", "", { "dependencies": { "@floating-ui/utils": "^0.2.12" } }, "sha512-0CIZ5itps/8x7BG8dEIhs53BvCUH2PCoogtakwRTut+Arm58sJooJ0AuZhLw2HJYIR5cMLNPBSS728sPho2khQ=="],
|
||||||
|
|
||||||
|
"@floating-ui/dom": ["@floating-ui/dom@1.8.0", "", { "dependencies": { "@floating-ui/core": "^1.8.0", "@floating-ui/utils": "^0.2.12" } }, "sha512-yXSrzeHZBTZadLOlfyhCkJHNeLJnHRnRInwdZ40L7ZiaAtrBwoYlsDrX3v5zB1Utk7CLfzcOVnVVWoXEky7Ceg=="],
|
||||||
|
|
||||||
|
"@floating-ui/react": ["@floating-ui/react@0.27.20", "", { "dependencies": { "@floating-ui/react-dom": "^2.1.9", "@floating-ui/utils": "^0.2.12", "tabbable": "^6.0.0" }, "peerDependencies": { "react": ">=17.0.0", "react-dom": ">=17.0.0" } }, "sha512-CMqMy7OaXl9W0eq1Uy7L7i2Y/anPvHmFmESd2CEw0t5YvZhcVCeo4MBevAmswRllX7Y2dEidA4ozGPunLSTQpw=="],
|
||||||
|
|
||||||
|
"@floating-ui/react-dom": ["@floating-ui/react-dom@2.1.9", "", { "dependencies": { "@floating-ui/dom": "^1.8.0" }, "peerDependencies": { "react": ">=16.8.0", "react-dom": ">=16.8.0" } }, "sha512-JDjEFGCpImxDCA7JJKviA0M9+RtmJdj0m/NVU5IMgBK+AmZouAQQ7/+2GLH0GXXY0YMw9oXPB8hKdbPYg5QLYg=="],
|
||||||
|
|
||||||
|
"@floating-ui/utils": ["@floating-ui/utils@0.2.12", "", {}, "sha512-HpCo8tmWzLVad5s2d19EhAz5zqrrQ6s69qd6moPMQvkOuSwDT1YgRfWSVuc4ennqrgv3OHppiOGMQ7oC13yIww=="],
|
||||||
|
|
||||||
|
"@fontsource-variable/recursive": ["@fontsource-variable/recursive@5.3.0", "", {}, "sha512-4B4/lWCVeZgdbpJdIIU1sOVO/ECjjM673ohuxvyQ6uCK41TPlGzKRNokKY84noUgGYnpwc//MW4k2KrOMY19jQ=="],
|
||||||
|
|
||||||
|
"@fontsource/open-sans": ["@fontsource/open-sans@5.3.0", "", {}, "sha512-V1bdMlGNyZrJwzrdusshMOw2YR0aqYDL7kOo9dkxUEKl8dFv66A9HLckOOXl572sG/7ohhDQrCrTFGSn9LZcSw=="],
|
||||||
|
|
||||||
|
"@fortawesome/fontawesome-free": ["@fortawesome/fontawesome-free@7.3.1", "", {}, "sha512-wmglKKPDIkgV3aWlZzWECCPoGIkYCulzBwxG9+w7rc5BGapZ6cPMpoPOT8k36J0Ni7PPX6c/rsoMWfS4d1MUMg=="],
|
||||||
|
|
||||||
|
"@headlessui/react": ["@headlessui/react@2.2.10", "", { "dependencies": { "@floating-ui/react": "^0.26.16", "@react-aria/focus": "^3.20.2", "@react-aria/interactions": "^3.25.0", "@tanstack/react-virtual": "^3.13.9", "use-sync-external-store": "^1.5.0" }, "peerDependencies": { "react": "^18 || ^19 || ^19.0.0-rc", "react-dom": "^18 || ^19 || ^19.0.0-rc" } }, "sha512-5pVLNK9wlpxTUTy9GpgbX/SdcRh+HBnPktjM2wbiLTH4p+2EPHBO1aoSryUCuKUIItdDWO9ITlhUL8UnUN/oIA=="],
|
||||||
|
|
||||||
|
"@headlessui/tailwindcss": ["@headlessui/tailwindcss@0.2.2", "", { "peerDependencies": { "tailwindcss": "^3.0 || ^4.0" } }, "sha512-xNe42KjdyA4kfUKLLPGzME9zkH7Q3rOZ5huFihWNWOQFxnItxPB3/67yBI8/qBfY8nwBRx5GHn4VprsoluVMGw=="],
|
||||||
|
|
||||||
|
"@iconify/types": ["@iconify/types@2.0.0", "", {}, "sha512-+wluvCrRhXrhyOmRDJ3q8mux9JkKy5SJ/v8ol2tu4FVjyYvtEzkc/3pK15ET6RKg4b4w4BmTk1+gsCUhf21Ykg=="],
|
||||||
|
|
||||||
|
"@iconify/utils": ["@iconify/utils@3.1.7", "", { "dependencies": { "@antfu/install-pkg": "^2.0.1", "@iconify/types": "^2.0.0", "import-meta-resolve": "^4.2.0" } }, "sha512-JZHlwdID+dy+lTgbYC8NEC4zeugqeYsc6jewvzb4c58kHauJn+X7rNwQjxz5p2qSjqaEeQoLkCIQ9v/H4PK0/w=="],
|
||||||
|
|
||||||
|
"@internationalized/date": ["@internationalized/date@3.12.4", "", { "dependencies": { "@swc/helpers": "^0.5.0" } }, "sha512-M1dEn4c1U1HsSlaVR8upZtSqvXrTkHDfv18H01uCSJyjVLDxnBR38v/fMxecmlwXKR4i9HeZcmgQAPE6A+aGJQ=="],
|
||||||
|
|
||||||
|
"@internationalized/number": ["@internationalized/number@3.6.9", "", { "dependencies": { "@swc/helpers": "^0.5.0" } }, "sha512-GgWy2caO/+hV9sT/oCTWGHvbjmJMPT9kkXzoKRLnkEq7adghhR7UprhvY9sXrKfrp3NcDfhF6QQHXR1KfQbB8g=="],
|
||||||
|
|
||||||
|
"@internationalized/string": ["@internationalized/string@3.2.10", "", { "dependencies": { "@swc/helpers": "^0.5.0" } }, "sha512-PDx6//vHSpRnHfxqMqto11zQvhsaU74O3mKv2F/0eicGZcl9NLjQmGlbHz/LsJh5tLKp4A4L7ZVTzN1/MmMTvA=="],
|
||||||
|
|
||||||
|
"@jridgewell/gen-mapping": ["@jridgewell/gen-mapping@0.3.13", "", { "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.0", "@jridgewell/trace-mapping": "^0.3.24" } }, "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA=="],
|
||||||
|
|
||||||
|
"@jridgewell/remapping": ["@jridgewell/remapping@2.3.5", "", { "dependencies": { "@jridgewell/gen-mapping": "^0.3.5", "@jridgewell/trace-mapping": "^0.3.24" } }, "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ=="],
|
||||||
|
|
||||||
|
"@jridgewell/resolve-uri": ["@jridgewell/resolve-uri@3.1.2", "", {}, "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw=="],
|
||||||
|
|
||||||
|
"@jridgewell/sourcemap-codec": ["@jridgewell/sourcemap-codec@1.6.0", "", {}, "sha512-T7jf+5zgsZHwNJ4lvQ7/aezbyk0nNX+zJVWpmHA7VYsEx7a7qr5Rg5IbtJFqkgze5Y2sruq1RUY8Q837Od7iFw=="],
|
||||||
|
|
||||||
|
"@jridgewell/trace-mapping": ["@jridgewell/trace-mapping@0.3.31", "", { "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" } }, "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw=="],
|
||||||
|
|
||||||
|
"@mermaid-js/layout-tidy-tree": ["@mermaid-js/layout-tidy-tree@1.0.1", "", { "dependencies": { "d3": "^7.9.0" }, "peerDependencies": { "mermaid": "^11.0.2 || ^12.0.0" } }, "sha512-suZgFgQQHYuAxiEiNVgPJwOoXi/keXV6DghCL3rT4K9DmX7xYQ2XZI2suiBVs/fj1gn/OoXIWB2DFSmeY7trvw=="],
|
||||||
|
|
||||||
|
"@mermaid-js/mermaid-cli": ["@mermaid-js/mermaid-cli@12.0.0", "", { "dependencies": { "@fontsource-variable/recursive": "^5.3.0", "@fontsource/open-sans": "^5.3.0", "@fortawesome/fontawesome-free": "^7.0.1", "@mermaid-js/mermaid-zenuml": "^1.0.1", "chalk": "^6.0.0", "commander": "^15.0.0", "import-meta-resolve": "^4.1.0", "katex": "^0.16.25", "mermaid": "^12.0.0", "p-limit": "^7.0.0" }, "optionalDependencies": { "@mermaid-js/layout-tidy-tree": "^1.0.1" }, "peerDependencies": { "puppeteer": "^25.0.0" }, "bin": { "mmdc": "src/cli.js" } }, "sha512-AA18uaJtWVlM5PX7RGBxrVrqTTesmEaWCmfV+l5RkD6A1CnpUAtPpL+wWhkQAZrDSfyAw5FZyj084MsnDIPY3g=="],
|
||||||
|
|
||||||
|
"@mermaid-js/mermaid-zenuml": ["@mermaid-js/mermaid-zenuml@1.0.1", "", { "dependencies": { "@zenuml/core": "^3.47.9" }, "peerDependencies": { "mermaid": "^10 || ^11 || ^12" } }, "sha512-O5DiRODoFVNgugOVloxcDXmd+bXe/sbGlDh3onnzuE4EWtgTWwaAlWuPPOXbU9QESsztnD4Gtnu7dr+tYLFE0A=="],
|
||||||
|
|
||||||
|
"@mermaid-js/parser": ["@mermaid-js/parser@2.0.1", "", { "dependencies": { "@chevrotain/types": "~13.2.0" } }, "sha512-j37dj/h6p6pots1L7pLPPNuABEEu9WP4OYg9pW1g+nYG331j0+3canE9OagtYdytYvdSAMG+2fKU5cxep6LgjA=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas": ["@napi-rs/canvas@0.1.100", "", { "optionalDependencies": { "@napi-rs/canvas-android-arm64": "0.1.100", "@napi-rs/canvas-darwin-arm64": "0.1.100", "@napi-rs/canvas-darwin-x64": "0.1.100", "@napi-rs/canvas-linux-arm-gnueabihf": "0.1.100", "@napi-rs/canvas-linux-arm64-gnu": "0.1.100", "@napi-rs/canvas-linux-arm64-musl": "0.1.100", "@napi-rs/canvas-linux-riscv64-gnu": "0.1.100", "@napi-rs/canvas-linux-x64-gnu": "0.1.100", "@napi-rs/canvas-linux-x64-musl": "0.1.100", "@napi-rs/canvas-win32-arm64-msvc": "0.1.100", "@napi-rs/canvas-win32-x64-msvc": "0.1.100" } }, "sha512-xglYA6q3XO5P3BNJYxVZ1IV7DLVjp1Py6nwag88YntrS+3vKHyYcMqXVS4ZztJmwz2uGvz1FWhI/4LgbR5uQDA=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-android-arm64": ["@napi-rs/canvas-android-arm64@0.1.100", "", { "os": "android", "cpu": "arm64" }, "sha512-hjhCKhntPv9+t4ckHymdx0phYNcVW+GKQR6Lzw2zE+pOVjOplSmtx9nNNknTjbEDLcuLZqA1y8ufKg1XfgftzQ=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-darwin-arm64": ["@napi-rs/canvas-darwin-arm64@0.1.100", "", { "os": "darwin", "cpu": "arm64" }, "sha512-2PcswRaC7Ly645DGt88///zuFDhJxJYdKAs1uU3mfk1atYkXufgcgLfBpk6Tm12nCQBaNt1wpybuPZ4qOhTo8A=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-darwin-x64": ["@napi-rs/canvas-darwin-x64@0.1.100", "", { "os": "darwin", "cpu": "x64" }, "sha512-ePNZtj7pNIva/siZMg+HmbeozkIjqUIYdoymH8HaA3qK7LfzFN4WMBM8G6HQ9ZC+H3+Dnn5pqtiXpgLykaPOhw=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-linux-arm-gnueabihf": ["@napi-rs/canvas-linux-arm-gnueabihf@0.1.100", "", { "os": "linux", "cpu": "arm" }, "sha512-d5cDB48oWFGU8/XPhUOFAlySgb/VAu7D+s8fi55K1Pcfg8aPplHWqMgibhVLU8ky7Pyg/fuiVLz4Nf3JrSTuUA=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-linux-arm64-gnu": ["@napi-rs/canvas-linux-arm64-gnu@0.1.100", "", { "os": "linux", "cpu": "arm64" }, "sha512-rDxgxRu69RvDlX/bh9o22DxLsGr8EqsNgotL9+RwQE1S0b0cqeatqsw6aW45mukm0B42DIAaAacKaYQ8cqS1nw=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-linux-arm64-musl": ["@napi-rs/canvas-linux-arm64-musl@0.1.100", "", { "os": "linux", "cpu": "arm64" }, "sha512-K3mDW66N+xT2/V439u1alFANiBUjdEx2gLiNYnCmUsva5jZMxWTjafBYwTzYK+EMFMHrUoabuU+T1BIP5CgbYQ=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-linux-riscv64-gnu": ["@napi-rs/canvas-linux-riscv64-gnu@0.1.100", "", { "os": "linux", "cpu": "none" }, "sha512-mooqUBTIsccZpnoQC4NgrC1v6C1vof39etLNMnBwCY+p0gajWJvAHLGQ6g/gGyS5YrpDW+GefSN4+Cvcr08UWw=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-linux-x64-gnu": ["@napi-rs/canvas-linux-x64-gnu@0.1.100", "", { "os": "linux", "cpu": "x64" }, "sha512-1eCvkDCazm7FFhsT7DfGOdSaHgZVK3bt/dSBl5EWHOWmnz+I7j8tPseJqqD81NF+MH21jKUK4wQSDjN0mdhnTg=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-linux-x64-musl": ["@napi-rs/canvas-linux-x64-musl@0.1.100", "", { "os": "linux", "cpu": "x64" }, "sha512-20arT6lnI19S68qNlii73TSEDbECNgzMz2EpldC1V3mZFuRkeujXkcebRk0LRJe9SEUAooYiLokfMViY8IX7yA=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-win32-arm64-msvc": ["@napi-rs/canvas-win32-arm64-msvc@0.1.100", "", { "os": "win32", "cpu": "arm64" }, "sha512-DZFFT1wIAg37LJw37yhMRFfjATd3vTQzjZ1Yki8u2vhO6Hi5VE6BVaGQ1aaDu7xb4iMErz+9EOwjpS7xcxFeBw=="],
|
||||||
|
|
||||||
|
"@napi-rs/canvas-win32-x64-msvc": ["@napi-rs/canvas-win32-x64-msvc@0.1.100", "", { "os": "win32", "cpu": "x64" }, "sha512-MyT1j3mHC2+Lu4pBi9mKyMJhtP6U7k7EldY7sj/uS5gJA65gTXt8MefJQXLJo5d/vZbuWmfxzkEUNc/urV3pHA=="],
|
||||||
|
|
||||||
|
"@napi-rs/lzma-linux-x64-gnu": ["@napi-rs/lzma-linux-x64-gnu@1.5.1", "", { "os": "linux", "cpu": "x64" }, "sha512-oTXEIha4SsuXdTA4Iyskj0kpdx2yVXdhd75c2v3xGrHFfVMsbhTPZU/nMPL4sWKo4pBHm3aucLaqGlF696dTyQ=="],
|
||||||
|
|
||||||
|
"@phosphor-icons/core": ["@phosphor-icons/core@2.1.1", "", {}, "sha512-v4ARvrip4qBCImOE5rmPUylOEK4iiED9ZyKjcvzuezqMaiRASCHKcRIuvvxL/twvLpkfnEODCOJp5dM4eZilxQ=="],
|
||||||
|
|
||||||
|
"@phosphor-icons/react": ["@phosphor-icons/react@2.1.10", "", { "peerDependencies": { "react": ">= 16.8", "react-dom": ">= 16.8" } }, "sha512-vt8Tvq8GLjheAZZYa+YG/pW7HDbov8El/MANW8pOAz4eGxrwhnbfrQZq0Cp4q8zBEu8NIhHdnr+r8thnfRSNYA=="],
|
||||||
|
|
||||||
|
"@puppeteer/browsers": ["@puppeteer/browsers@3.2.6", "", { "dependencies": { "modern-tar": "^0.8.6", "yargs": "^18.0.0" }, "peerDependencies": { "proxy-agent": ">=8.0.1", "yauzl": "^2.10.0 || ^3.4.0" }, "optionalPeers": ["proxy-agent", "yauzl"], "bin": { "browsers": "lib/main-cli.js" } }, "sha512-MJP29gVoHznmqmwhH1tlZqzfeQ3aylTpSSa6WKZXtkwYUH02i9imBmWGTyZrbnAou5paX78SE4jMAUqnEPf8ug=="],
|
||||||
|
|
||||||
|
"@react-aria/focus": ["@react-aria/focus@3.22.1", "", { "dependencies": { "@swc/helpers": "^0.5.0", "react-aria": "^3.48.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-CPxtkyrBi/HYY5P3lE/57sQ6qfa0lN8E55TOm89H0kNGv0lKt+/0zP7lWERzBjRr5IxBVrQX4gFEowBN52LPaA=="],
|
||||||
|
|
||||||
|
"@react-aria/interactions": ["@react-aria/interactions@3.28.1", "", { "dependencies": { "@react-types/shared": "^3.34.0", "@swc/helpers": "^0.5.0", "react-aria": "^3.48.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-Bqb+HrD5I5MHS2SKBhISYqo2SW8Y2dfzgF/Y1lIJq7xqLxheo9vzxPGEHhz+XzkgGfoqEJx8A6a3C7uiqS3HWA=="],
|
||||||
|
|
||||||
|
"@react-types/shared": ["@react-types/shared@3.37.0", "", { "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-VNlZuifu4tHdxWPfHvoMfKsHA9kVTCGkduv5vKVTdinm8wHFJNhyVB5RzIMiRFj0q3RKoCbP68u2zaoBSiFueg=="],
|
||||||
|
|
||||||
|
"@rolldown/pluginutils": ["@rolldown/pluginutils@1.0.0-beta.27", "", {}, "sha512-+d0F4MKMCbeVUJwG96uQ4SgAznZNSq93I3V+9NHA4OpvqG8mRCpGdKmK8l/dl02h2CCDHwW2FqilnTyDcAnqjA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-android-arm-eabi": ["@rollup/rollup-android-arm-eabi@4.66.0", "", { "os": "android", "cpu": "arm" }, "sha512-7y4XeoUHPecjfUDRmap8U0q6bjfLAPn7uOGT8BKyqy8uNDOjsGS8rlBhOx6sZLVwwjN6hapvGl2mW9/IS6UNww=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-android-arm64": ["@rollup/rollup-android-arm64@4.66.0", "", { "os": "android", "cpu": "arm64" }, "sha512-e8WugYZXpgqrlMXLCudYVRAxAcK7AIY36JxRDwFRD38L9q62G1VsEUW6ijXxzjxYjNB8i1zo3B/ycIQ/qjLC/Q=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-darwin-arm64": ["@rollup/rollup-darwin-arm64@4.66.0", "", { "os": "darwin", "cpu": "arm64" }, "sha512-6vkDCfyDjNLokh+Rt1D2KtNgFFMEPdkWha/mbtP4cSjh9xiN8T/JBS/A7nDYKjmMAXHrvR9J3AzUk2LtFbIBLg=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-darwin-x64": ["@rollup/rollup-darwin-x64@4.66.0", "", { "os": "darwin", "cpu": "x64" }, "sha512-/mzZAX0+Q6eXxvkR0HB0RZCCrsbmFD8DpsvCQoMYABDfq/DjqkbfytuJ7GvZ4AhR/Mgis2fXbZrGqfbcK2Z5fA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-freebsd-arm64": ["@rollup/rollup-freebsd-arm64@4.66.0", "", { "os": "freebsd", "cpu": "arm64" }, "sha512-JQJx9E8tUjGqed1RevDmoHaS3V30ODdV8uyvGxlwd4K5se6bkPrMeltSybqAtpJ+ltDRfo7FORQaJG2Hd5nGog=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-freebsd-x64": ["@rollup/rollup-freebsd-x64@4.66.0", "", { "os": "freebsd", "cpu": "x64" }, "sha512-GEaUQQjMaG7X1304qMgqLjzCKv6CdDirzJSS+UqUs3xhJ9X2Kjzu0JDbLoUU42FWxwmZqz+SsgU1SlQv9GNRVA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm-gnueabihf": ["@rollup/rollup-linux-arm-gnueabihf@4.66.0", "", { "os": "linux", "cpu": "arm" }, "sha512-DgmAU9N0NhDQDzHgFUocDio7zRO8jR/nY/obDGvCR8zbJ6J77Fg6X49yPuExJUpYPbC82EOaRhG969pWzUSnHQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm-musleabihf": ["@rollup/rollup-linux-arm-musleabihf@4.66.0", "", { "os": "linux", "cpu": "arm" }, "sha512-zG09YZ+sk/HoHq+P9gYB0EseQ3M20RbDuKGWey6fbiMDV1LxfXvhgSW9jDaCcvFPMgfLXpimzXY+UYvA8R2mLQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm64-gnu": ["@rollup/rollup-linux-arm64-gnu@4.66.0", "", { "os": "linux", "cpu": "arm64" }, "sha512-vlArhgyXbcVc1D4WZPoiYuqJIaMiSHBj6etRXua0KlfjlZeuiQyVAPYi0/N49O4mSp3u1iGUBLEjNa8ec81XZg=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm64-musl": ["@rollup/rollup-linux-arm64-musl@4.66.0", "", { "os": "linux", "cpu": "arm64" }, "sha512-RxJZtk0G87YPotDaRDvRqStV8cbqLSC5TroHvQHHKsqBg0ok64RxKgtXeFsa7FBcy7mb4crBrG3xK8USWIqWNA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-loong64-gnu": ["@rollup/rollup-linux-loong64-gnu@4.66.0", "", { "os": "linux", "cpu": "none" }, "sha512-qlGcw959PrLLkZhiBxF3OZ6SQvj+OKY85mCqGNgSRs4LZlDJ6ICqmz6UdxtINdhcXYwNIbZoapQVBAmZlD2hUQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-loong64-musl": ["@rollup/rollup-linux-loong64-musl@4.66.0", "", { "os": "linux", "cpu": "none" }, "sha512-TvTI/7Cy0WvRA1SXgwzu6bwXBnMpmeT/ln5q7WvSpqmXy1VbmEnY8HVIDQNBiaHJvoWqRr0M4FNo7qiqtyMaFw=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-ppc64-gnu": ["@rollup/rollup-linux-ppc64-gnu@4.66.0", "", { "os": "linux", "cpu": "ppc64" }, "sha512-UZEDkSoDRZ50NyLj70nO6mpIK3dvs2cPTTvQb1bA/PBDmr9fvn5KiESuGfh6srd7Zi6Lt9Sv2sVrFr1QoHLvPQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-ppc64-musl": ["@rollup/rollup-linux-ppc64-musl@4.66.0", "", { "os": "linux", "cpu": "ppc64" }, "sha512-VRbxTvagLh3HRcysx1CNq+HHcvJbSebNI6fCbk7jwmmWHkXjrSIV3igXBpRHUTFdg0pagWGu50xoSZXnrZHjVQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-riscv64-gnu": ["@rollup/rollup-linux-riscv64-gnu@4.66.0", "", { "os": "linux", "cpu": "none" }, "sha512-uWdJpvYqh0LE/i+YBL3sMX0a2kUkICENjmrPmyBmMOFc3jMrs6MSQH/pMD+VIpGEoUcr3XkHGLLfymzIqPSRRg=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-riscv64-musl": ["@rollup/rollup-linux-riscv64-musl@4.66.0", "", { "os": "linux", "cpu": "none" }, "sha512-3FUd88pxgWAjK60OgCrika1AcNG+u8zaCdWjg4TlcZTDkt5TGyci8ZU64l3OJ9ax0MEjw3P80B/3PoSQDCLwJQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-s390x-gnu": ["@rollup/rollup-linux-s390x-gnu@4.66.0", "", { "os": "linux", "cpu": "s390x" }, "sha512-qT2rMmgyej62g5AdwktK+Bt2lBu497pzWZe12TTQ5JmZjOYPnEwcPEAOSLTBxBV+6gIES75rXm219v/QkT397A=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-x64-gnu": ["@rollup/rollup-linux-x64-gnu@4.66.0", "", { "os": "linux", "cpu": "x64" }, "sha512-E46rnZgp7J84Qwe8RMlF+rgimnDo/9fuiGbUArGB0ZkMWf97O7yeSCfKls5x/YJOF0RcuSe9RctuKe1hlxICiA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-x64-musl": ["@rollup/rollup-linux-x64-musl@4.66.0", "", { "os": "linux", "cpu": "x64" }, "sha512-Uz1HiZe+qBzqgdPsON+z0wRx3WdATuyzwvGT6cr2VZVrqqko0ZJVfkrQJtwDMuDcAfXYdo7XucaxJ7lTLjEcgg=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-openbsd-x64": ["@rollup/rollup-openbsd-x64@4.66.0", "", { "os": "openbsd", "cpu": "x64" }, "sha512-Ph7TX3Ex5qdfcb7Tc6eEPugVkRfJ501eTovO4T5029YObfpZ7dzn3RiwpFvGp50nk2QUhvBMZ0PFGlEj6pOYTg=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-openharmony-arm64": ["@rollup/rollup-openharmony-arm64@4.66.0", "", { "os": "none", "cpu": "arm64" }, "sha512-nZYPEya7ZkeNxUEiF7qmNZbyLTyRN3MK5cO22KqsaoneUzXJuzBIQRw+7BEQy9LGj2O5vrCE9V3EpK06FYo1tQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-arm64-msvc": ["@rollup/rollup-win32-arm64-msvc@4.66.0", "", { "os": "win32", "cpu": "arm64" }, "sha512-u7aTfS3R6C4hRsqXSzaO6qLZYLVuMkHMvcWlux4IM8IJif1VCl2cgPBSo5gSNoFoStQypQP+qwq8W1IyFBf1QQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-ia32-msvc": ["@rollup/rollup-win32-ia32-msvc@4.66.0", "", { "os": "win32", "cpu": "ia32" }, "sha512-e+i9ueHrH1Bafb0cf0woAIVJbYcoC8vRaD+vz+Xi8w6jz9cYJSV3vyKO6ELGSZ6g4W4MJOm2WPLN4/nQf77h7w=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-x64-gnu": ["@rollup/rollup-win32-x64-gnu@4.66.0", "", { "os": "win32", "cpu": "x64" }, "sha512-KfTCbrtr2zXTqH2E1F+uYlFTrYibxHKqPAHobpd8Kfg49cEHmuHebOidCTDRgqG1suaPFX7oejFQeGE71zWKfA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-x64-msvc": ["@rollup/rollup-win32-x64-msvc@4.66.0", "", { "os": "win32", "cpu": "x64" }, "sha512-xA+neBh1bqkqaS3b48T2UHZnDsTIpb9B0h+TdBzynjF/ymCpYndhfY10RqW0qSKB1HqqQA83mINVhAdwA+mETg=="],
|
||||||
|
|
||||||
|
"@storebound/desktop": ["@storebound/desktop@workspace:apps/desktop"],
|
||||||
|
|
||||||
|
"@swc/helpers": ["@swc/helpers@0.5.23", "", { "dependencies": { "tslib": "^2.8.0" } }, "sha512-5lSsMOTXURePglDfvuAQUqkGek9Hg2kksOYay2m0+XR++b2NWYL/4sWyuvVBIs8oKnJaxkdi9whaL/sqN13afw=="],
|
||||||
|
|
||||||
|
"@tanstack/react-virtual": ["@tanstack/react-virtual@3.14.23", "", { "dependencies": { "@tanstack/virtual-core": "3.19.8" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "sha512-Oyy58qQwdaQieA+A4WUDtnh9D1rv5FZvGdw8og9Xeyh88V6HH94vMSyV5i9ATIbYNe9t5Ix0WXRo9NOTpHDkYw=="],
|
||||||
|
|
||||||
|
"@tanstack/virtual-core": ["@tanstack/virtual-core@3.19.8", "", {}, "sha512-Oz/SYBo/aVPyQkwtOw7Q23myITUgFIof2glQqydYJAPL6mH2SkJDkvDKZTklB+7gv5jGLZQhyTcd7SO1A1EODQ=="],
|
||||||
|
|
||||||
|
"@tauri-apps/api": ["@tauri-apps/api@2.12.4", "", {}, "sha512-pVmfis+4zT8H0Qhp3xPZx9Ju7kpzvA6rr/PSJPyuwfvucTQ8sVt61NYU9KMkK703UFlYadFmjKA4HhybOtN0gg=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli": ["@tauri-apps/cli@2.12.4", "", { "optionalDependencies": { "@tauri-apps/cli-darwin-arm64": "2.12.4", "@tauri-apps/cli-darwin-x64": "2.12.4", "@tauri-apps/cli-linux-arm-gnueabihf": "2.12.4", "@tauri-apps/cli-linux-arm64-gnu": "2.12.4", "@tauri-apps/cli-linux-arm64-musl": "2.12.4", "@tauri-apps/cli-linux-riscv64-gnu": "2.12.4", "@tauri-apps/cli-linux-x64-gnu": "2.12.4", "@tauri-apps/cli-linux-x64-musl": "2.12.4", "@tauri-apps/cli-win32-arm64-msvc": "2.12.4", "@tauri-apps/cli-win32-ia32-msvc": "2.12.4", "@tauri-apps/cli-win32-x64-msvc": "2.12.4" }, "bin": { "tauri": "tauri.js" } }, "sha512-JI9bHfudSRJikGOrjbXEm6RjzzvmKuLc+JixB1NE8hNzQkNlCCIC3pTES3uypkR9lxHrsbxzcnSwhI2IxBQphw=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-darwin-arm64": ["@tauri-apps/cli-darwin-arm64@2.12.4", "", { "os": "darwin", "cpu": "arm64" }, "sha512-OxqKSckIkoJ6vX2AjifIJpTasFC0Hbdoo7gEiCmAjauABO3U8m2MRsLWe+QTiBwDx1mIrvgA+rvI7tvDnbnHVg=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-darwin-x64": ["@tauri-apps/cli-darwin-x64@2.12.4", "", { "os": "darwin", "cpu": "x64" }, "sha512-fz76/77wMMJOaaUN6n3CybRG0P/MTEjjqYk81mGPyhi9m6Ue5T+LWBnJP/AkPooNatBPI2vtulGqomyMJ44lCQ=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-linux-arm-gnueabihf": ["@tauri-apps/cli-linux-arm-gnueabihf@2.12.4", "", { "os": "linux", "cpu": "arm" }, "sha512-K0w8Bof6Lt8QKLAYhRy0yy36ZH5iA/35VuSOvnxyjvCUZ+A3JKsUTlALviH/sVgAlisaPzzmeJSH8XOn4Q2HBA=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-linux-arm64-gnu": ["@tauri-apps/cli-linux-arm64-gnu@2.12.4", "", { "os": "linux", "cpu": "arm64" }, "sha512-j5rOnjmRUwWrm1oosf0zBYl4D+fqydgUROFCk0hvKZxvbTT8SOERes0QB7rBV/XWNy+kM6pCKzb3oSm2sRglzg=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-linux-arm64-musl": ["@tauri-apps/cli-linux-arm64-musl@2.12.4", "", { "os": "linux", "cpu": "arm64" }, "sha512-aOue3Fy6Jb7+oWcfAVUsVHfeTybSCt2CZoU06aO4jv4d2Ks/KnaTPwMAK3CLEduGOvBLY1lbBBrIyomqLLH5Sg=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-linux-riscv64-gnu": ["@tauri-apps/cli-linux-riscv64-gnu@2.12.4", "", { "os": "linux", "cpu": "none" }, "sha512-Fx6GShY/RvST+t6LMlTHAwd66+1tEaAAGrnU7cysVfaiRP1BKng5Vl6rVmO6rSLOA1Sp1dRzNYM4f0OWQGb7qA=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-linux-x64-gnu": ["@tauri-apps/cli-linux-x64-gnu@2.12.4", "", { "os": "linux", "cpu": "x64" }, "sha512-tNzZSa79Z1nRpHxEpQ38lsAFpKlFlYvoXzjTV+lRRn/zSf3wrdUC3wnLcq2XEadchPu4ttK0zivhYzr+XGD19Q=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-linux-x64-musl": ["@tauri-apps/cli-linux-x64-musl@2.12.4", "", { "os": "linux", "cpu": "x64" }, "sha512-jmZ1pr0xEqUhuEusWtt9Yt+GF6lCnGHUmIL+KIknpbjK/XQ2qkhDBhaxK/JMHM2A8dAacVXCxXJk2EXpwhQUfA=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-win32-arm64-msvc": ["@tauri-apps/cli-win32-arm64-msvc@2.12.4", "", { "os": "win32", "cpu": "arm64" }, "sha512-fGo8pgEHZxdSYgZ/J98m1usJ7NHKmKbq7k6uT0x1rpOq6Bg2YVzzpaAblWk710f5LHYBJIL5QIFS5IrD+4gmTg=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-win32-ia32-msvc": ["@tauri-apps/cli-win32-ia32-msvc@2.12.4", "", { "os": "win32", "cpu": "ia32" }, "sha512-ezl8sQIcjYsye3TUnTH5VcWmWzccZASlQm7hlZt0dYyj1XD0qpVW47u2xYVrIKui0F8uQv/7QGZixdWiClBsbg=="],
|
||||||
|
|
||||||
|
"@tauri-apps/cli-win32-x64-msvc": ["@tauri-apps/cli-win32-x64-msvc@2.12.4", "", { "os": "win32", "cpu": "x64" }, "sha512-DJhDeCqjLDNMWYFy7ZS8cfeAHX2RK0RbQMLiA3bMVVkXRDJ4NBYiHriGqsUhsr9iG41aTb+dJGkFPmPw1gWwVw=="],
|
||||||
|
|
||||||
|
"@types/babel__core": ["@types/babel__core@7.20.5", "", { "dependencies": { "@babel/parser": "^7.20.7", "@babel/types": "^7.20.7", "@types/babel__generator": "*", "@types/babel__template": "*", "@types/babel__traverse": "*" } }, "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA=="],
|
||||||
|
|
||||||
|
"@types/babel__generator": ["@types/babel__generator@7.27.0", "", { "dependencies": { "@babel/types": "^7.0.0" } }, "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg=="],
|
||||||
|
|
||||||
|
"@types/babel__template": ["@types/babel__template@7.4.4", "", { "dependencies": { "@babel/parser": "^7.1.0", "@babel/types": "^7.0.0" } }, "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A=="],
|
||||||
|
|
||||||
|
"@types/babel__traverse": ["@types/babel__traverse@7.28.0", "", { "dependencies": { "@babel/types": "^7.28.2" } }, "sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q=="],
|
||||||
|
|
||||||
|
"@types/bun": ["@types/bun@1.3.0", "", { "dependencies": { "bun-types": "1.3.0" } }, "sha512-+lAGCYjXjip2qY375xX/scJeVRmZ5cY0wyHYyCYxNcdEXrQ4AOe3gACgd4iQ8ksOslJtW4VNxBJ8llUwc3a6AA=="],
|
||||||
|
|
||||||
|
"@types/d3": ["@types/d3@7.4.3", "", { "dependencies": { "@types/d3-array": "*", "@types/d3-axis": "*", "@types/d3-brush": "*", "@types/d3-chord": "*", "@types/d3-color": "*", "@types/d3-contour": "*", "@types/d3-delaunay": "*", "@types/d3-dispatch": "*", "@types/d3-drag": "*", "@types/d3-dsv": "*", "@types/d3-ease": "*", "@types/d3-fetch": "*", "@types/d3-force": "*", "@types/d3-format": "*", "@types/d3-geo": "*", "@types/d3-hierarchy": "*", "@types/d3-interpolate": "*", "@types/d3-path": "*", "@types/d3-polygon": "*", "@types/d3-quadtree": "*", "@types/d3-random": "*", "@types/d3-scale": "*", "@types/d3-scale-chromatic": "*", "@types/d3-selection": "*", "@types/d3-shape": "*", "@types/d3-time": "*", "@types/d3-time-format": "*", "@types/d3-timer": "*", "@types/d3-transition": "*", "@types/d3-zoom": "*" } }, "sha512-lZXZ9ckh5R8uiFVt8ogUNf+pIrK4EsWrx2Np75WvF/eTpJ0FMHNhjXk8CKEx/+gpHbNQyJWehbFaTvqmHWB3ww=="],
|
||||||
|
|
||||||
|
"@types/d3-array": ["@types/d3-array@3.0.3", "", {}, "sha512-Reoy+pKnvsksN0lQUlcH6dOGjRZ/3WRwXR//m+/8lt1BXeI4xyaUZoqULNjyXXRuh0Mj4LNpkCvhUpQlY3X5xQ=="],
|
||||||
|
|
||||||
|
"@types/d3-axis": ["@types/d3-axis@3.0.6", "", { "dependencies": { "@types/d3-selection": "*" } }, "sha512-pYeijfZuBd87T0hGn0FO1vQ/cgLk6E1ALJjfkC0oJ8cbwkZl3TpgS8bVBLZN+2jjGgg38epgxb2zmoGtSfvgMw=="],
|
||||||
|
|
||||||
|
"@types/d3-brush": ["@types/d3-brush@3.0.6", "", { "dependencies": { "@types/d3-selection": "*" } }, "sha512-nH60IZNNxEcrh6L1ZSMNA28rj27ut/2ZmI3r96Zd+1jrZD++zD3LsMIjWlvg4AYrHn/Pqz4CF3veCxGjtbqt7A=="],
|
||||||
|
|
||||||
|
"@types/d3-chord": ["@types/d3-chord@3.0.6", "", {}, "sha512-LFYWWd8nwfwEmTZG9PfQxd17HbNPksHBiJHaKuY1XeqscXacsS2tyoo6OdRsjf+NQYeB6XrNL3a25E3gH69lcg=="],
|
||||||
|
|
||||||
|
"@types/d3-color": ["@types/d3-color@3.1.0", "", {}, "sha512-HKuicPHJuvPgCD+np6Se9MQvS6OCbJmOjGvylzMJRlDwUXjKTTXs6Pwgk79O09Vj/ho3u1ofXnhFOaEWWPrlwA=="],
|
||||||
|
|
||||||
|
"@types/d3-contour": ["@types/d3-contour@3.0.6", "", { "dependencies": { "@types/d3-array": "*", "@types/geojson": "*" } }, "sha512-BjzLgXGnCWjUSYGfH1cpdo41/hgdWETu4YxpezoztawmqsvCeep+8QGfiY6YbDvfgHz/DkjeIkkZVJavB4a3rg=="],
|
||||||
|
|
||||||
|
"@types/d3-delaunay": ["@types/d3-delaunay@6.0.1", "", {}, "sha512-tLxQ2sfT0p6sxdG75c6f/ekqxjyYR0+LwPrsO1mbC9YDBzPJhs2HbJJRrn8Ez1DBoHRo2yx7YEATI+8V1nGMnQ=="],
|
||||||
|
|
||||||
|
"@types/d3-dispatch": ["@types/d3-dispatch@3.0.7", "", {}, "sha512-5o9OIAdKkhN1QItV2oqaE5KMIiXAvDWBDPrD85e58Qlz1c1kI/J0NcqbEG88CoTwJrYe7ntUCVfeUl2UJKbWgA=="],
|
||||||
|
|
||||||
|
"@types/d3-drag": ["@types/d3-drag@3.0.7", "", { "dependencies": { "@types/d3-selection": "*" } }, "sha512-HE3jVKlzU9AaMazNufooRJ5ZpWmLIoc90A37WU2JMmeq28w1FQqCZswHZ3xR+SuxYftzHq6WU6KJHvqxKzTxxQ=="],
|
||||||
|
|
||||||
|
"@types/d3-dsv": ["@types/d3-dsv@3.0.7", "", {}, "sha512-n6QBF9/+XASqcKK6waudgL0pf/S5XHPPI8APyMLLUHd8NqouBGLsU8MgtO7NINGtPBtk9Kko/W4ea0oAspwh9g=="],
|
||||||
|
|
||||||
|
"@types/d3-ease": ["@types/d3-ease@3.0.2", "", {}, "sha512-NcV1JjO5oDzoK26oMzbILE6HW7uVXOHLQvHshBUW4UMdZGfiY6v5BeQwh9a9tCzv+CeefZQHJt5SRgK154RtiA=="],
|
||||||
|
|
||||||
|
"@types/d3-fetch": ["@types/d3-fetch@3.0.7", "", { "dependencies": { "@types/d3-dsv": "*" } }, "sha512-fTAfNmxSb9SOWNB9IoG5c8Hg6R+AzUHDRlsXsDZsNp6sxAEOP0tkP3gKkNSO/qmHPoBFTxNrjDprVHDQDvo5aA=="],
|
||||||
|
|
||||||
|
"@types/d3-force": ["@types/d3-force@3.0.10", "", {}, "sha512-ZYeSaCF3p73RdOKcjj+swRlZfnYpK1EbaDiYICEEp5Q6sUiqFaFQ9qgoshp5CzIyyb/yD09kD9o2zEltCexlgw=="],
|
||||||
|
|
||||||
|
"@types/d3-format": ["@types/d3-format@3.0.1", "", {}, "sha512-5KY70ifCCzorkLuIkDe0Z9YTf9RR2CjBX1iaJG+rgM/cPP+sO+q9YdQ9WdhQcgPj1EQiJ2/0+yUkkziTG6Lubg=="],
|
||||||
|
|
||||||
|
"@types/d3-geo": ["@types/d3-geo@3.1.0", "", { "dependencies": { "@types/geojson": "*" } }, "sha512-856sckF0oP/diXtS4jNsiQw/UuK5fQG8l/a9VVLeSouf1/PPbBE1i1W852zVwKwYCBkFJJB7nCFTbk6UMEXBOQ=="],
|
||||||
|
|
||||||
|
"@types/d3-hierarchy": ["@types/d3-hierarchy@3.1.7", "", {}, "sha512-tJFtNoYBtRtkNysX1Xq4sxtjK8YgoWUNpIiUee0/jHGRwqvzYxkq0hGVbbOGSz+JgFxxRu4K8nb3YpG3CMARtg=="],
|
||||||
|
|
||||||
|
"@types/d3-interpolate": ["@types/d3-interpolate@3.0.1", "", { "dependencies": { "@types/d3-color": "*" } }, "sha512-jx5leotSeac3jr0RePOH1KdR9rISG91QIE4Q2PYTu4OymLTZfA3SrnURSLzKH48HmXVUru50b8nje4E79oQSQw=="],
|
||||||
|
|
||||||
|
"@types/d3-path": ["@types/d3-path@3.1.1", "", {}, "sha512-VMZBYyQvbGmWyWVea0EHs/BwLgxc+MKi1zLDCONksozI4YJMcTt8ZEuIR4Sb1MMTE8MMW49v0IwI5+b7RmfWlg=="],
|
||||||
|
|
||||||
|
"@types/d3-polygon": ["@types/d3-polygon@3.0.2", "", {}, "sha512-ZuWOtMaHCkN9xoeEMr1ubW2nGWsp4nIql+OPQRstu4ypeZ+zk3YKqQT0CXVe/PYqrKpZAi+J9mTs05TKwjXSRA=="],
|
||||||
|
|
||||||
|
"@types/d3-quadtree": ["@types/d3-quadtree@3.0.6", "", {}, "sha512-oUzyO1/Zm6rsxKRHA1vH0NEDG58HrT5icx/azi9MF1TWdtttWl0UIUsjEQBBh+SIkrpd21ZjEv7ptxWys1ncsg=="],
|
||||||
|
|
||||||
|
"@types/d3-random": ["@types/d3-random@3.0.4", "", {}, "sha512-UHYId5WTCx4L4YNel7NU00XUXXgvgpgZOvp10PuvsQENjMDXhh2RyFc0KBjO7B45ne4Ha1yVH7ii0vnzKkuzWA=="],
|
||||||
|
|
||||||
|
"@types/d3-scale": ["@types/d3-scale@4.0.2", "", { "dependencies": { "@types/d3-time": "*" } }, "sha512-Yk4htunhPAwN0XGlIwArRomOjdoBFXC3+kCxK2Ubg7I9shQlVSJy/pG/Ht5ASN+gdMIalpk8TJ5xV74jFsetLA=="],
|
||||||
|
|
||||||
|
"@types/d3-scale-chromatic": ["@types/d3-scale-chromatic@3.1.0", "", {}, "sha512-iWMJgwkK7yTRmWqRB5plb1kadXyQ5Sj8V/zYlFGMUBbIPKQScw+Dku9cAAMgJG+z5GYDoMjWGLVOvjghDEFnKQ=="],
|
||||||
|
|
||||||
|
"@types/d3-selection": ["@types/d3-selection@3.0.12", "", {}, "sha512-Qe/KWYhEiIIxGs7HrAAjMfShxKldx19SJtr5zu53f3afPsdZNz7HHtdTLXo/kqeiWNXVycI24kSnfzBYkTzpgw=="],
|
||||||
|
|
||||||
|
"@types/d3-shape": ["@types/d3-shape@3.1.7", "", { "dependencies": { "@types/d3-path": "*" } }, "sha512-VLvUQ33C+3J+8p+Daf+nYSOsjB4GXp19/S/aGo60m9h1v6XaxjiT82lKVWJCfzhtuZ3yD7i/TPeC/fuKLLOSmg=="],
|
||||||
|
|
||||||
|
"@types/d3-time": ["@types/d3-time@3.0.0", "", {}, "sha512-sZLCdHvBUcNby1cB6Fd3ZBrABbjz3v1Vm90nysCQ6Vt7vd6e/h9Lt7SiJUoEX0l4Dzc7P5llKyhqSi1ycSf1Hg=="],
|
||||||
|
|
||||||
|
"@types/d3-time-format": ["@types/d3-time-format@2.1.0", "", {}, "sha512-/myT3I7EwlukNOX2xVdMzb8FRgNzRMpsZddwst9Ld/VFe6LyJyRp0s32l/V9XoUzk+Gqu56F/oGk6507+8BxrA=="],
|
||||||
|
|
||||||
|
"@types/d3-timer": ["@types/d3-timer@3.0.2", "", {}, "sha512-Ps3T8E8dZDam6fUyNiMkekK3XUsaUEik+idO9/YjPtfj2qruF8tFBXS7XhtE4iIXBLxhmLjP3SXpLhVf21I9Lw=="],
|
||||||
|
|
||||||
|
"@types/d3-transition": ["@types/d3-transition@3.0.9", "", { "dependencies": { "@types/d3-selection": "*" } }, "sha512-uZS5shfxzO3rGlu0cC3bjmMFKsXv+SmZZcgp0KD22ts4uGXp5EVYGzu/0YdwZeKmddhcAccYtREJKkPfXkZuCg=="],
|
||||||
|
|
||||||
|
"@types/d3-zoom": ["@types/d3-zoom@3.0.9", "", { "dependencies": { "@types/d3-interpolate": "*", "@types/d3-selection": "*" } }, "sha512-0sE1406XBYJGiqD3AusTl9ZqC//2mIXix51tbom25gDCA8ri4xnSZg28CaSE8Srl6FClqABUKfsn0qghgdepMA=="],
|
||||||
|
|
||||||
|
"@types/estree": ["@types/estree@1.0.9", "", {}, "sha512-GhdPgy1el4/ImP05X05Uw4cw2/M93BCUmnEvWZNStlCzEKME4Fkk+YpoA5OiHNQmoS7Cafb8Xa3Pya8m1Qrzeg=="],
|
||||||
|
|
||||||
|
"@types/geojson": ["@types/geojson@7946.0.16", "", {}, "sha512-6C8nqWur3j98U6+lXDfTUWIfgvZU+EumvpHKcYjujKH7woYyLj2sUmff0tRhrqM7BohUw7Pz3ZB1jj2gW9Fvmg=="],
|
||||||
|
|
||||||
|
"@types/node": ["@types/node@26.6.6", "", { "dependencies": { "undici-types": "~8.9.0" } }, "sha512-MzQj+8Kx3XI40OmUAE6Qoh58ZMNstNNMwn2nfd3qWsfe7nDNSqJNzes4njhz6AHwrSHOffSLwXU6yb474Q4aog=="],
|
||||||
|
|
||||||
|
"@types/react": ["@types/react@19.3.0", "", { "dependencies": { "csstype": "^3.2.2" } }, "sha512-N0rFCuH9YoxG9/m61l9MfpJKfmLOVU0em7ipIz6TRgSSkvReLB9vL85GB+yr8Bs5leqpvg96JSwF4ZS1s4viQg=="],
|
||||||
|
|
||||||
|
"@types/react-dom": ["@types/react-dom@19.3.0", "", { "peerDependencies": { "@types/react": "^19.3.0" } }, "sha512-ZI7bU42mZXXKHn/qNLEw2IrbiINU7X5+vfgdixBHkCNpYWXjKgfQ/P+uyGb5CjOLB9UcnTeg3rylQtV2hym44Q=="],
|
||||||
|
|
||||||
|
"@types/trusted-types": ["@types/trusted-types@2.0.7", "", {}, "sha512-ScaPdn1dQczgbl0QFTeTOmVHFULt394XJgOQNoyVhZ6r2vLnMLJfBPd53SB52T/3G36VI1/g2MZaX0cwDuXsfw=="],
|
||||||
|
|
||||||
|
"@upsetjs/venn.js": ["@upsetjs/venn.js@2.0.0", "", { "optionalDependencies": { "d3-selection": "^3.0.0", "d3-transition": "^3.0.1" } }, "sha512-WbBhLrooyePuQ1VZxrJjtLvTc4NVfpOyKx0sKqioq9bX1C1m7Jgykkn8gLrtwumBioXIqam8DLxp88Adbue6Hw=="],
|
||||||
|
|
||||||
|
"@visx/axis": ["@visx/axis@4.0.0", "", { "dependencies": { "@visx/group": "4.0.0", "@visx/point": "4.0.0", "@visx/scale": "4.0.0", "@visx/shape": "4.0.0", "@visx/text": "4.0.0", "classnames": "^2.3.1" }, "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react"] }, "sha512-cSPNO9Aic2UX49AmIeJJ9TQrrAkvUHpHOGqimUAXhbg07VI3HoHDKcXZdrjvQz+g0LhubrUkjj8Gwju2WZ3dtg=="],
|
||||||
|
|
||||||
|
"@visx/bounds": ["@visx/bounds@4.0.0", "", { "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "@types/react-dom": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0", "react-dom": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-3wAfN5fg2bxg/5f3MlKWzGDTKU2hdKkxq8bVWXpPZQV0UiVc0myuU1qa34c7tN3hg5SDe6MJi/bae2eTQDgEiQ=="],
|
||||||
|
|
||||||
|
"@visx/curve": ["@visx/curve@4.0.0", "", { "dependencies": { "@visx/vendor": "4.0.0" } }, "sha512-bXrOSd2BzVCxR7kBE7gPTSU4plxzYN75w7erdHYabwn3vzP+xFk1o0gg3NOHEPJzt5tXqf0Ecm5YqHACOnipTA=="],
|
||||||
|
|
||||||
|
"@visx/event": ["@visx/event@4.0.0", "", { "dependencies": { "@visx/point": "4.0.0" }, "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react"] }, "sha512-sOcVVzOUxOefF8mQenRFtutoEO7P9icpTcSJM36Sv13sepQbPBuYLknX7RV+EzqyNLOze5cO5GmLIUNH82FOoA=="],
|
||||||
|
|
||||||
|
"@visx/gradient": ["@visx/gradient@4.0.0", "", { "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react"] }, "sha512-AycKA/9Hhx9BXOdWACqYKGU+Dkq/gWzgaDAK/MkVDjXME+3Sl8oE6mn/ZO54gi6wg9qNHhWLnp8XKPJSp4/pzA=="],
|
||||||
|
|
||||||
|
"@visx/group": ["@visx/group@4.0.0", "", { "dependencies": { "classnames": "^2.3.1" }, "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react"] }, "sha512-HGAq8BCqn5x0t94CJOLJeKtWss9LFpF3HY69HbuO1PlR+B9c4aVT9xbjfudmU8wGQZLT6JNt+PJvxbO2aJ+1aA=="],
|
||||||
|
|
||||||
|
"@visx/point": ["@visx/point@4.0.0", "", {}, "sha512-hwJ9UlIjg3iV4iiJ3RN5SNTXama+zGaNe57sXSrSvPiqhkDXypsYBdDSlAnHmKbMzHP0zFmgB1UJciB/QUyigw=="],
|
||||||
|
|
||||||
|
"@visx/responsive": ["@visx/responsive@4.0.0", "", { "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react"] }, "sha512-MGPK8AeiBIhzz34o9TNJIyUDQIdWEj5mt+U/Je4qVRRXpXSMhor1IE7v71czAS5b90OrFxC9L3w27AV+szG25w=="],
|
||||||
|
|
||||||
|
"@visx/scale": ["@visx/scale@4.0.0", "", { "dependencies": { "@visx/vendor": "4.0.0" } }, "sha512-Q3VaSLKlsrxxSl9CwS2D3Mvz4/4kIp/6NMKRY8Im0Au1hrQh2egU806p0+JwN0ccuGGDe03jyAxX4BSRAH8Plg=="],
|
||||||
|
|
||||||
|
"@visx/shape": ["@visx/shape@4.0.0", "", { "dependencies": { "@visx/curve": "4.0.0", "@visx/group": "4.0.0", "@visx/scale": "4.0.0", "@visx/vendor": "4.0.0", "classnames": "^2.3.1" }, "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react"] }, "sha512-X0FP3OFjQhc5/6Vj2aY7cK2JwKYI0H0hQM7cdNRWy/ZMMlrh5KpEdqx0HVo0KoTeTlkUvO+kydMLnAuuCRFIFw=="],
|
||||||
|
|
||||||
|
"@visx/text": ["@visx/text@4.0.0", "", { "dependencies": { "classnames": "^2.3.1", "reduce-css-calc": "^1.3.0" }, "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react"] }, "sha512-39f2goSaKy5Mqn89lRDGSJ1IMr49wplkbIFHsFI8cPnAPbguiJxYZ+ulizd7Vcsq2z/hytuGv3Lmk165zUiUYQ=="],
|
||||||
|
|
||||||
|
"@visx/tooltip": ["@visx/tooltip@4.0.0", "", { "dependencies": { "@visx/bounds": "4.0.0", "classnames": "^2.3.1", "react-use-measure": "^2.0.4" }, "peerDependencies": { "@types/react": "^18.0.0 || ^19.0.0", "@types/react-dom": "^18.0.0 || ^19.0.0", "react": "^18.0.0 || ^19.0.0", "react-dom": "^18.0.0 || ^19.0.0" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-+6J2h5qPvniT0pQtxQrLYGErPRVHr3pRfcMkNqTxD/HgofDGsL6vEBkjMR535MF1hkWYQ9XzOiWP6ERN4TF+mg=="],
|
||||||
|
|
||||||
|
"@visx/vendor": ["@visx/vendor@4.0.0", "", { "dependencies": { "@types/d3-array": "3.0.3", "@types/d3-color": "3.1.0", "@types/d3-delaunay": "6.0.1", "@types/d3-format": "3.0.1", "@types/d3-geo": "3.1.0", "@types/d3-interpolate": "3.0.1", "@types/d3-path": "3.1.1", "@types/d3-scale": "4.0.2", "@types/d3-shape": "3.1.7", "@types/d3-time": "3.0.0", "@types/d3-time-format": "2.1.0", "d3-array": "3.2.1", "d3-color": "3.1.0", "d3-delaunay": "6.0.2", "d3-format": "3.1.0", "d3-geo": "3.1.0", "d3-interpolate": "3.0.1", "d3-path": "3.1.0", "d3-scale": "4.0.2", "d3-shape": "3.2.0", "d3-time": "3.1.0", "d3-time-format": "4.1.0", "internmap": "2.0.3" } }, "sha512-LoBNzWjTXzBfu095BQxB14IwZQHHOLs8ZMzM6t2FL4ZGORaACgLcmXRRLhFo0VmRR8L7iNTM4HHc1j6yFvzsAA=="],
|
||||||
|
|
||||||
|
"@vitejs/plugin-react": ["@vitejs/plugin-react@4.7.0", "", { "dependencies": { "@babel/core": "^7.28.0", "@babel/plugin-transform-react-jsx-self": "^7.27.1", "@babel/plugin-transform-react-jsx-source": "^7.27.1", "@rolldown/pluginutils": "1.0.0-beta.27", "@types/babel__core": "^7.20.5", "react-refresh": "^0.17.0" }, "peerDependencies": { "vite": "^4.2.0 || ^5.0.0 || ^6.0.0 || ^7.0.0" } }, "sha512-gUu9hwfWvvEDBBmgtAowQCojwZmJ5mcLn3aufeCsitijs3+f2NsrPtlAWIR6OPiqljl96GVCUbLe0HyqIpVaoA=="],
|
||||||
|
|
||||||
|
"@zenuml/core": ["@zenuml/core@3.50.1", "", { "dependencies": { "@floating-ui/react": "^0.27.16", "@headlessui/react": "^2.2.9", "@headlessui/tailwindcss": "^0.2.2", "antlr4": "~4.11.0", "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "color-string": "^2.1.4", "dompurify": "^3.3.1", "highlight.js": "^11.10.0", "html-to-image": "^1.11.13", "jotai": "^2.16.1", "marked": "^4.3.0", "react": "^19.2.3", "react-dom": "^19.2.3", "tailwind-merge": "^3.4.0" }, "optionalDependencies": { "@napi-rs/canvas": "^0.1.97" }, "peerDependencies": { "playwright-core": "1.57.0" }, "optionalPeers": ["playwright-core"], "bin": { "zenuml": "dist/cli/zenuml.mjs" } }, "sha512-Q18BXvIfhRuGw0JfO4e+pltG04Phhv2E7n35EWTNSZKKH/HEkyE4Sh7KERb9dqaOfjOdRdKvLG0YekjK3fcDXw=="],
|
||||||
|
|
||||||
|
"ansi-regex": ["ansi-regex@6.4.0", "", {}, "sha512-KzTVk2tCWAHtYrvvvaP8bJKJq2pVinhLcGEQdtLIYPbmNGNyYe8QwNaTUYQp2J7/vIsUKt5QCqAfUkYyG9DkOw=="],
|
||||||
|
|
||||||
|
"ansi-styles": ["ansi-styles@6.2.3", "", {}, "sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg=="],
|
||||||
|
|
||||||
|
"antlr4": ["antlr4@4.11.0", "", {}, "sha512-GUGlpE2JUjAN+G8G5vY+nOoeyNhHsXoIJwP1XF1oRw89vifA1K46T6SEkwLwr7drihN7I/lf0DIjKc4OZvBX8w=="],
|
||||||
|
|
||||||
|
"aria-hidden": ["aria-hidden@1.2.6", "", { "dependencies": { "tslib": "^2.0.0" } }, "sha512-ik3ZgC9dY/lYVVM++OISsaYDeg1tb0VtP5uL3ouh1koGOaUMDPpbFIei4JkFimWUFPn90sbMNMXQAIVOlnYKJA=="],
|
||||||
|
|
||||||
|
"balanced-match": ["balanced-match@0.4.2", "", {}, "sha512-STw03mQKnGUYtoNjmowo4F2cRmIIxYEGiMsjjwla/u5P1lxadj/05WkNaFjNiKTgJkj8KiXbgAiRTmcQRwQNtg=="],
|
||||||
|
|
||||||
|
"baseline-browser-mapping": ["baseline-browser-mapping@2.11.34", "", { "bin": { "baseline-browser-mapping": "dist/cli.cjs" } }, "sha512-Aqr8mA1kIvyJ3UY5YAY7ib8LSo1DmDMbMnVqGPtsKW1LxaFQFwn9Eb3yvq2fUKJsRvaXjnAV7R5osqETapzNiA=="],
|
||||||
|
|
||||||
|
"browserslist": ["browserslist@4.29.5", "", { "dependencies": { "baseline-browser-mapping": "^2.11.33", "caniuse-lite": "^1.0.30001819", "electron-to-chromium": "^1.5.464", "node-releases": "^2.0.60", "update-browserslist-db": "^1.3.4" }, "bin": { "browserslist": "cli.js" } }, "sha512-khTmKu5NGYTotqcYo8Bew2k4RAE9PuXRSFRXG2lQBrCEQHyeQ/vX6gKMxfokwywBsLiXZMnHsmWMG1pnO8J7uQ=="],
|
||||||
|
|
||||||
|
"bun-types": ["bun-types@1.3.0", "", { "dependencies": { "@types/node": "*" }, "peerDependencies": { "@types/react": "^19" } }, "sha512-u8X0thhx+yJ0KmkxuEo9HAtdfgCBaM/aI9K90VQcQioAmkVp3SG3FkwWGibUFz3WdXAdcsqOcbU40lK7tbHdkQ=="],
|
||||||
|
|
||||||
|
"caniuse-lite": ["caniuse-lite@1.0.30001820", "", {}, "sha512-gfWD6MxqVCqAOwmODfZf7DchWvlrA+SRdNX7ceLfg3xRqe5ssjjpF7EgslC/0tiLiNTajdaNN/q8c/5u/7Gz8w=="],
|
||||||
|
|
||||||
|
"chalk": ["chalk@6.0.1", "", {}, "sha512-/Ce6KNm3vIbWdMlNna6RVIZ/ICQxnJxCicet5LBKK9ZffBkqzDw0xh9EiKSljdRtiIQ1S1z4YgcscUUGzNCWrA=="],
|
||||||
|
|
||||||
|
"chevrotain": ["chevrotain@13.2.0", "", { "dependencies": { "@chevrotain/cst-dts-gen": "13.2.0", "@chevrotain/gast": "13.2.0", "@chevrotain/regexp-to-ast": "13.2.0", "@chevrotain/types": "13.2.0", "@chevrotain/utils": "13.2.0" } }, "sha512-GTouk5YzgBxlTPCaDn5q0q2EJKkrYmnPF+HmF8v0Qo4r3iyPG7HJivkN1wthCXZcm3sIcZFpGTRovLPNdJNRCA=="],
|
||||||
|
|
||||||
|
"chromium-bidi": ["chromium-bidi@157.0.8090-0", "", { "dependencies": { "mitt": "^3.0.1", "zod": "^4.6.5" }, "peerDependencies": { "devtools-protocol": "*" } }, "sha512-KJw7IQgqXwxpJgJlEIPg5mr2ZoqA+jkTRtc5EABI7sUJ3bu3cpI7NuEBoj4Gn1AsF78CaT9So5WQWspK3/wYag=="],
|
||||||
|
|
||||||
|
"class-variance-authority": ["class-variance-authority@0.7.1", "", { "dependencies": { "clsx": "^2.1.1" } }, "sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg=="],
|
||||||
|
|
||||||
|
"classnames": ["classnames@2.5.1", "", {}, "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow=="],
|
||||||
|
|
||||||
|
"cliui": ["cliui@9.0.1", "", { "dependencies": { "string-width": "^7.2.0", "strip-ansi": "^7.1.0", "wrap-ansi": "^9.0.0" } }, "sha512-k7ndgKhwoQveBL+/1tqGJYNz097I7WOvwbmmU2AR5+magtbjPWQTS1C5vzGkBC8Ym8UWRzfKUzUUqFLypY4Q+w=="],
|
||||||
|
|
||||||
|
"clsx": ["clsx@2.1.1", "", {}, "sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA=="],
|
||||||
|
|
||||||
|
"color-name": ["color-name@2.1.1", "", {}, "sha512-p2FdgwVx1a9yWBHP2wI0VgShkDpgN4kZISkxdNipGBJWpa5G6b04OINlVWCyJj0JmfvcPrgqt95E9k8yvaOJFg=="],
|
||||||
|
|
||||||
|
"color-string": ["color-string@2.1.4", "", { "dependencies": { "color-name": "^2.0.0" } }, "sha512-Bb6Cq8oq0IjDOe8wJmi4JeNn763Xs9cfrBcaylK1tPypWzyoy2G3l90v9k64kjphl/ZJjPIShFztenRomi8WTg=="],
|
||||||
|
|
||||||
|
"commander": ["commander@15.0.0", "", {}, "sha512-z67u4ZhzCL/Tydu1lJARtEZYWbWaN7oYLHbsuzocr6y4N6WZAagG3RQ4FW61V1/0+jImpj293XfrcYnd1qxtPg=="],
|
||||||
|
|
||||||
|
"convert-source-map": ["convert-source-map@2.0.0", "", {}, "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg=="],
|
||||||
|
|
||||||
|
"cose-base": ["cose-base@1.0.3", "", { "dependencies": { "layout-base": "^1.0.0" } }, "sha512-s9whTXInMSgAp/NVXVNuVxVKzGH2qck3aQlVHxDCdAEPgtMKwc4Wq6/QKhgdEdgbLSi9rBTAcPoRa6JpiG4ksg=="],
|
||||||
|
|
||||||
|
"csstype": ["csstype@3.2.3", "", {}, "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ=="],
|
||||||
|
|
||||||
|
"cytoscape": ["cytoscape@3.34.4", "", {}, "sha512-msY99tMY8iWTg+sIPGfSqDcPNOt4xcj+v/K/7qUFaCUxxlqnMkUYLBjRUzn9W5CU/R2hrmtJa5+UtovrEM2ctg=="],
|
||||||
|
|
||||||
|
"cytoscape-cose-bilkent": ["cytoscape-cose-bilkent@4.1.0", "", { "dependencies": { "cose-base": "^1.0.0" }, "peerDependencies": { "cytoscape": "^3.2.0" } }, "sha512-wgQlVIUJF13Quxiv5e1gstZ08rnZj2XaLHGoFMYXz7SkNfCDOOteKBE6SYRfA9WxxI/iBc3ajfDoc6hb/MRAHQ=="],
|
||||||
|
|
||||||
|
"cytoscape-fcose": ["cytoscape-fcose@2.2.0", "", { "dependencies": { "cose-base": "^2.2.0" }, "peerDependencies": { "cytoscape": "^3.2.0" } }, "sha512-ki1/VuRIHFCzxWNrsshHYPs6L7TvLu3DL+TyIGEsRcvVERmxokbf5Gdk7mFxZnTdiGtnA4cfSmjZJMviqSuZrQ=="],
|
||||||
|
|
||||||
|
"d3": ["d3@7.9.0", "", { "dependencies": { "d3-array": "3", "d3-axis": "3", "d3-brush": "3", "d3-chord": "3", "d3-color": "3", "d3-contour": "4", "d3-delaunay": "6", "d3-dispatch": "3", "d3-drag": "3", "d3-dsv": "3", "d3-ease": "3", "d3-fetch": "3", "d3-force": "3", "d3-format": "3", "d3-geo": "3", "d3-hierarchy": "3", "d3-interpolate": "3", "d3-path": "3", "d3-polygon": "3", "d3-quadtree": "3", "d3-random": "3", "d3-scale": "4", "d3-scale-chromatic": "3", "d3-selection": "3", "d3-shape": "3", "d3-time": "3", "d3-time-format": "4", "d3-timer": "3", "d3-transition": "3", "d3-zoom": "3" } }, "sha512-e1U46jVP+w7Iut8Jt8ri1YsPOvFpg46k+K8TpCb0P+zjCkjkPnV7WzfDJzMHy1LnA+wj5pLT1wjO901gLXeEhA=="],
|
||||||
|
|
||||||
|
"d3-array": ["d3-array@3.2.1", "", { "dependencies": { "internmap": "1 - 2" } }, "sha512-gUY/qeHq/yNqqoCKNq4vtpFLdoCdvyNpWoC/KNjhGbhDuQpAM9sIQQKkXSNpXa9h5KySs/gzm7R88WkUutgwWQ=="],
|
||||||
|
|
||||||
|
"d3-axis": ["d3-axis@3.0.0", "", {}, "sha512-IH5tgjV4jE/GhHkRV0HiVYPDtvfjHQlQfJHs0usq7M30XcSBvOotpmH1IgkcXsO/5gEQZD43B//fc7SRT5S+xw=="],
|
||||||
|
|
||||||
|
"d3-brush": ["d3-brush@3.0.0", "", { "dependencies": { "d3-dispatch": "1 - 3", "d3-drag": "2 - 3", "d3-interpolate": "1 - 3", "d3-selection": "3", "d3-transition": "3" } }, "sha512-ALnjWlVYkXsVIGlOsuWH1+3udkYFI48Ljihfnh8FZPF2QS9o+PzGLBslO0PjzVoHLZ2KCVgAM8NVkXPJB2aNnQ=="],
|
||||||
|
|
||||||
|
"d3-chord": ["d3-chord@3.0.1", "", { "dependencies": { "d3-path": "1 - 3" } }, "sha512-VE5S6TNa+j8msksl7HwjxMHDM2yNK3XCkusIlpX5kwauBfXuyLAtNg9jCp/iHH61tgI4sb6R/EIMWCqEIdjT/g=="],
|
||||||
|
|
||||||
|
"d3-color": ["d3-color@3.1.0", "", {}, "sha512-zg/chbXyeBtMQ1LbD/WSoW2DpC3I0mpmPdW+ynRTj/x2DAWYrIY7qeZIHidozwV24m4iavr15lNwIwLxRmOxhA=="],
|
||||||
|
|
||||||
|
"d3-contour": ["d3-contour@4.0.2", "", { "dependencies": { "d3-array": "^3.2.0" } }, "sha512-4EzFTRIikzs47RGmdxbeUvLWtGedDUNkTcmzoeyg4sP/dvCexO47AaQL7VKy/gul85TOxw+IBgA8US2xwbToNA=="],
|
||||||
|
|
||||||
|
"d3-delaunay": ["d3-delaunay@6.0.2", "", { "dependencies": { "delaunator": "5" } }, "sha512-IMLNldruDQScrcfT+MWnazhHbDJhcRJyOEBAJfwQnHle1RPh6WDuLvxNArUju2VSMSUuKlY5BGHRJ2cYyoFLQQ=="],
|
||||||
|
|
||||||
|
"d3-dispatch": ["d3-dispatch@3.0.1", "", {}, "sha512-rzUyPU/S7rwUflMyLc1ETDeBj0NRuHKKAcvukozwhshr6g6c5d8zh4c2gQjY2bZ0dXeGLWc1PF174P2tVvKhfg=="],
|
||||||
|
|
||||||
|
"d3-drag": ["d3-drag@3.0.0", "", { "dependencies": { "d3-dispatch": "1 - 3", "d3-selection": "3" } }, "sha512-pWbUJLdETVA8lQNJecMxoXfH6x+mO2UQo8rSmZ+QqxcbyA3hfeprFgIT//HW2nlHChWeIIMwS2Fq+gEARkhTkg=="],
|
||||||
|
|
||||||
|
"d3-dsv": ["d3-dsv@3.0.1", "", { "dependencies": { "commander": "7", "iconv-lite": "0.6", "rw": "1" }, "bin": { "csv2json": "bin/dsv2json.js", "csv2tsv": "bin/dsv2dsv.js", "dsv2dsv": "bin/dsv2dsv.js", "dsv2json": "bin/dsv2json.js", "json2csv": "bin/json2dsv.js", "json2dsv": "bin/json2dsv.js", "json2tsv": "bin/json2dsv.js", "tsv2csv": "bin/dsv2dsv.js", "tsv2json": "bin/dsv2json.js" } }, "sha512-UG6OvdI5afDIFP9w4G0mNq50dSOsXHJaRE8arAS5o9ApWnIElp8GZw1Dun8vP8OyHOZ/QJUKUJwxiiCCnUwm+Q=="],
|
||||||
|
|
||||||
|
"d3-ease": ["d3-ease@3.0.1", "", {}, "sha512-wR/XK3D3XcLIZwpbvQwQ5fK+8Ykds1ip7A2Txe0yxncXSdq1L9skcG7blcedkOX+ZcgxGAmLX1FrRGbADwzi0w=="],
|
||||||
|
|
||||||
|
"d3-fetch": ["d3-fetch@3.0.1", "", { "dependencies": { "d3-dsv": "1 - 3" } }, "sha512-kpkQIM20n3oLVBKGg6oHrUchHM3xODkTzjMoj7aWQFq5QEM+R6E4WkzT5+tojDY7yjez8KgCBRoj4aEr99Fdqw=="],
|
||||||
|
|
||||||
|
"d3-force": ["d3-force@3.0.0", "", { "dependencies": { "d3-dispatch": "1 - 3", "d3-quadtree": "1 - 3", "d3-timer": "1 - 3" } }, "sha512-zxV/SsA+U4yte8051P4ECydjD/S+qeYtnaIyAs9tgHCqfguma/aAQDjo85A9Z6EKhBirHRJHXIgJUlffT4wdLg=="],
|
||||||
|
|
||||||
|
"d3-format": ["d3-format@3.1.0", "", {}, "sha512-YyUI6AEuY/Wpt8KWLgZHsIU86atmikuoOmCfommt0LYHiQSPjvX2AcFc38PX0CBpr2RCyZhjex+NS/LPOv6YqA=="],
|
||||||
|
|
||||||
|
"d3-geo": ["d3-geo@3.1.0", "", { "dependencies": { "d3-array": "2.5.0 - 3" } }, "sha512-JEo5HxXDdDYXCaWdwLRt79y7giK8SbhZJbFWXqbRTolCHFI5jRqteLzCsq51NKbUoX0PjBVSohxrx+NoOUujYA=="],
|
||||||
|
|
||||||
|
"d3-hierarchy": ["d3-hierarchy@3.1.2", "", {}, "sha512-FX/9frcub54beBdugHjDCdikxThEqjnR93Qt7PvQTOHxyiNCAlvMrHhclk3cD5VeAaq9fxmfRp+CnWw9rEMBuA=="],
|
||||||
|
|
||||||
|
"d3-interpolate": ["d3-interpolate@3.0.1", "", { "dependencies": { "d3-color": "1 - 3" } }, "sha512-3bYs1rOD33uo8aqJfKP3JWPAibgw8Zm2+L9vBKEHJ2Rg+viTR7o5Mmv5mZcieN+FRYaAOWX5SJATX6k1PWz72g=="],
|
||||||
|
|
||||||
|
"d3-path": ["d3-path@3.1.0", "", {}, "sha512-p3KP5HCf/bvjBSSKuXid6Zqijx7wIfNW+J/maPs+iwR35at5JCbLUT0LzF1cnjbCHWhqzQTIN2Jpe8pRebIEFQ=="],
|
||||||
|
|
||||||
|
"d3-polygon": ["d3-polygon@3.0.1", "", {}, "sha512-3vbA7vXYwfe1SYhED++fPUQlWSYTTGmFmQiany/gdbiWgU/iEyQzyymwL9SkJjFFuCS4902BSzewVGsHHmHtXg=="],
|
||||||
|
|
||||||
|
"d3-quadtree": ["d3-quadtree@3.0.1", "", {}, "sha512-04xDrxQTDTCFwP5H6hRhsRcb9xxv2RzkcsygFzmkSIOJy3PeRJP7sNk3VRIbKXcog561P9oU0/rVH6vDROAgUw=="],
|
||||||
|
|
||||||
|
"d3-random": ["d3-random@3.0.1", "", {}, "sha512-FXMe9GfxTxqd5D6jFsQ+DJ8BJS4E/fT5mqqdjovykEB2oFbTMDVdg1MGFxfQW+FBOGoB++k8swBrgwSHT1cUXQ=="],
|
||||||
|
|
||||||
|
"d3-sankey": ["d3-sankey@0.12.3", "", { "dependencies": { "d3-array": "1 - 2", "d3-shape": "^1.2.0" } }, "sha512-nQhsBRmM19Ax5xEIPLMY9ZmJ/cDvd1BG3UVvt5h3WRxKg5zGRbvnteTyWAbzeSvlh3tW7ZEmq4VwR5mB3tutmQ=="],
|
||||||
|
|
||||||
|
"d3-scale": ["d3-scale@4.0.2", "", { "dependencies": { "d3-array": "2.10.0 - 3", "d3-format": "1 - 3", "d3-interpolate": "1.2.0 - 3", "d3-time": "2.1.1 - 3", "d3-time-format": "2 - 4" } }, "sha512-GZW464g1SH7ag3Y7hXjf8RoUuAFIqklOAq3MRl4OaWabTFJY9PN/E1YklhXLh+OQ3fM9yS2nOkCoS+WLZ6kvxQ=="],
|
||||||
|
|
||||||
|
"d3-scale-chromatic": ["d3-scale-chromatic@3.1.0", "", { "dependencies": { "d3-color": "1 - 3", "d3-interpolate": "1 - 3" } }, "sha512-A3s5PWiZ9YCXFye1o246KoscMWqf8BsD9eRiJ3He7C9OBaxKhAd5TFCdEx/7VbKtxxTsu//1mMJFrEt572cEyQ=="],
|
||||||
|
|
||||||
|
"d3-selection": ["d3-selection@3.0.0", "", {}, "sha512-fmTRWbNMmsmWq6xJV8D19U/gw/bwrHfNXxrIN+HfZgnzqTHp9jOmKMhsTUjXOJnZOdZY9Q28y4yebKzqDKlxlQ=="],
|
||||||
|
|
||||||
|
"d3-shape": ["d3-shape@3.2.0", "", { "dependencies": { "d3-path": "^3.1.0" } }, "sha512-SaLBuwGm3MOViRq2ABk3eLoxwZELpH6zhl3FbAoJ7Vm1gofKx6El1Ib5z23NUEhF9AsGl7y+dzLe5Cw2AArGTA=="],
|
||||||
|
|
||||||
|
"d3-time": ["d3-time@3.1.0", "", { "dependencies": { "d3-array": "2 - 3" } }, "sha512-VqKjzBLejbSMT4IgbmVgDjpkYrNWUYJnbCGo874u7MMKIWsILRX+OpX/gTk8MqjpT1A/c6HY2dCA77ZN0lkQ2Q=="],
|
||||||
|
|
||||||
|
"d3-time-format": ["d3-time-format@4.1.0", "", { "dependencies": { "d3-time": "1 - 3" } }, "sha512-dJxPBlzC7NugB2PDLwo9Q8JiTR3M3e4/XANkreKSUxF8vvXKqm1Yfq4Q5dl8budlunRVlUUaDUgFt7eA8D6NLg=="],
|
||||||
|
|
||||||
|
"d3-timer": ["d3-timer@3.0.1", "", {}, "sha512-ndfJ/JxxMd3nw31uyKoY2naivF+r29V+Lc0svZxe1JvvIRmi8hUsrMvdOwgS1o6uBHmiz91geQ0ylPP0aj1VUA=="],
|
||||||
|
|
||||||
|
"d3-transition": ["d3-transition@3.0.1", "", { "dependencies": { "d3-color": "1 - 3", "d3-dispatch": "1 - 3", "d3-ease": "1 - 3", "d3-interpolate": "1 - 3", "d3-timer": "1 - 3" }, "peerDependencies": { "d3-selection": "2 - 3" } }, "sha512-ApKvfjsSR6tg06xrL434C0WydLr7JewBB3V+/39RMHsaXTOG0zmt/OAXeng5M5LBm0ojmxJrpomQVZ1aPvBL4w=="],
|
||||||
|
|
||||||
|
"d3-zoom": ["d3-zoom@3.0.0", "", { "dependencies": { "d3-dispatch": "1 - 3", "d3-drag": "2 - 3", "d3-interpolate": "1 - 3", "d3-selection": "2 - 3", "d3-transition": "2 - 3" } }, "sha512-b8AmV3kfQaqWAuacbPuNbL6vahnOJflOhexLzMMNLga62+/nh0JzvJ0aO/5a5MVgUFGS7Hu1P9P03o3fJkDCyw=="],
|
||||||
|
|
||||||
|
"dagre-d3-es": ["dagre-d3-es@7.0.14", "", { "dependencies": { "d3": "^7.9.0", "lodash-es": "^4.17.21" } }, "sha512-P4rFMVq9ESWqmOgK+dlXvOtLwYg0i7u0HBGJER0LZDJT2VHIPAMZ/riPxqJceWMStH5+E61QxFra9kIS3AqdMg=="],
|
||||||
|
|
||||||
|
"dayjs": ["dayjs@1.11.23", "", {}, "sha512-QDTCU0M0MxR3hQfnlDJfwekQiaanm1ubOD231u73WBckQ/fsamwRLiE2GBz6D3a/xF1NgfiDLJjXBa1hYOYTtQ=="],
|
||||||
|
|
||||||
|
"debug": ["debug@4.4.3", "", { "dependencies": { "ms": "^2.1.3" }, "peerDependencies": { "supports-color": "*" }, "optionalPeers": ["supports-color"] }, "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA=="],
|
||||||
|
|
||||||
|
"delaunator": ["delaunator@5.1.0", "", { "dependencies": { "robust-predicates": "^3.0.2" } }, "sha512-AGrQ4QSgssa1NGmWmLPqN5NY2KajF5MqxetNEO+o0n3ZwZZeTmt7bBnvzHWrmkZFxGgr4HdyFgelzgi06otLuQ=="],
|
||||||
|
|
||||||
|
"devtools-protocol": ["devtools-protocol@0.0.1704951", "", {}, "sha512-GQhQOs9u/Mvm1zMtJIH872JS4AskuZdUSsPNPk4ChahtWAUqgz6atEtIsMt+nO7MqF1Ic4HxII/k8Cu36JivNg=="],
|
||||||
|
|
||||||
|
"dompurify": ["dompurify@3.4.17", "", { "optionalDependencies": { "@types/trusted-types": "^2.0.7" } }, "sha512-B/pSlYVHQ58kqISD/yDjuJ1yfzI34m1gF4lAod2bwSRhiN4K5Cl3H8Af7hqB2PmTL911tdEudnnXn5FnhRoz0w=="],
|
||||||
|
|
||||||
|
"electron-to-chromium": ["electron-to-chromium@1.5.467", "", {}, "sha512-Nw9X371rtZmYcBSnEijnCDONILjs93biCZO34juC7MBOmK8E+GFnyD4T/WvyrlJkppul7oxg6TwvtKst9SODTw=="],
|
||||||
|
|
||||||
|
"elkjs": ["elkjs@0.9.3", "", {}, "sha512-f/ZeWvW/BCXbhGEf1Ujp29EASo/lk1FDnETgNKwJrsVvGZhUWCZyg3xLJjAsxfOmt8KjswHmI5EwCQcPMpOYhQ=="],
|
||||||
|
|
||||||
|
"emoji-regex": ["emoji-regex@10.6.0", "", {}, "sha512-toUI84YS5YmxW219erniWD0CIVOo46xGKColeNQRgOzDorgBi1v4D71/OFzgD9GO2UGKIv1C3Sp8DAn0+j5w7A=="],
|
||||||
|
|
||||||
|
"es-toolkit": ["es-toolkit@1.53.0", "", {}, "sha512-3+AYXp9fmJ/UhHBMYj2/U+RaUouMD90SzoItyDOB2Za7W6dB7fQApFGnZPl2MF6K8/Tv1koh1JyirSx/kju6Pw=="],
|
||||||
|
|
||||||
|
"esbuild": ["esbuild@0.25.12", "", { "optionalDependencies": { "@esbuild/aix-ppc64": "0.25.12", "@esbuild/android-arm": "0.25.12", "@esbuild/android-arm64": "0.25.12", "@esbuild/android-x64": "0.25.12", "@esbuild/darwin-arm64": "0.25.12", "@esbuild/darwin-x64": "0.25.12", "@esbuild/freebsd-arm64": "0.25.12", "@esbuild/freebsd-x64": "0.25.12", "@esbuild/linux-arm": "0.25.12", "@esbuild/linux-arm64": "0.25.12", "@esbuild/linux-ia32": "0.25.12", "@esbuild/linux-loong64": "0.25.12", "@esbuild/linux-mips64el": "0.25.12", "@esbuild/linux-ppc64": "0.25.12", "@esbuild/linux-riscv64": "0.25.12", "@esbuild/linux-s390x": "0.25.12", "@esbuild/linux-x64": "0.25.12", "@esbuild/netbsd-arm64": "0.25.12", "@esbuild/netbsd-x64": "0.25.12", "@esbuild/openbsd-arm64": "0.25.12", "@esbuild/openbsd-x64": "0.25.12", "@esbuild/openharmony-arm64": "0.25.12", "@esbuild/sunos-x64": "0.25.12", "@esbuild/win32-arm64": "0.25.12", "@esbuild/win32-ia32": "0.25.12", "@esbuild/win32-x64": "0.25.12" }, "bin": { "esbuild": "bin/esbuild" } }, "sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg=="],
|
||||||
|
|
||||||
|
"escalade": ["escalade@3.2.0", "", {}, "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA=="],
|
||||||
|
|
||||||
|
"fdir": ["fdir@6.5.0", "", { "peerDependencies": { "picomatch": "^3 || ^4" }, "optionalPeers": ["picomatch"] }, "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg=="],
|
||||||
|
|
||||||
|
"fsevents": ["fsevents@2.3.2", "", { "os": "darwin" }, "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA=="],
|
||||||
|
|
||||||
|
"gensync": ["gensync@1.0.0-beta.2", "", {}, "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg=="],
|
||||||
|
|
||||||
|
"get-caller-file": ["get-caller-file@2.0.5", "", {}, "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg=="],
|
||||||
|
|
||||||
|
"get-east-asian-width": ["get-east-asian-width@1.7.0", "", {}, "sha512-XjH1AECxf0giL2V1aU8vKyRR2ppRUb5c0EvT7zuJTokQ74bNo52zOtghqdWIqrhUD79fo3x0WfKZdOqxF6LG1Q=="],
|
||||||
|
|
||||||
|
"hachure-fill": ["hachure-fill@0.5.2", "", {}, "sha512-3GKBOn+m2LX9iq+JC1064cSFprJY4jL1jCXTcpnfER5HYE2l/4EfWSGzkPa/ZDBmYI0ZOEj5VHV/eKnPGkHuOg=="],
|
||||||
|
|
||||||
|
"highlight.js": ["highlight.js@11.12.0", "", {}, "sha512-nbfWpyRMcMrPMmDwJB+dhX/eiaPKtc2RB+0QZskqJ3WjRA/FDS0e9hZrx8EC/lbEv8gXy98FcDbNa/dspAaJMg=="],
|
||||||
|
|
||||||
|
"html-to-image": ["html-to-image@1.11.13", "", {}, "sha512-cuOPoI7WApyhBElTTb9oqsawRvZ0rHhaHwghRLlTuffoD1B2aDemlCruLeZrUIIdvG7gs9xeELEPm6PhuASqrg=="],
|
||||||
|
|
||||||
|
"iconv-lite": ["iconv-lite@0.6.3", "", { "dependencies": { "safer-buffer": ">= 2.1.2 < 3.0.0" } }, "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw=="],
|
||||||
|
|
||||||
|
"import-meta-resolve": ["import-meta-resolve@4.2.0", "", {}, "sha512-Iqv2fzaTQN28s/FwZAoFq0ZSs/7hMAHJVX+w8PZl3cY19Pxk6jFFalxQoIfW2826i/fDLXv8IiEZRIT0lDuWcg=="],
|
||||||
|
|
||||||
|
"internmap": ["internmap@2.0.3", "", {}, "sha512-5Hh7Y1wQbvY5ooGgPbDaL5iYLAPzMTUrjMulskHLH6wnv/A+1q5rgEaiuqEjB+oxGXIVZs1FF+R/KPN3ZSQYYg=="],
|
||||||
|
|
||||||
|
"jotai": ["jotai@2.20.3", "", { "peerDependencies": { "@babel/core": ">=7.0.0", "@babel/template": ">=7.0.0", "@types/react": ">=17.0.0", "react": ">=17.0.0" }, "optionalPeers": ["@babel/core", "@babel/template", "@types/react", "react"] }, "sha512-N8L9FUbeGDP+0qNJw1FebOxt+5hk+jTOwUA2LlRE4C081jUcY6F1T/FSETp4DT2/INMtiSRZyNm2D+yZdzrSgA=="],
|
||||||
|
|
||||||
|
"js-tokens": ["js-tokens@4.0.0", "", {}, "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ=="],
|
||||||
|
|
||||||
|
"jsesc": ["jsesc@3.1.0", "", { "bin": { "jsesc": "bin/jsesc" } }, "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA=="],
|
||||||
|
|
||||||
|
"json5": ["json5@2.2.3", "", { "bin": { "json5": "lib/cli.js" } }, "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg=="],
|
||||||
|
|
||||||
|
"katex": ["katex@0.16.47", "", { "dependencies": { "commander": "^8.3.0" }, "bin": { "katex": "cli.js" } }, "sha512-Eeo8Ys1doU1z+x8AZsPpQu+p/QcZBI5PeOo7QGQdy2x2m0MU/hYagBbGOmXwr5KVbEfVuWv9LpnQWeehogurjg=="],
|
||||||
|
|
||||||
|
"khroma": ["khroma@2.1.0", "", {}, "sha512-Ls993zuzfayK269Svk9hzpeGUKob/sIgZzyHYdjQoAdQetRKpOLj+k/QQQ/6Qi0Yz65mlROrfd+Ev+1+7dz9Kw=="],
|
||||||
|
|
||||||
|
"layout-base": ["layout-base@1.0.2", "", {}, "sha512-8h2oVEZNktL4BH2JCOI90iD1yXwL6iNW7KcCKT2QZgQJR2vbqDsldCTPRU9NifTCqHZci57XvQQ15YTu+sTYPg=="],
|
||||||
|
|
||||||
|
"lilconfig": ["lilconfig@3.1.4", "", {}, "sha512-zJZyBmQhArDRefuWTypZxwDpFDIYmrj8ypSBvwGD5P13Y95s6DjzKgu4DVdGbeQa5PDEsAOCAPNk4X+QOR006w=="],
|
||||||
|
|
||||||
|
"lodash-es": ["lodash-es@4.18.1", "", {}, "sha512-J8xewKD/Gk22OZbhpOVSwcs60zhd95ESDwezOFuA3/099925PdHJ7OFHNTGtajL3AlZkykD32HykiMo+BIBI8A=="],
|
||||||
|
|
||||||
|
"lru-cache": ["lru-cache@5.1.1", "", { "dependencies": { "yallist": "^3.0.2" } }, "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w=="],
|
||||||
|
|
||||||
|
"marked": ["marked@16.4.2", "", { "bin": { "marked": "bin/marked.js" } }, "sha512-TI3V8YYWvkVf3KJe1dRkpnjs68JUPyEa5vjKrp1XEEJUAOaQc+Qj+L1qWbPd0SJuAdQkFU0h73sXXqwDYxsiDA=="],
|
||||||
|
|
||||||
|
"math-expression-evaluator": ["math-expression-evaluator@1.4.0", "", {}, "sha512-4vRUvPyxdO8cWULGTh9dZWL2tZK6LDBvj+OGHBER7poH9Qdt7kXEoj20wiz4lQUbUXQZFjPbe5mVDo9nutizCw=="],
|
||||||
|
|
||||||
|
"mermaid": ["mermaid@12.2.0", "", { "dependencies": { "@braintree/sanitize-url": "^7.1.2", "@iconify/utils": "^3.0.2", "@mermaid-js/parser": "^2.0.1", "@types/d3": "^7.4.3", "@upsetjs/venn.js": "^2.0.0", "chevrotain": "~13.2.0", "cytoscape": "^3.34.0", "cytoscape-cose-bilkent": "^4.1.0", "cytoscape-fcose": "^2.2.0", "d3": "^7.9.0", "d3-sankey": "^0.12.3", "dagre-d3-es": "7.0.14", "dayjs": "^1.11.21", "dompurify": "^3.4.12", "elkjs": "^0.9.3", "es-toolkit": "^1.45.1", "katex": "^0.18.0", "khroma": "^2.1.0", "marked": "^16.3.0", "roughjs": "^4.6.6", "stylis": "^4.3.6", "ts-dedent": "^2.2.0", "uuid": "^11.1.0 || ^12 || ^13 || ^14.0.0" } }, "sha512-w7nr/SFrLO7BaVTs3dQTvYSV6nYSBj0Yy9DjBhsIJtAcHqRzXSq4Pg32ujHZ/AdWsAMNEvvhbm5dt9E2tOiHzw=="],
|
||||||
|
|
||||||
|
"mitt": ["mitt@3.0.1", "", {}, "sha512-vKivATfr97l2/QBCYAkXYDbrIWPM2IIKEl7YPhjCvKlG3kE2gm+uBo6nEXK3M5/Ffh/FLpKExzOQ3JJoJGFKBw=="],
|
||||||
|
|
||||||
|
"modern-tar": ["modern-tar@0.8.6", "", {}, "sha512-LYSks0tNVqbtez/9OB0YFP6qLRSqkdAxJWOQpVaR67lNTbj2zNLyYpowkRMia5lXLCZKzxwoxkxH2MbbBR2aEg=="],
|
||||||
|
|
||||||
|
"ms": ["ms@2.1.3", "", {}, "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA=="],
|
||||||
|
|
||||||
|
"nanoid": ["nanoid@3.3.20", "", { "bin": { "nanoid": "bin/nanoid.cjs" } }, "sha512-uKdg2G3GNCKQn9byYOpxbGqrT2fGO5KRt5J/8b3pok8rT6qxGWF6hxMyJiEYtAf+FVyYuD9hRaDqX5uPFYJ4ZQ=="],
|
||||||
|
|
||||||
|
"node-releases": ["node-releases@2.0.60", "", {}, "sha512-OmO8+GM1JUZqXET720VrJCwkjUCXmCMQm0Z3UDDRbfNLHS4NEAvY60j5jiFv0tkKw2PNNlqOLhahVmwJIOLDIQ=="],
|
||||||
|
|
||||||
|
"p-limit": ["p-limit@7.3.3", "", { "dependencies": { "yocto-queue": "^1.2.1" } }, "sha512-SKgVvDU5TNIxQ4r30U75BNLC6a+6GOEjngrk/ysM5+Zu3oJuk1SC5ApzIzY/7PjCEjoVPMWJ0zho/4QUiEB7TQ=="],
|
||||||
|
|
||||||
|
"package-manager-detector": ["package-manager-detector@1.9.0", "", {}, "sha512-zAMfbta9nPA8AKkA4WdmNAT8R8s6Dk0/xwPsqNnRidMFcLo1YkLuPDTgs2f64XdzS8vbLNnoJ+uUIkgbz7oRHA=="],
|
||||||
|
|
||||||
|
"path-data-parser": ["path-data-parser@0.1.0", "", {}, "sha512-NOnmBpt5Y2RWbuv0LMzsayp3lVylAHLPUTut412ZA3l+C4uw4ZVkQbjShYCQ8TCpUMdPapr4YjUqLYD6v68j+w=="],
|
||||||
|
|
||||||
|
"picocolors": ["picocolors@1.1.1", "", {}, "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA=="],
|
||||||
|
|
||||||
|
"picomatch": ["picomatch@4.0.7", "", {}, "sha512-qcJu88Q2IWqJsDD529JKMdwGm/dvInW4HvQnRwiH9JtihJvzGOscDtHE3x1pBKeUOTysQ8kVmLnJ2kJu7yhcGA=="],
|
||||||
|
|
||||||
|
"playwright": ["playwright@1.55.0", "", { "dependencies": { "playwright-core": "1.55.0" }, "optionalDependencies": { "fsevents": "2.3.2" }, "bin": { "playwright": "cli.js" } }, "sha512-sdCWStblvV1YU909Xqx0DhOjPZE4/5lJsIS84IfN9dAZfcl/CIZ5O8l3o0j7hPMjDvqoTF8ZUcc+i/GL5erstA=="],
|
||||||
|
|
||||||
|
"playwright-core": ["playwright-core@1.55.0", "", { "bin": { "playwright-core": "cli.js" } }, "sha512-GvZs4vU3U5ro2nZpeiwyb0zuFaqb9sUiAJuyrWpcGouD8y9/HLgGbNRjIph7zU9D3hnPaisMl9zG9CgFi/biIg=="],
|
||||||
|
|
||||||
|
"points-on-curve": ["points-on-curve@0.2.0", "", {}, "sha512-0mYKnYYe9ZcqMCWhUjItv/oHjvgEsfKvnUTg8sAtnHr3GVy7rGkXCb6d5cSyqrWqL4k81b9CPg3urd+T7aop3A=="],
|
||||||
|
|
||||||
|
"points-on-path": ["points-on-path@0.2.1", "", { "dependencies": { "path-data-parser": "0.1.0", "points-on-curve": "0.2.0" } }, "sha512-25ClnWWuw7JbWZcgqY/gJ4FQWadKxGWk+3kR/7kD0tCaDtPPMj7oHu2ToLaVhfpnHrZzYby2w6tUA0eOIuUg8g=="],
|
||||||
|
|
||||||
|
"postcss": ["postcss@8.5.32", "", { "dependencies": { "nanoid": "^3.3.20", "picocolors": "^1.1.1", "source-map-js": "^1.2.2" } }, "sha512-LJlKCCAUFKOuZxipUdYw1NzIITEsPcgyOG9LkvRJvuKj/bRzbuRY0ARXvL0pWGpsZvn8jku+LMep2eU0seHp8g=="],
|
||||||
|
|
||||||
|
"puppeteer": ["puppeteer@25.16.0", "", { "dependencies": { "@puppeteer/browsers": "3.2.6", "chromium-bidi": "157.0.8090-0", "devtools-protocol": "0.0.1704951", "lilconfig": "^3.1.3", "puppeteer-core": "25.16.0", "typed-query-selector": "^2.12.3" }, "bin": { "puppeteer": "lib/puppeteer/node/cli.js" } }, "sha512-LOr3reYnxAYYfQkpopz1fQnL0LdvqhpR5U2Fu+QnwzTX2gpVTHsn91UETo5NNC1md2/oC54Zu1ChBXgZDNSP1A=="],
|
||||||
|
|
||||||
|
"puppeteer-core": ["puppeteer-core@25.16.0", "", { "dependencies": { "@puppeteer/browsers": "3.2.6", "chromium-bidi": "157.0.8090-0", "devtools-protocol": "0.0.1704951", "typed-query-selector": "^2.12.3", "webdriver-bidi-protocol": "1.0.1", "ws": "^8.22.0" } }, "sha512-VA5Pf54N8shfopNkZZXCdiiwfnnY8ZJYAMqFQRhlH5mGUhfwf53Ar770GPtdpTDLUqvQeYpIBtC9/G2Jij2IJw=="],
|
||||||
|
|
||||||
|
"react": ["react@19.3.1", "", {}, "sha512-QNhWdt7nrgVWWQG58QuGsAR3jv3Hbe4mb4vz7w2csnHavciZJgda1CPNaldF6eVxv90ud3jUXpKlHL69gO38yw=="],
|
||||||
|
|
||||||
|
"react-aria": ["react-aria@3.53.1", "", { "dependencies": { "@internationalized/date": "^3.12.4", "@internationalized/number": "^3.6.9", "@internationalized/string": "^3.2.10", "@react-types/shared": "^3.37.0", "@swc/helpers": "^0.5.0", "aria-hidden": "^1.2.3", "clsx": "^2.0.0", "react-stately": "3.51.0", "use-sync-external-store": "^1.6.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1", "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-dikisyOjJd3D2fFrIDWmVWzqiLz5B86GzZv1zxs7xI4dVc0JIz/1Wa52I20gYvVL2WXeFXlygYsle/QcOMhtcg=="],
|
||||||
|
|
||||||
|
"react-dom": ["react-dom@19.3.1", "", { "dependencies": { "scheduler": "^0.28.0" }, "peerDependencies": { "react": "^19.3.1" } }, "sha512-Y0bARz53lhEC1NMCASs0/j+faB/zqt3R8hpvg1e8+61ZVJ4UL0UdC4cBbXfZMcIuhrfgeILTLe+ZeBCavQPtKQ=="],
|
||||||
|
|
||||||
|
"react-refresh": ["react-refresh@0.17.0", "", {}, "sha512-z6F7K9bV85EfseRCp2bzrpyQ0Gkw1uLoCel9XBVWPg/TjRj94SkJzUTGfOa4bs7iJvBWtQG0Wq7wnI0syw3EBQ=="],
|
||||||
|
|
||||||
|
"react-stately": ["react-stately@3.51.0", "", { "dependencies": { "@internationalized/date": "^3.12.4", "@internationalized/number": "^3.6.9", "@internationalized/string": "^3.2.10", "@react-types/shared": "^3.37.0", "@swc/helpers": "^0.5.0", "use-sync-external-store": "^1.6.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1" } }, "sha512-YJcmkAXu2XOQP97hO/qz/cC3qv9kni3oVhwBlxWr358BHePJUpY15XwL3YSRMKxYt4EkslPqAz11JRirMfANGw=="],
|
||||||
|
|
||||||
|
"react-use-measure": ["react-use-measure@2.1.7", "", { "peerDependencies": { "react": ">=16.13", "react-dom": ">=16.13" }, "optionalPeers": ["react-dom"] }, "sha512-KrvcAo13I/60HpwGO5jpW7E9DfusKyLPLvuHlUyP5zqnmAPhNc6qTRjUQrdTADl0lpPpDVU2/Gg51UlOGHXbdg=="],
|
||||||
|
|
||||||
|
"reduce-css-calc": ["reduce-css-calc@1.3.0", "", { "dependencies": { "balanced-match": "^0.4.2", "math-expression-evaluator": "^1.2.14", "reduce-function-call": "^1.0.1" } }, "sha512-0dVfwYVOlf/LBA2ec4OwQ6p3X9mYxn/wOl2xTcLwjnPYrkgEfPx3VI4eGCH3rQLlPISG5v9I9bkZosKsNRTRKA=="],
|
||||||
|
|
||||||
|
"reduce-function-call": ["reduce-function-call@1.0.3", "", { "dependencies": { "balanced-match": "^1.0.0" } }, "sha512-Hl/tuV2VDgWgCSEeWMLwxLZqX7OK59eU1guxXsRKTAyeYimivsKdtcV4fu3r710tpG5GmDKDhQ0HSZLExnNmyQ=="],
|
||||||
|
|
||||||
|
"robust-predicates": ["robust-predicates@3.0.3", "", {}, "sha512-NS3levdsRIUOmiJ8FZWCP7LG3QpJyrs/TE0Zpf1yvZu8cAJJ6QMW92H1c7kWpdIHo8RvmLxN/o2JXTKHp74lUA=="],
|
||||||
|
|
||||||
|
"rollup": ["rollup@4.66.0", "", { "dependencies": { "@types/estree": "1.0.9" }, "optionalDependencies": { "@napi-rs/lzma-linux-x64-gnu": "1.5.1", "@rollup/rollup-android-arm-eabi": "4.66.0", "@rollup/rollup-android-arm64": "4.66.0", "@rollup/rollup-darwin-arm64": "4.66.0", "@rollup/rollup-darwin-x64": "4.66.0", "@rollup/rollup-freebsd-arm64": "4.66.0", "@rollup/rollup-freebsd-x64": "4.66.0", "@rollup/rollup-linux-arm-gnueabihf": "4.66.0", "@rollup/rollup-linux-arm-musleabihf": "4.66.0", "@rollup/rollup-linux-arm64-gnu": "4.66.0", "@rollup/rollup-linux-arm64-musl": "4.66.0", "@rollup/rollup-linux-loong64-gnu": "4.66.0", "@rollup/rollup-linux-loong64-musl": "4.66.0", "@rollup/rollup-linux-ppc64-gnu": "4.66.0", "@rollup/rollup-linux-ppc64-musl": "4.66.0", "@rollup/rollup-linux-riscv64-gnu": "4.66.0", "@rollup/rollup-linux-riscv64-musl": "4.66.0", "@rollup/rollup-linux-s390x-gnu": "4.66.0", "@rollup/rollup-linux-x64-gnu": "4.66.0", "@rollup/rollup-linux-x64-musl": "4.66.0", "@rollup/rollup-openbsd-x64": "4.66.0", "@rollup/rollup-openharmony-arm64": "4.66.0", "@rollup/rollup-win32-arm64-msvc": "4.66.0", "@rollup/rollup-win32-ia32-msvc": "4.66.0", "@rollup/rollup-win32-x64-gnu": "4.66.0", "@rollup/rollup-win32-x64-msvc": "4.66.0", "fsevents": "~2.3.2" }, "bin": { "rollup": "dist/bin/rollup" } }, "sha512-Onq6/qO4ARhxIs+jYiHE0pYehadLyMECAiGEqQ+0/aWND3+2PmifJIIqBLYtuBODqHTlOUEQFtIVPyCy0Lck7A=="],
|
||||||
|
|
||||||
|
"roughjs": ["roughjs@4.6.6", "", { "dependencies": { "hachure-fill": "^0.5.2", "path-data-parser": "^0.1.0", "points-on-curve": "^0.2.0", "points-on-path": "^0.2.1" } }, "sha512-ZUz/69+SYpFN/g/lUlo2FXcIjRkSu3nDarreVdGGndHEBJ6cXPdKguS8JGxwj5HA5xIbVKSmLgr5b3AWxtRfvQ=="],
|
||||||
|
|
||||||
|
"rw": ["rw@1.3.3", "", {}, "sha512-PdhdWy89SiZogBLaw42zdeqtRJ//zFd2PgQavcICDUgJT5oW10QCRKbJ6bg4r0/UY2M6BWd5tkxuGFRvCkgfHQ=="],
|
||||||
|
|
||||||
|
"safer-buffer": ["safer-buffer@2.1.2", "", {}, "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="],
|
||||||
|
|
||||||
|
"scheduler": ["scheduler@0.28.0", "", {}, "sha512-juorfCmIkIw8tT+p5BXSm6PJjQF/ycEYmKyzURCIt/RaZIhL+PulbQ9Yu2z1HdOJDdqDTlxA1+xKBmHXJsczAw=="],
|
||||||
|
|
||||||
|
"semver": ["semver@6.3.1", "", { "bin": { "semver": "bin/semver.js" } }, "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA=="],
|
||||||
|
|
||||||
|
"simple-icons": ["simple-icons@16.34.0", "", {}, "sha512-UTxKn0PVspk84B2hHF3Dqiqht1yDjJmDc/t4cO7PyCQxCMk6OjEu95pnpGjhLaGeQ4qBrGASbefTIe/+czrX7g=="],
|
||||||
|
|
||||||
|
"source-map-js": ["source-map-js@1.2.2", "", {}, "sha512-KGj/8Y43x35aZVDtt+J4mK1hoLGHULMYfSkODJNQjNDC3oW1PqPoxMwo0pLUsWM/UEGzON/NxeHywEfNXNP3Vw=="],
|
||||||
|
|
||||||
|
"string-width": ["string-width@8.3.0", "", { "dependencies": { "get-east-asian-width": "^1.5.0", "strip-ansi": "^7.1.2" } }, "sha512-ZbmZM0JCihQN91dWnxoipT2KOEyHqEyfRXUyjuRhW8b/xnqPDoq4gWEVApTVa9db2wN8mmoikgFBbjh71+cGeQ=="],
|
||||||
|
|
||||||
|
"strip-ansi": ["strip-ansi@7.2.0", "", { "dependencies": { "ansi-regex": "^6.2.2" } }, "sha512-yDPMNjp4WyfYBkHnjIRLfca1i6KMyGCtsVgoKe/z1+6vukgaENdgGBZt+ZmKPc4gavvEZ5OgHfHdrazhgNyG7w=="],
|
||||||
|
|
||||||
|
"stylis": ["stylis@4.4.0", "", {}, "sha512-5Z9ZpRzfuH6l/UAvCPAPUo3665Nk2wLaZU3x+TLHKVzIz33+sbJqbtrYoC3KD4/uVOr2Zp+L0LySezP9OHV9yA=="],
|
||||||
|
|
||||||
|
"tabbable": ["tabbable@6.5.1", "", {}, "sha512-dMCuwDUY6Noz3zVKLefBC4wq+aJV20yc7vWmM7uTNGwtQSFF5kX7OUIUsxuVajz/bdt5Xqdah3/0NLjth+cM5A=="],
|
||||||
|
|
||||||
|
"tailwind-merge": ["tailwind-merge@3.7.0", "", {}, "sha512-XPPUyAc+cvspz3lHTcR/QgPfW2A0lv/xQNIjX3HGhLR+Nq2lHaLq5MtTesHn8GUr3W3DguT2KT5x3NVgRtYwmA=="],
|
||||||
|
|
||||||
|
"tailwindcss": ["tailwindcss@4.3.3", "", {}, "sha512-gOhV3P7ufE62QDGg1zVaTgCR+EtPv92k2nIhVcVKcLmxT1sUBsQGhnZj175j+MqRt4zLF7ic+sCYjfhxMxj7YQ=="],
|
||||||
|
|
||||||
|
"tinyexec": ["tinyexec@1.3.1", "", {}, "sha512-GCvB3aoys96IuDFBMcTB46JOR6mdMtAToqwiW8JlWhsoh1mhHi/xn9ss/Dg7N555GiJyEt2qzoG/NHCwM6h1EA=="],
|
||||||
|
|
||||||
|
"tinyglobby": ["tinyglobby@0.2.17", "", { "dependencies": { "fdir": "^6.5.0", "picomatch": "^4.0.4" } }, "sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g=="],
|
||||||
|
|
||||||
|
"ts-dedent": ["ts-dedent@2.3.0", "", {}, "sha512-JfJeIHke7y2egdGGgRAvpCwYFUsHlM2gPcrVOxFkznt/4uzQ7HFmvE63iFHVLBJNDuyDOQgijDK/tXH/f6Msjg=="],
|
||||||
|
|
||||||
|
"tslib": ["tslib@2.8.1", "", {}, "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w=="],
|
||||||
|
|
||||||
|
"typed-query-selector": ["typed-query-selector@2.12.3", "", {}, "sha512-/dtuMZyutHLlrxWhhC1uib00ELUr2dZ8C9B8YzZYsJmeE3V56OxRblrSM2UaF142pcMtak7ehZ6+poWGeehNIg=="],
|
||||||
|
|
||||||
|
"typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="],
|
||||||
|
|
||||||
|
"undici-types": ["undici-types@8.9.0", "", {}, "sha512-KTDyRTYX8sWmKXAikPHHSyc63CRPETMctyjKFupcC6OBLXT3xsN0e9aF7m+mIXutFWpUXuedtowG7iLOzp0kQg=="],
|
||||||
|
|
||||||
|
"update-browserslist-db": ["update-browserslist-db@1.3.4", "", { "dependencies": { "escalade": "^3.2.0", "picocolors": "^1.1.1" }, "peerDependencies": { "browserslist": ">= 4.21.0" }, "bin": { "update-browserslist-db": "cli.js" } }, "sha512-t8wonIOdQyOjtPd2VktlBu6QjTVTks6v8bSi7kd0r2Vll8TK1JYDZtRRdbmCHOAMphkZgrzK+L+vXK4pyZ8t4A=="],
|
||||||
|
|
||||||
|
"use-sync-external-store": ["use-sync-external-store@1.7.0", "", { "peerDependencies": { "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "sha512-6L+EeigHMQhdaIPNIFUKwfWJSwWFQ8gJbJ2DLOs5sDIegTwR9fRxvnM3uciHKjIZhFz+KAv2emhWMRvDmMcY8A=="],
|
||||||
|
|
||||||
|
"uuid": ["uuid@14.0.3", "", { "bin": { "uuid": "dist-node/bin/uuid" } }, "sha512-Sc5u1VVln93y1Xnz4R+CunOZc7R9LUcTmhj7Rc7Eg3HVcf7rVn2FOoa812fe0W8p3jD7xeoGSYbfqCGGH2B6xw=="],
|
||||||
|
|
||||||
|
"vite": ["vite@6.4.5", "", { "dependencies": { "esbuild": "^0.25.0", "fdir": "^6.4.4", "picomatch": "^4.0.2", "postcss": "^8.5.3", "rollup": "^4.34.9", "tinyglobby": "^0.2.13" }, "optionalDependencies": { "fsevents": "~2.3.3" }, "peerDependencies": { "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", "jiti": ">=1.21.0", "less": "*", "lightningcss": "^1.21.0", "sass": "*", "sass-embedded": "*", "stylus": "*", "sugarss": "*", "terser": "^5.16.0", "tsx": "^4.8.1", "yaml": "^2.4.2" }, "optionalPeers": ["@types/node", "jiti", "less", "lightningcss", "sass", "sass-embedded", "stylus", "sugarss", "terser", "tsx", "yaml"], "bin": { "vite": "bin/vite.js" } }, "sha512-4enwjFfi4IwtEh0w+jPzpLVOFQiPHmmzPxcHXQOyEur47o6u0jE573DmGpjA+7irXoMLYRZD5ZaFUEneS3abPg=="],
|
||||||
|
|
||||||
|
"webdriver-bidi-protocol": ["webdriver-bidi-protocol@1.0.1", "", {}, "sha512-WXWs/aXF2a6Al1Z2/V/7Gp2oPZOAAmHjJOTmv4KCXRJ122IMj3tSSMc6a4q3K4QOmhQbse/Ahr+oTVJOU2dUiw=="],
|
||||||
|
|
||||||
|
"wrap-ansi": ["wrap-ansi@9.0.2", "", { "dependencies": { "ansi-styles": "^6.2.1", "string-width": "^7.0.0", "strip-ansi": "^7.1.0" } }, "sha512-42AtmgqjV+X1VpdOfyTGOYRi0/zsoLqtXQckTmqTeybT+BDIbM/Guxo7x3pE2vtpr1ok6xRqM9OpBe+Jyoqyww=="],
|
||||||
|
|
||||||
|
"ws": ["ws@8.22.0", "", { "peerDependencies": { "bufferutil": "^4.0.1", "utf-8-validate": ">=5.0.2" }, "optionalPeers": ["bufferutil", "utf-8-validate"] }, "sha512-Ydggc987+RO0AnWtZ/7Wq9FtNvcrL1b/RO0ud9mWjUPgDrsAAwQSF51sm2hm1XofbU/4jkpGEsLFsZZxU+1DOg=="],
|
||||||
|
|
||||||
|
"y18n": ["y18n@5.0.8", "", {}, "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA=="],
|
||||||
|
|
||||||
|
"yallist": ["yallist@3.1.1", "", {}, "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g=="],
|
||||||
|
|
||||||
|
"yargs": ["yargs@18.2.0", "", { "dependencies": { "cliui": "^9.0.1", "escalade": "^3.1.1", "get-caller-file": "^2.0.5", "string-width": "^8.2.1", "y18n": "^5.0.5", "yargs-parser": "^22.0.0" } }, "sha512-9OpKOLeaoNFecEp7P6iYbzze/5CqWoH7N3SMs/6y1XF4nMvFMspEGZzJ6uFi9MmQwXhyzqYoSEKO3tvA3Z/o2w=="],
|
||||||
|
|
||||||
|
"yargs-parser": ["yargs-parser@22.0.0", "", {}, "sha512-rwu/ClNdSMpkSrUb+d6BRsSkLUq1fmfsY6TOpYzTwvwkg1/NRG85KBy3kq++A8LKQwX6lsu+aWad+2khvuXrqw=="],
|
||||||
|
|
||||||
|
"yocto-queue": ["yocto-queue@1.2.2", "", {}, "sha512-4LCcse/U2MHZ63HAJVE+v71o7yOdIe4cZ70Wpf8D/IyjDKYQLV5GD46B+hSTjJsvV5PztjvHoU580EftxjDZFQ=="],
|
||||||
|
|
||||||
|
"zod": ["zod@4.6.7", "", {}, "sha512-g8W2D2kU6a8untc053fX1uVBKzM7yqAxW/3zwk83+6RyF2+SKOuV+c0wBDhUwzV1PaGapmZH+rmcUzPf+3CGwg=="],
|
||||||
|
|
||||||
|
"@headlessui/react/@floating-ui/react": ["@floating-ui/react@0.26.28", "", { "dependencies": { "@floating-ui/react-dom": "^2.1.2", "@floating-ui/utils": "^0.2.8", "tabbable": "^6.0.0" }, "peerDependencies": { "react": ">=16.8.0", "react-dom": ">=16.8.0" } }, "sha512-yORQuuAtVpiRjpMhdc0wJj06b9JFjrYF4qp96j++v2NBpbi6SEGF7donUJ3TMieerQ6qVkAv1tgr7L4r5roTqw=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-array": ["@types/d3-array@3.2.2", "", {}, "sha512-hOLWVbm7uRza0BYXpIIW5pxfrKe0W+D5lrFiAEYR+pb6w3N2SwSMaJbXdUfSEv+dT4MfHBLtn5js0LAWaO6otw=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-color": ["@types/d3-color@3.1.3", "", {}, "sha512-iO90scth9WAbmgv7ogoq57O9YpKmFBbmoEoCHDB2xMBY0+/KVrqAaCDyCE16dUspeOvIxFFRI+0sEtqDqy2b4A=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-delaunay": ["@types/d3-delaunay@6.0.4", "", {}, "sha512-ZMaSKu4THYCU6sV64Lhg6qjf1orxBthaC161plr5KuPHo3CNm8DTHiLw/5Eq2b6TsNP0W0iJrUOFscY6Q450Hw=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-format": ["@types/d3-format@3.0.4", "", {}, "sha512-fALi2aI6shfg7vM5KiR1wNJnZ7r6UuggVqtDA+xiEdPZQwy/trcQaHnwShLuLdta2rTymCNpxYTiMZX/e09F4g=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-geo": ["@types/d3-geo@3.1.1", "", { "dependencies": { "@types/geojson": "*" } }, "sha512-65Emv9fQiQQqphLlRkuQ5ypPsOmWPhtBGCMv61JDPEPMvsx+gzhGf74yw1a78xFKPj6zw4AgQICJoQv0vK9M2w=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-interpolate": ["@types/d3-interpolate@3.0.4", "", { "dependencies": { "@types/d3-color": "*" } }, "sha512-mgLPETlrpVV1YRJIglr4Ez47g7Yxjl1lj7YKsiMCb27VJH9W8NVM6Bb9d8kkpG/uAQS5AmbA48q2IAolKKo1MA=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-scale": ["@types/d3-scale@4.0.9", "", { "dependencies": { "@types/d3-time": "*" } }, "sha512-dLmtwB8zkAeO/juAMfnV+sItKjlsw2lKdZVVy6LRr0cBmegxSABiLEpGVmSJJ8O08i4+sGR6qQtb6WtuwJdvVw=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-shape": ["@types/d3-shape@3.2.0", "", { "dependencies": { "@types/d3-path": "*" } }, "sha512-kVd74ta9eof3eJOvbNd1vGKS/XERRyQbT26Og63hIsvDO84cjD5gEOhsXf26w3FSoNlPVz84DOFcKv/oou+fMw=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-time": ["@types/d3-time@3.0.4", "", {}, "sha512-yuzZug1nkAAaBlBBikKZTgzCeA+k1uy4ZFwWANOfKw5z5LRhV0gNA7gNkKm7HoK+HRN0wX3EkxGk0fpbWhmB7g=="],
|
||||||
|
|
||||||
|
"@types/d3/@types/d3-time-format": ["@types/d3-time-format@4.0.3", "", {}, "sha512-5xg9rC+wWL8kdDj153qZcsJ0FWiFt0J5RB6LYUNZjwSnesfblqrI/bJ1wBdJ8OQfncgbJG5+2F+qfqnqyzYxyg=="],
|
||||||
|
|
||||||
|
"@types/d3-contour/@types/d3-array": ["@types/d3-array@3.2.2", "", {}, "sha512-hOLWVbm7uRza0BYXpIIW5pxfrKe0W+D5lrFiAEYR+pb6w3N2SwSMaJbXdUfSEv+dT4MfHBLtn5js0LAWaO6otw=="],
|
||||||
|
|
||||||
|
"@types/d3-interpolate/@types/d3-color": ["@types/d3-color@3.1.3", "", {}, "sha512-iO90scth9WAbmgv7ogoq57O9YpKmFBbmoEoCHDB2xMBY0+/KVrqAaCDyCE16dUspeOvIxFFRI+0sEtqDqy2b4A=="],
|
||||||
|
|
||||||
|
"@types/d3-scale/@types/d3-time": ["@types/d3-time@3.0.4", "", {}, "sha512-yuzZug1nkAAaBlBBikKZTgzCeA+k1uy4ZFwWANOfKw5z5LRhV0gNA7gNkKm7HoK+HRN0wX3EkxGk0fpbWhmB7g=="],
|
||||||
|
|
||||||
|
"@types/d3-zoom/@types/d3-interpolate": ["@types/d3-interpolate@3.0.4", "", { "dependencies": { "@types/d3-color": "*" } }, "sha512-mgLPETlrpVV1YRJIglr4Ez47g7Yxjl1lj7YKsiMCb27VJH9W8NVM6Bb9d8kkpG/uAQS5AmbA48q2IAolKKo1MA=="],
|
||||||
|
|
||||||
|
"@zenuml/core/marked": ["marked@4.3.0", "", { "bin": { "marked": "bin/marked.js" } }, "sha512-PRsaiG84bK+AMvxziE/lCFss8juXjNaWzVbN5tXAm4XjeaS9NAHhop+PjQxz2A9h8Q4M/xGmzP8vqNwy6JeK0A=="],
|
||||||
|
|
||||||
|
"cliui/string-width": ["string-width@7.2.0", "", { "dependencies": { "emoji-regex": "^10.3.0", "get-east-asian-width": "^1.0.0", "strip-ansi": "^7.1.0" } }, "sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ=="],
|
||||||
|
|
||||||
|
"cytoscape-fcose/cose-base": ["cose-base@2.2.0", "", { "dependencies": { "layout-base": "^2.0.0" } }, "sha512-AzlgcsCbUMymkADOJtQm3wO9S3ltPfYOFD5033keQn9NJzIbtnZj+UdBJe7DYml/8TdbtHJW3j58SOnKhWY/5g=="],
|
||||||
|
|
||||||
|
"d3/d3-array": ["d3-array@3.2.4", "", { "dependencies": { "internmap": "1 - 2" } }, "sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg=="],
|
||||||
|
|
||||||
|
"d3/d3-delaunay": ["d3-delaunay@6.0.4", "", { "dependencies": { "delaunator": "5" } }, "sha512-mdjtIZ1XLAM8bm/hx3WwjfHt6Sggek7qH043O8KEjDXN40xi3vx/6pYSVTwLjEgiXQTbvaouWKynLBiUZ6SK6A=="],
|
||||||
|
|
||||||
|
"d3/d3-format": ["d3-format@3.1.2", "", {}, "sha512-AJDdYOdnyRDV5b6ArilzCPPwc1ejkHcoyFarqlPqT7zRYjhavcT3uSrqcMvsgh2CgoPbK3RCwyHaVyxYcP2Arg=="],
|
||||||
|
|
||||||
|
"d3/d3-geo": ["d3-geo@3.1.1", "", { "dependencies": { "d3-array": "2.5.0 - 3" } }, "sha512-637ln3gXKXOwhalDzinUgY83KzNWZRKbYubaG+fGVuc/dxO64RRljtCTnf5ecMyE1RIdtqpkVcq0IbtU2S8j2Q=="],
|
||||||
|
|
||||||
|
"d3-contour/d3-array": ["d3-array@3.2.4", "", { "dependencies": { "internmap": "1 - 2" } }, "sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg=="],
|
||||||
|
|
||||||
|
"d3-dsv/commander": ["commander@7.2.0", "", {}, "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw=="],
|
||||||
|
|
||||||
|
"d3-geo/d3-array": ["d3-array@3.2.4", "", { "dependencies": { "internmap": "1 - 2" } }, "sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg=="],
|
||||||
|
|
||||||
|
"d3-sankey/d3-array": ["d3-array@2.12.1", "", { "dependencies": { "internmap": "^1.0.0" } }, "sha512-B0ErZK/66mHtEsR1TkPEEkwdy+WDesimkM5gpZr5Dsg54BiTA5RXtYW5qTLIAcekaS9xfZrzBLF/OAkB3Qn1YQ=="],
|
||||||
|
|
||||||
|
"d3-sankey/d3-shape": ["d3-shape@1.3.7", "", { "dependencies": { "d3-path": "1" } }, "sha512-EUkvKjqPFUAZyOlhY5gzCxCeI0Aep04LwIRpsZ/mLFelJiUfnK56jo5JMDSE7yyP2kLSb6LtF+S5chMk7uqPqw=="],
|
||||||
|
|
||||||
|
"d3-scale/d3-array": ["d3-array@3.2.4", "", { "dependencies": { "internmap": "1 - 2" } }, "sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg=="],
|
||||||
|
|
||||||
|
"d3-scale/d3-format": ["d3-format@3.1.2", "", {}, "sha512-AJDdYOdnyRDV5b6ArilzCPPwc1ejkHcoyFarqlPqT7zRYjhavcT3uSrqcMvsgh2CgoPbK3RCwyHaVyxYcP2Arg=="],
|
||||||
|
|
||||||
|
"d3-time/d3-array": ["d3-array@3.2.4", "", { "dependencies": { "internmap": "1 - 2" } }, "sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg=="],
|
||||||
|
|
||||||
|
"katex/commander": ["commander@8.3.0", "", {}, "sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww=="],
|
||||||
|
|
||||||
|
"mermaid/katex": ["katex@0.18.11", "", { "dependencies": { "commander": "^15.0.0" }, "bin": { "katex": "cli.js" } }, "sha512-yvyz/2VMKqoho/35Hat5w37wIEdWJ5ElVMidTAlWrxr5uW4aBGsEpveTmKh18/zw08v/7lGswCPon4OhqmqrTA=="],
|
||||||
|
|
||||||
|
"reduce-function-call/balanced-match": ["balanced-match@1.0.2", "", {}, "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw=="],
|
||||||
|
|
||||||
|
"rollup/fsevents": ["fsevents@2.3.3", "", { "os": "darwin" }, "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw=="],
|
||||||
|
|
||||||
|
"vite/fsevents": ["fsevents@2.3.3", "", { "os": "darwin" }, "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw=="],
|
||||||
|
|
||||||
|
"wrap-ansi/string-width": ["string-width@7.2.0", "", { "dependencies": { "emoji-regex": "^10.3.0", "get-east-asian-width": "^1.0.0", "strip-ansi": "^7.1.0" } }, "sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ=="],
|
||||||
|
|
||||||
|
"@types/d3-zoom/@types/d3-interpolate/@types/d3-color": ["@types/d3-color@3.1.3", "", {}, "sha512-iO90scth9WAbmgv7ogoq57O9YpKmFBbmoEoCHDB2xMBY0+/KVrqAaCDyCE16dUspeOvIxFFRI+0sEtqDqy2b4A=="],
|
||||||
|
|
||||||
|
"cytoscape-fcose/cose-base/layout-base": ["layout-base@2.0.1", "", {}, "sha512-dp3s92+uNI1hWIpPGH3jK2kxE2lMjdXdr+DH8ynZHpd6PUlH6x6cbuXnoMmiNumznqaNO31xu9e79F0uuZ0JFg=="],
|
||||||
|
|
||||||
|
"d3-sankey/d3-array/internmap": ["internmap@1.0.1", "", {}, "sha512-lDB5YccMydFBtasVtxnZ3MRBHuaoE8GKsppq+EchKL2U4nK/DmEpPHNH8MZe5HkMtpSiTSOZwfN0tzYjO/lJEw=="],
|
||||||
|
|
||||||
|
"d3-sankey/d3-shape/d3-path": ["d3-path@1.0.9", "", {}, "sha512-VLaYcn81dtHVTjEHd8B+pbe9yHWpXKZUC87PzoFmsFrJqgFwDe/qxfp5MlfsfM1V5E/iVt0MmEbWQ7FVIXh/bg=="],
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -7,10 +7,11 @@ export const WRAPPED: { apple: Record<string, string>; play: Record<string, stri
|
||||||
'analyticsReportRequests_createInstance': 'analytics',
|
'analyticsReportRequests_createInstance': 'analytics',
|
||||||
'analyticsReportRequests_reports_getToManyRelated': 'analytics',
|
'analyticsReportRequests_reports_getToManyRelated': 'analytics',
|
||||||
'analyticsReports_instances_getToManyRelated': 'analytics',
|
'analyticsReports_instances_getToManyRelated': 'analytics',
|
||||||
'appAssetLibraries_images_getToManyRelated': 'apple/creative-assets',
|
'appAssetLibraries_images_getToManyRelated': 'apple/creative-assets apple/duo-library',
|
||||||
'appAssetLibraries_videos_getToManyRelated': 'apple/creative-assets',
|
'appAssetLibraries_videos_getToManyRelated': 'apple/creative-assets',
|
||||||
'appAssetLibraryPlacements_createInstance': 'apple/creative-assets',
|
'appAssetLibraryPlacements_createInstance': 'apple/creative-assets apple/duo-library',
|
||||||
'appAssetLibraryPlacements_deleteInstance': 'apple/creative-assets',
|
'appAssetLibraryPlacements_deleteInstance': 'apple/creative-assets apple/duo-library',
|
||||||
|
'appAssetLibraryRefData_getCollection': 'apple/duo-library',
|
||||||
'appAvailabilitiesV2_createInstance': 'apple/appinfo',
|
'appAvailabilitiesV2_createInstance': 'apple/appinfo',
|
||||||
'appAvailabilitiesV2_territoryAvailabilities_getToManyRelated': 'apple/appinfo apple/preorder',
|
'appAvailabilitiesV2_territoryAvailabilities_getToManyRelated': 'apple/appinfo apple/preorder',
|
||||||
'appCustomProductPageLocalizations_appScreenshotSets_getToManyRelated': 'apple/cpp',
|
'appCustomProductPageLocalizations_appScreenshotSets_getToManyRelated': 'apple/cpp',
|
||||||
|
|
@ -62,22 +63,22 @@ export const WRAPPED: { apple: Record<string, string>; play: Record<string, stri
|
||||||
'appStoreVersionExperimentsV2_getInstance': 'apple/ppo',
|
'appStoreVersionExperimentsV2_getInstance': 'apple/ppo',
|
||||||
'appStoreVersionExperimentsV2_updateInstance': 'lib/ppo',
|
'appStoreVersionExperimentsV2_updateInstance': 'lib/ppo',
|
||||||
'appStoreVersionLocalizations_appPreviewSets_getToManyRelated': 'apple/previews art',
|
'appStoreVersionLocalizations_appPreviewSets_getToManyRelated': 'apple/previews art',
|
||||||
'appStoreVersionLocalizations_appScreenshotSets_getToManyRelated': 'apple/screenshot-health apple/screenshots art validate',
|
'appStoreVersionLocalizations_appScreenshotSets_getToManyRelated': 'apple/device-families apple/screenshot-health apple/screenshots art validate',
|
||||||
'appStoreVersionLocalizations_createInstance': 'listing-store',
|
'appStoreVersionLocalizations_createInstance': 'listing-store',
|
||||||
'appStoreVersionLocalizations_placements_getToManyRelated': 'apple/creative-assets',
|
'appStoreVersionLocalizations_placements_getToManyRelated': 'apple/creative-assets apple/duo-library',
|
||||||
'appStoreVersionLocalizations_updateInstance': 'listing-store',
|
'appStoreVersionLocalizations_updateInstance': 'listing-store',
|
||||||
'appStoreVersionPhasedReleases_createInstance': 'apple/release',
|
'appStoreVersionPhasedReleases_createInstance': 'apple/release',
|
||||||
'appStoreVersionPhasedReleases_updateInstance': 'apple/release',
|
'appStoreVersionPhasedReleases_updateInstance': 'apple/release',
|
||||||
'appStoreVersionReleaseRequests_createInstance': 'apple/release',
|
'appStoreVersionReleaseRequests_createInstance': 'apple/release',
|
||||||
'appStoreVersions_appStoreReviewDetail_getToOneRelated': 'apple/review-details onboard validate',
|
'appStoreVersions_appStoreReviewDetail_getToOneRelated': 'apple/review-details onboard validate',
|
||||||
'appStoreVersions_appStoreVersionLocalizations_getToManyRelated': 'apple/creative-assets apple/listing apple/previews apple/screenshot-health apple/screenshots art listing-store onboard validate',
|
'appStoreVersions_appStoreVersionLocalizations_getToManyRelated': 'apple/creative-assets apple/device-families apple/listing apple/previews apple/screenshot-health apple/screenshots art listing-store onboard validate',
|
||||||
'appStoreVersions_appStoreVersionPhasedRelease_getToOneRelated': 'apple/release apple/status',
|
'appStoreVersions_appStoreVersionPhasedRelease_getToOneRelated': 'apple/release apple/status',
|
||||||
'appStoreVersions_build_getToOneRelated': 'apple/listing apple/resubmit validate',
|
'appStoreVersions_build_getToOneRelated': 'apple/device-families apple/listing apple/resubmit validate',
|
||||||
'appStoreVersions_build_updateToOneRelationship': 'apple/listing apple/resubmit',
|
'appStoreVersions_build_updateToOneRelationship': 'apple/listing apple/resubmit',
|
||||||
'appStoreVersions_createInstance': 'apple/listing',
|
'appStoreVersions_createInstance': 'apple/listing',
|
||||||
'appStoreVersions_gameCenterAppVersion_getToOneRelated': 'apple/game-center',
|
'appStoreVersions_gameCenterAppVersion_getToOneRelated': 'apple/game-center',
|
||||||
'appStoreVersions_getInstance': 'apple/listing',
|
'appStoreVersions_getInstance': 'apple/listing',
|
||||||
'appStoreVersions_updateInstance': 'apple/listing',
|
'appStoreVersions_updateInstance': 'apple/listing apple/release apple/resubmit',
|
||||||
'apps_analyticsReportRequests_getToManyRelated': 'analytics',
|
'apps_analyticsReportRequests_getToManyRelated': 'analytics',
|
||||||
'apps_appAvailabilityV2_getToOneRelated': 'apple/appinfo apple/preorder validate',
|
'apps_appAvailabilityV2_getToOneRelated': 'apple/appinfo apple/preorder validate',
|
||||||
'apps_appCustomProductPages_getToManyRelated': 'apple/cpp',
|
'apps_appCustomProductPages_getToManyRelated': 'apple/cpp',
|
||||||
|
|
@ -87,7 +88,7 @@ export const WRAPPED: { apple: Record<string, string>; play: Record<string, stri
|
||||||
'apps_appPriceSchedule_getToOneRelated': 'apple/appinfo validate',
|
'apps_appPriceSchedule_getToOneRelated': 'apple/appinfo validate',
|
||||||
'apps_appStoreVersionExperimentsV2_getToManyRelated': 'apple/ppo',
|
'apps_appStoreVersionExperimentsV2_getToManyRelated': 'apple/ppo',
|
||||||
'apps_appStoreVersions_getToManyRelated': 'apple/asc apple/creative-assets apple/iap-submit apple/platform apple/review-details apple/status art lib/store-apps listing-store onboard',
|
'apps_appStoreVersions_getToManyRelated': 'apple/asc apple/creative-assets apple/iap-submit apple/platform apple/review-details apple/status art lib/store-apps listing-store onboard',
|
||||||
'apps_assetLibrary_getToOneRelated': 'apple/creative-assets',
|
'apps_assetLibrary_getToOneRelated': 'apple/creative-assets apple/duo-library',
|
||||||
'apps_betaAppLocalizations_getToManyRelated': 'apple/testflight',
|
'apps_betaAppLocalizations_getToManyRelated': 'apple/testflight',
|
||||||
'apps_betaAppReviewDetail_getToOneRelated': 'apple/testflight',
|
'apps_betaAppReviewDetail_getToOneRelated': 'apple/testflight',
|
||||||
'apps_betaFeedbackCrashSubmissions_getToManyRelated': 'health',
|
'apps_betaFeedbackCrashSubmissions_getToManyRelated': 'health',
|
||||||
|
|
@ -96,7 +97,7 @@ export const WRAPPED: { apple: Record<string, string>; play: Record<string, stri
|
||||||
'apps_customerReviews_getToManyRelated': 'reviews',
|
'apps_customerReviews_getToManyRelated': 'reviews',
|
||||||
'apps_gameCenterDetail_getToOneRelated': 'apple/game-center',
|
'apps_gameCenterDetail_getToOneRelated': 'apple/game-center',
|
||||||
'apps_getCollection': 'apple/asc apple/bundle apps console/app-id console/verify lib/store-apps',
|
'apps_getCollection': 'apple/asc apple/bundle apps console/app-id console/verify lib/store-apps',
|
||||||
'apps_getInstance': 'apple/appinfo apple/status apps onboard watch',
|
'apps_getInstance': 'apple/appinfo apple/status apple/testflight apps onboard watch',
|
||||||
'apps_inAppPurchasesV2_getToManyRelated': 'apple/first-products apple/iap apple/iap-review apple/iap-submit apple/offer-codes apple/promoted apple/status catalog prices validate',
|
'apps_inAppPurchasesV2_getToManyRelated': 'apple/first-products apple/iap apple/iap-review apple/iap-submit apple/offer-codes apple/promoted apple/status catalog prices validate',
|
||||||
'apps_perfPowerMetrics_getToManyRelated': 'health',
|
'apps_perfPowerMetrics_getToManyRelated': 'health',
|
||||||
'apps_promotedPurchases_getToManyRelated': 'apple/promoted',
|
'apps_promotedPurchases_getToManyRelated': 'apple/promoted',
|
||||||
|
|
@ -122,6 +123,7 @@ export const WRAPPED: { apple: Record<string, string>; play: Record<string, stri
|
||||||
'betaTesterInvitations_createInstance': 'lib/testflight',
|
'betaTesterInvitations_createInstance': 'lib/testflight',
|
||||||
'betaTesters_createInstance': 'lib/testflight',
|
'betaTesters_createInstance': 'lib/testflight',
|
||||||
'betaTesters_getCollection': 'apple/testflight',
|
'betaTesters_getCollection': 'apple/testflight',
|
||||||
|
'buildBundles_buildBundleFileSizes_getToManyRelated': 'apple/device-families',
|
||||||
'buildUploadFiles_createInstance': 'lib/xcode',
|
'buildUploadFiles_createInstance': 'lib/xcode',
|
||||||
'buildUploadFiles_updateInstance': 'lib/xcode',
|
'buildUploadFiles_updateInstance': 'lib/xcode',
|
||||||
'buildUploads_buildUploadFiles_getToManyRelated': 'apple/upload',
|
'buildUploads_buildUploadFiles_getToManyRelated': 'apple/upload',
|
||||||
|
|
@ -130,8 +132,10 @@ export const WRAPPED: { apple: Record<string, string>; play: Record<string, stri
|
||||||
'builds_appEncryptionDeclaration_getToOneRelated': 'validate',
|
'builds_appEncryptionDeclaration_getToOneRelated': 'validate',
|
||||||
'builds_betaAppReviewSubmission_getToOneRelated': 'apple/testflight',
|
'builds_betaAppReviewSubmission_getToOneRelated': 'apple/testflight',
|
||||||
'builds_betaBuildLocalizations_getToManyRelated': 'apple/testflight',
|
'builds_betaBuildLocalizations_getToManyRelated': 'apple/testflight',
|
||||||
|
'builds_buildBetaDetail_getToOneRelated': 'apple/testflight',
|
||||||
'builds_diagnosticSignatures_getToManyRelated': 'health',
|
'builds_diagnosticSignatures_getToManyRelated': 'health',
|
||||||
'builds_getCollection': 'apple/build apple/build-mas apple/encryption apple/listing apple/next-build apple/resubmit apple/status apple/testflight apple/upload art health lib/store-apps triage',
|
'builds_getCollection': 'apple/encryption apple/listing apple/next-build apple/resubmit apple/status apple/testflight apple/upload art health lib/store-apps triage',
|
||||||
|
'builds_getInstance': 'apple/device-families',
|
||||||
'builds_updateInstance': 'apple/encryption lib/build-ops',
|
'builds_updateInstance': 'apple/encryption lib/build-ops',
|
||||||
'bundleIdCapabilities_createInstance': 'lib/signing',
|
'bundleIdCapabilities_createInstance': 'lib/signing',
|
||||||
'bundleIds_createInstance': 'apple/bundle apple/signing',
|
'bundleIds_createInstance': 'apple/bundle apple/signing',
|
||||||
|
|
@ -242,13 +246,13 @@ export const WRAPPED: { apple: Record<string, string>; play: Record<string, stri
|
||||||
'androidpublisher.edits.bundles.upload': 'play/release play/upload',
|
'androidpublisher.edits.bundles.upload': 'play/release play/upload',
|
||||||
'androidpublisher.edits.commit': 'play/client',
|
'androidpublisher.edits.commit': 'play/client',
|
||||||
'androidpublisher.edits.countryavailability.get': 'validate',
|
'androidpublisher.edits.countryavailability.get': 'validate',
|
||||||
'androidpublisher.edits.delete': 'apps onboard play/client validate',
|
'androidpublisher.edits.delete': 'apps onboard play/client',
|
||||||
'androidpublisher.edits.details.get': 'apps onboard play/listing play/status validate',
|
'androidpublisher.edits.details.get': 'apps onboard play/listing play/status validate',
|
||||||
'androidpublisher.edits.details.update': 'play/listing',
|
'androidpublisher.edits.details.update': 'play/listing',
|
||||||
'androidpublisher.edits.images.deleteall': 'play/images',
|
'androidpublisher.edits.images.deleteall': 'play/images',
|
||||||
'androidpublisher.edits.images.list': 'apps art play/images play/listing validate',
|
'androidpublisher.edits.images.list': 'apps art play/images play/listing validate',
|
||||||
'androidpublisher.edits.images.upload': 'play/images play/listing',
|
'androidpublisher.edits.images.upload': 'play/images play/listing',
|
||||||
'androidpublisher.edits.insert': 'apps onboard play/client validate',
|
'androidpublisher.edits.insert': 'apps onboard play/client',
|
||||||
'androidpublisher.edits.listings.get': 'onboard',
|
'androidpublisher.edits.listings.get': 'onboard',
|
||||||
'androidpublisher.edits.listings.list': 'art listing-store play/listing play/status validate',
|
'androidpublisher.edits.listings.list': 'art listing-store play/listing play/status validate',
|
||||||
'androidpublisher.edits.listings.patch': 'listing-store',
|
'androidpublisher.edits.listings.patch': 'listing-store',
|
||||||
|
|
|
||||||
57
cli/apple/asset-library.ts
Normal file
57
cli/apple/asset-library.ts
Normal file
|
|
@ -0,0 +1,57 @@
|
||||||
|
// App Asset Library states and upsert rules shared by creative assets and iPhone Duo screenshots. No command flags here.
|
||||||
|
import * as rt from '../lib/rt';
|
||||||
|
import type { J } from './asc';
|
||||||
|
|
||||||
|
export const REF = (sum: string): string => `storebound ${sum}`;
|
||||||
|
export const sumOf = (a: J): string | undefined => /^storebound ([0-9a-f]{32})$/.exec(String(a?.attributes?.referenceName ?? ''))?.[1];
|
||||||
|
|
||||||
|
/** Asset states (AppAssetLibraryAssetState, API 4.5.1) by what storebound may do with them. */
|
||||||
|
export const ASSET_STATES = {
|
||||||
|
/** still uploading / processing: wait (bounded), then select */
|
||||||
|
processing: ['AWAITING_UPLOAD', 'UPLOAD_COMPLETE'],
|
||||||
|
/** processed and usable in a slot; not reviewed yet: goes into a review submission */
|
||||||
|
unreviewed: ['COMPLETE', 'PREPARE_FOR_SUBMISSION'],
|
||||||
|
/** in a submission or reviewed: usable in a slot, nothing to add */
|
||||||
|
reviewing: ['READY_FOR_REVIEW', 'WAITING_FOR_REVIEW', 'IN_REVIEW', 'ACCEPTED', 'APPROVED'],
|
||||||
|
} as const;
|
||||||
|
export type AssetClass = 'processing' | 'unreviewed' | 'reviewing' | 'failed' | 'rejected' | 'archived' | 'unknown';
|
||||||
|
|
||||||
|
/** What a library asset's state means for storebound. Pure. */
|
||||||
|
export function classify(state: string | undefined): AssetClass {
|
||||||
|
const s = String(state ?? '');
|
||||||
|
for (const [k, v] of Object.entries(ASSET_STATES)) if ((v as readonly string[]).includes(s)) return k as AssetClass;
|
||||||
|
if (s === 'FAILED') return 'failed';
|
||||||
|
if (s === 'REJECTED') return 'rejected';
|
||||||
|
if (s === 'ARCHIVED') return 'archived';
|
||||||
|
return s ? 'unknown' : 'processing';
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Selectable for a slot: processed and not failed / rejected / archived (Prepare for Submission is enough). */
|
||||||
|
export const selectable = (c: AssetClass): boolean => c === 'unreviewed' || c === 'reviewing';
|
||||||
|
|
||||||
|
/** Stop re-uploading a file whose earlier uploads failed processing this many times. */
|
||||||
|
export const MAX_FAILED = 2;
|
||||||
|
|
||||||
|
/** The library asset to use for one MD5: a live one first (newest state wins: reviewing > unreviewed > processing),
|
||||||
|
* else an archived one (unarchive it), else none; plus why not to upload (a rejected file, repeated failures). Pure. */
|
||||||
|
export function pickAsset(assets: J[], sum: string): { asset?: J; unarchive?: boolean; refuse?: string } {
|
||||||
|
const mine = assets.filter(x => sumOf(x) === sum);
|
||||||
|
const rank: Record<AssetClass, number> = { reviewing: 0, unreviewed: 1, processing: 2, unknown: 3, archived: 4, rejected: 5, failed: 6 };
|
||||||
|
const by = (c: AssetClass) => mine.filter(x => classify(x.attributes?.state) === c);
|
||||||
|
const live = mine.filter(x => rank[classify(x.attributes?.state)] <= 3).sort((a, b) => rank[classify(a.attributes?.state)] - rank[classify(b.attributes?.state)]);
|
||||||
|
if (live[0]) return { asset: live[0] };
|
||||||
|
if (by('archived')[0]) return { asset: by('archived')[0], unarchive: true };
|
||||||
|
const rej = by('rejected')[0];
|
||||||
|
if (rej) return { refuse: `rejected by App Review${reason(rej)}: uploading the same file again changes nothing; change the file` };
|
||||||
|
if (by('failed').length >= MAX_FAILED) return { refuse: `${by('failed').length} earlier uploads of this file failed processing${reason(by('failed')[0]!)}: check the file (format, size) before trying again` };
|
||||||
|
return {};
|
||||||
|
}
|
||||||
|
|
||||||
|
export const reason = (a: J): string => {
|
||||||
|
const d = ((a.attributes?.stateDetails ?? []) as J[]).map(x => x?.code ?? x?.message ?? x?.description).filter(Boolean);
|
||||||
|
return d.length ? ` (${d.join(', ')})` : '';
|
||||||
|
};
|
||||||
|
|
||||||
|
/** Bounded wait for processing (every wait has a timeout and a heartbeat); tests set waitMs 0 / timeoutMs 0. */
|
||||||
|
export const processingTiming = { pollMs: 3000, timeoutMs: 120_000, heartbeatMs: 20_000, sleep: (ms: number): Promise<void> => (ms > 0 ? rt.sleep(ms) : Promise.resolve()) };
|
||||||
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
// Mac App Store build of a Tauri app: `tauri build --bundles app`, signed for the Mac App Store, then productbuild to a .pkg.
|
// Mac App Store build of a Tauri app: `tauri build --bundles app`, signed for the Mac App Store, then productbuild to a .pkg.
|
||||||
// storebound apple build --platform macos --tauri <src-tauri> [--path-free] [--target universal-apple-darwin]
|
// storebound apple build --platform macos --tauri <src-tauri> [--path-free] [--target universal-apple-darwin]
|
||||||
// [--version x.y.z] [--build-number N] [--profile <file.provisionprofile>] [--out build/macos] [--unsigned] [--dry] [--json]
|
// [--entitlements <plist>] [--allow-entitlements] [--version x.y.z] [--build-number N] [--profile <file.provisionprofile>] [--out build/macos] [--unsigned] [--dry] [--json]
|
||||||
// Steps: Tauri project -> version / build number (next free one on App Store Connect, platform MAC_OS) -> signing
|
// Steps: Tauri project -> version / build number (next free one on App Store Connect, every platform) -> signing
|
||||||
// identities from the keychain ("Apple Distribution" or "3rd Party Mac Developer Application"; "Mac Installer
|
// identities from the keychain ("Apple Distribution" or "3rd Party Mac Developer Application"; "Mac Installer
|
||||||
// Distribution" or "3rd Party Mac Developer Installer") -> Mac App Store provisioning profile (--profile, installed, or
|
// Distribution" or "3rd Party Mac Developer Installer") -> Mac App Store provisioning profile (--profile, installed, or
|
||||||
// from the API) -> entitlements (app sandbox + application / team identifier, the project's own keys kept) -> a
|
// from the API) -> entitlements (app sandbox + application / team identifier, the project's own keys kept) -> a
|
||||||
|
|
@ -19,12 +19,15 @@ import type { Ctx } from '../lib/ctx';
|
||||||
import { need } from '../lib/ctx';
|
import { need } from '../lib/ctx';
|
||||||
import { done, log, printJson, warn } from '../lib/log';
|
import { done, log, printJson, warn } from '../lib/log';
|
||||||
import { parseMobileprovision, parsePlist, type PlistValue } from '../lib/plist';
|
import { parseMobileprovision, parsePlist, type PlistValue } from '../lib/plist';
|
||||||
import { nextBuildNumber } from '../lib/release';
|
import { appNextBuild } from './next-build';
|
||||||
import { parseIdentities, profileDirs, readProfiles, type ApiProfile } from '../lib/signing';
|
import { parseIdentities, profileDirs, readProfiles, type ApiProfile } from '../lib/signing';
|
||||||
import { sshBuildRefusal } from '../lib/keychain';
|
import { sshBuildRefusal } from '../lib/keychain';
|
||||||
import { remoteBuildSession, showCmd } from '../lib/xcode';
|
import { remoteBuildSession, showCmd } from '../lib/xcode';
|
||||||
|
import { prebuildFor, prebuildsDone, runPrebuild } from '../lib/web-assets';
|
||||||
|
import { preCheckCommand } from '../lib/pre-check';
|
||||||
|
import { pump } from '../lib/runner';
|
||||||
import {
|
import {
|
||||||
appProblems, entitlementKeysOf, entitlementsXml, findBuiltApp, findTauri, leakNeedles, masEntitlements, type MasProfile, masSteps, pathFreeEnv, pickMasIdentities,
|
appProblems, entitlementKeysOf, entitlementsSource, entitlementsXml, findBuiltApp, findTauri, leakNeedles, masEntitlementProblems, masEntitlements, type MasProfile, masSteps, pathFreeEnv, pickMasIdentities,
|
||||||
pickMasProfiles, pkgProblems, parsePkgSignature, readAppInfo, scanPathLeaks, tauriOverlay, categoryId,
|
pickMasProfiles, pkgProblems, parsePkgSignature, readAppInfo, scanPathLeaks, tauriOverlay, categoryId,
|
||||||
} from '../lib/mas';
|
} from '../lib/mas';
|
||||||
import { readdirSync } from 'node:fs';
|
import { readdirSync } from 'node:fs';
|
||||||
|
|
@ -41,6 +44,16 @@ const run1 = (argv: string[], timeout = 120_000): { ok: boolean; out: string } =
|
||||||
};
|
};
|
||||||
|
|
||||||
/** The Tauri CLI: the project's node_modules/.bin/tauri (walking up), `cargo tauri`, else bunx. */
|
/** The Tauri CLI: the project's node_modules/.bin/tauri (walking up), `cargo tauri`, else bunx. */
|
||||||
|
/** One sh -c command in root, its output streamed; the exit code and the last lines. */
|
||||||
|
async function runCheck(cmd: string, root: string): Promise<{ ok: boolean; code: number; tail: string }> {
|
||||||
|
const p = rt.spawn(['sh', '-c', cmd], { cwd: root, stdin: 'ignore', stdout: 'pipe', stderr: 'pipe', env: process.env });
|
||||||
|
const tail: string[] = [];
|
||||||
|
const each = (line: string, kind: 'stdout' | 'stderr'): void => { tail.push(line); if (tail.length > 10) tail.shift(); (kind === 'stderr' ? console.error : console.log)(` ${line}`); };
|
||||||
|
await Promise.all([pump(p.stdout, 'stdout', each), pump(p.stderr, 'stderr', each)]);
|
||||||
|
const code = await p.exited;
|
||||||
|
return { ok: code === 0, code, tail: tail.join('\n') };
|
||||||
|
}
|
||||||
|
|
||||||
export function tauriCommand(cwd: string, exists: (p: string) => boolean = existsSync, which: (c: string) => string | null = rt.which): string[] {
|
export function tauriCommand(cwd: string, exists: (p: string) => boolean = existsSync, which: (c: string) => string | null = rt.which): string[] {
|
||||||
for (let d = cwd, prev = ''; d !== prev; prev = d, d = dirname(d)) { const p = join(d, 'node_modules', '.bin', 'tauri'); if (exists(p)) return [p]; }
|
for (let d = cwd, prev = ''; d !== prev; prev = d, d = dirname(d)) { const p = join(d, 'node_modules', '.bin', 'tauri'); if (exists(p)) return [p]; }
|
||||||
if (which('cargo-tauri')) return ['cargo', 'tauri'];
|
if (which('cargo-tauri')) return ['cargo', 'tauri'];
|
||||||
|
|
@ -72,7 +85,13 @@ async function fetchMasProfile(c: Asc, bundleId: string, dest: string): Promise<
|
||||||
return dest;
|
return dest;
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function run(ctx: Ctx): Promise<void> {
|
/** The dry-run line about signing identities: on a machine that is not a Mac, say so instead of "none found". */
|
||||||
|
export function identityLine(o: { platform: string; appIdentity: string | null; installerIdentity: string | null; profile: string | null }): string {
|
||||||
|
if (o.platform !== 'darwin') return `this is not a build machine: Mac App Store builds run on a Mac (the signing identities live in its keychain), so none were looked up here; profile: ${o.profile ?? '(none)'}`;
|
||||||
|
return `app identity: ${o.appIdentity ?? '(none found)'}; installer identity: ${o.installerIdentity ?? '(none found)'}; profile: ${o.profile ?? '(none)'}`;
|
||||||
|
}
|
||||||
|
|
||||||
|
export async function run(ctx: Ctx, platform: string = process.platform): Promise<void> {
|
||||||
const { config, root, resolve } = ctx.loaded;
|
const { config, root, resolve } = ctx.loaded;
|
||||||
const a = ctx.args;
|
const a = ctx.args;
|
||||||
const bundleId = need(config.apple?.bundleId, 'apple.bundleId');
|
const bundleId = need(config.apple?.bundleId, 'apple.bundleId');
|
||||||
|
|
@ -92,9 +111,10 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
try {
|
try {
|
||||||
client = await ascClient(root, bundleId, config.apple?.appId);
|
client = await ascClient(root, bundleId, config.apple?.appId);
|
||||||
if (!build) {
|
if (!build) {
|
||||||
const builds = await client.all(`/v1/builds?filter[app]=${await client.app()}&filter[preReleaseVersion.platform]=MAC_OS&limit=200&fields[builds]=version`);
|
// every platform of the app record, not only macOS: CFBundleVersion must be unique across all its builds
|
||||||
build = nextBuildNumber(builds.map(b => String(b.attributes.version)));
|
const found = await appNextBuild(client);
|
||||||
log(TAG, `${builds.length} macOS builds on App Store Connect: next build number ${build} (CFBundleVersion must increase)`);
|
build = found.next;
|
||||||
|
log(TAG, `${found.builds} builds (all platforms) on App Store Connect: next build number ${build} (CFBundleVersion must increase)`);
|
||||||
}
|
}
|
||||||
if (!teamId) teamId = (await findBundleId(client, bundleId))?.attributes?.seedId ?? null;
|
if (!teamId) teamId = (await findBundleId(client, bundleId))?.attributes?.seedId ?? null;
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
@ -107,7 +127,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const team = teamId ?? '<TEAM_ID>';
|
const team = teamId ?? '<TEAM_ID>';
|
||||||
|
|
||||||
// identities and profile (a real signed run needs them; a dry run shows placeholders)
|
// identities and profile (a real signed run needs them; a dry run shows placeholders)
|
||||||
const mac = process.platform === 'darwin';
|
const mac = platform === 'darwin';
|
||||||
let appIdentity: string | null = null, installerIdentity: string | null = null;
|
let appIdentity: string | null = null, installerIdentity: string | null = null;
|
||||||
if (!unsigned && mac) {
|
if (!unsigned && mac) {
|
||||||
const picked = pickMasIdentities(parseIdentities(run1(['security', 'find-identity', '-v']).out), teamId);
|
const picked = pickMasIdentities(parseIdentities(run1(['security', 'find-identity', '-v']).out), teamId);
|
||||||
|
|
@ -142,21 +162,51 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const overlay = tauriOverlay({ appIdentity, entitlementsFile: entFile, profile, version, build: buildNo, unsigned, minOs: tauri.minOs, category });
|
const overlay = tauriOverlay({ appIdentity, entitlementsFile: entFile, profile, version, build: buildNo, unsigned, minOs: tauri.minOs, category });
|
||||||
const input = { tauri, tauriCmd, target, out, configFile, entitlementsFile: entFile, profile, appIdentity, installerIdentity: installerIdentity ?? '<Mac Installer Distribution identity>', version, build: buildNo, unsigned, pathFree, pkg };
|
const input = { tauri, tauriCmd, target, out, configFile, entitlementsFile: entFile, profile, appIdentity, installerIdentity: installerIdentity ?? '<Mac Installer Distribution identity>', version, build: buildNo, unsigned, pathFree, pkg };
|
||||||
const steps = masSteps(input);
|
const steps = masSteps(input);
|
||||||
const existingEnt = tauri.entitlements && existsSync(tauri.entitlements) ? (parsePlist(readFileSync(tauri.entitlements)) as Record<string, PlistValue>) : undefined;
|
// apple.macos.prebuild first (a project computes its build-time env there), apple.macAppCheck on the built .app before
|
||||||
|
// productbuild (e.g. a project's own check that a value was stamped in). build.prebuild / apple.prebuild belong to the
|
||||||
|
// iOS / Android project (a Capacitor sync, an OTA gate) and are not run for a Tauri Mac build
|
||||||
|
const prebuild = config.apple?.macos?.prebuild?.trim() || null;
|
||||||
|
const mobilePrebuild = prebuildFor(config, 'apple');
|
||||||
|
if (!prebuild && mobilePrebuild && !json) log(TAG, `not run for the Mac build: ${mobilePrebuild} (build.prebuild / apple.prebuild are for the iOS project; set apple.macos.prebuild for the Mac)`);
|
||||||
|
const prebuildSkip = !prebuild ? undefined : a.has('no-prebuild') ? '--no-prebuild' : prebuildsDone().has(prebuild) ? 'already ran in this flow run' : undefined;
|
||||||
|
const appCheck = config.apple?.macAppCheck?.trim() || null;
|
||||||
|
// entitlements: --entitlements, apple.macos.entitlements, the merged Tauri config (the first one that is set)
|
||||||
|
const entFlag = a.get('entitlements'), entCfg = config.apple?.macos?.entitlements;
|
||||||
|
const entSrc = entitlementsSource({ flag: entFlag ? resolve(entFlag) : undefined, config: entCfg ? resolve(entCfg) : undefined, tauri: tauri.entitlements });
|
||||||
|
let existingEnt: Record<string, PlistValue> | undefined;
|
||||||
|
if (entSrc) {
|
||||||
|
if (existsSync(entSrc.file)) existingEnt = parsePlist(readFileSync(entSrc.file)) as Record<string, PlistValue>;
|
||||||
|
else if (entSrc.source !== 'tauri config bundle.macOS.entitlements') throw new Error(`${entSrc.source}: ${entSrc.file} does not exist`);
|
||||||
|
else warn(TAG, `${entSrc.source}: ${relative(root, entSrc.file)} does not exist, using the sandbox defaults only`);
|
||||||
|
}
|
||||||
const ent = masEntitlements({ teamId: team, bundleId, existing: existingEnt });
|
const ent = masEntitlements({ teamId: team, bundleId, existing: existingEnt });
|
||||||
const plan = { platform: 'MAC_OS', tauri: relative(root, tauri.confPath), target, version, build: buildNo, teamId: teamId, unsigned, pathFree, appIdentity, installerIdentity,
|
const entCheck = masEntitlementProblems(ent);
|
||||||
profile: profile ? basenameOf(profile) : null, entitlements: Object.keys(ent), tauriOverlay: overlay, env: Object.fromEntries(Object.entries(env).map(([k, v]) => [k, k === 'RUSTFLAGS' ? v.replaceAll(home, '~') : v])),
|
const allowEnt = a.has('allow-entitlements');
|
||||||
|
const plan = { platform: 'MAC_OS', tauri: relative(root, tauri.confPath), tauriOverlayFile: tauri.overlayPath ? relative(root, tauri.overlayPath) : null, target, version, build: buildNo, teamId: teamId, unsigned, pathFree, appIdentity, installerIdentity,
|
||||||
|
profile: profile ? basenameOf(profile) : null, entitlements: Object.keys(ent), entitlementsSource: entSrc ? { source: entSrc.source, file: relative(root, entSrc.file) } : null,
|
||||||
|
entitlementProblems: entCheck, tauriOverlay: overlay, env: Object.fromEntries(Object.entries(env).map(([k, v]) => [k, k === 'RUSTFLAGS' ? v.replaceAll(home, '~') : v])),
|
||||||
|
prebuild, ...(prebuildSkip ? { prebuildSkip } : {}), appCheck,
|
||||||
steps: [showCmd(steps.tauri, null), showCmd(steps.codesignVerify, null), showCmd(steps.productbuild, null), showCmd(steps.pkgCheck, null)], out: relative(root, out) || '.', pkg: relative(root, pkg) };
|
steps: [showCmd(steps.tauri, null), showCmd(steps.codesignVerify, null), showCmd(steps.productbuild, null), showCmd(steps.pkgCheck, null)], out: relative(root, out) || '.', pkg: relative(root, pkg) };
|
||||||
if (dry) {
|
if (dry) {
|
||||||
if (json) { printJson(plan); return; }
|
if (json) { printJson(plan); return; }
|
||||||
log(TAG, `Tauri ${tauri.productName} (${bundleId}) ${version} (${buildNo}) for ${target}, ${unsigned ? 'UNSIGNED' : 'Mac App Store signing'}${pathFree ? ', path-free' : ''}`);
|
log(TAG, `Tauri ${tauri.productName} (${bundleId}) ${version} (${buildNo}) for ${target}, ${unsigned ? 'UNSIGNED' : 'Mac App Store signing'}${pathFree ? ', path-free' : ''}`);
|
||||||
log(TAG, `app identity: ${appIdentity ?? '(none found)'}; installer identity: ${installerIdentity ?? '(none found)'}; profile: ${plan.profile ?? '(none)'}`);
|
log(TAG, identityLine({ platform, appIdentity, installerIdentity, profile: plan.profile }));
|
||||||
log(TAG, `entitlements: ${plan.entitlements.join(', ')}`);
|
if (tauri.overlayPath) log(TAG, `Tauri overlay ${plan.tauriOverlayFile}${tauri.overlayAuto ? ' (found next to tauri.conf.json)' : ''}: merged over tauri.conf.json, passed to tauri build --config`);
|
||||||
|
log(TAG, `entitlements from ${entSrc?.source ?? 'the sandbox defaults'}${entSrc ? ` (${plan.entitlementsSource!.file})` : ''}: ${plan.entitlements.join(', ')}`);
|
||||||
|
for (const e of entCheck.errors) warn(TAG, `entitlement ${e}${allowEnt ? '' : ' (the real build stops here; --allow-entitlements builds anyway)'}`);
|
||||||
|
for (const w of entCheck.warnings) warn(TAG, `entitlement ${w}`);
|
||||||
if (pathFree) log(TAG, `RUSTFLAGS: ${plan.env.RUSTFLAGS}`);
|
if (pathFree) log(TAG, `RUSTFLAGS: ${plan.env.RUSTFLAGS}`);
|
||||||
|
if (prebuild) log(TAG, prebuildSkip ? `prebuild skipped (${prebuildSkip}): ${prebuild}` : `would run the prebuild: ${prebuild}`);
|
||||||
for (const s of plan.steps) log(TAG, `would run: ${s}`);
|
for (const s of plan.steps) log(TAG, `would run: ${s}`);
|
||||||
|
if (appCheck) log(TAG, `would check the built .app: ${appCheck}`);
|
||||||
done(TAG, 'macOS build planned (dry run)');
|
done(TAG, 'macOS build planned (dry run)');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (tauri.overlayPath) log(TAG, `Tauri overlay ${plan.tauriOverlayFile}${tauri.overlayAuto ? ' (found next to tauri.conf.json)' : ''}: merged over tauri.conf.json, passed to tauri build --config`);
|
||||||
|
log(TAG, `entitlements from ${entSrc?.source ?? 'the sandbox defaults'}${entSrc ? ` (${plan.entitlementsSource!.file})` : ''}: ${plan.entitlements.join(', ')}`);
|
||||||
|
for (const w of entCheck.warnings) warn(TAG, `entitlement ${w}`);
|
||||||
|
for (const e of entCheck.errors) if (allowEnt) warn(TAG, `entitlement ${e} (--allow-entitlements)`);
|
||||||
|
if (entCheck.errors.length && !allowEnt) throw new Error(`the entitlements (from ${entSrc?.source ?? 'the sandbox defaults'}) do not belong in a Mac App Store build:\n${entCheck.errors.map(x => ` ${x}`).join('\n')}\n Point the build at the App Store plist: --entitlements <plist>, apple.macos.entitlements, or a tauri.appstore.conf.json overlay next to tauri.conf.json (--allow-entitlements builds anyway).`);
|
||||||
if (!mac) throw new Error('apple build --platform macos needs macOS (tauri build, codesign, productbuild)');
|
if (!mac) throw new Error('apple build --platform macos needs macOS (tauri build, codesign, productbuild)');
|
||||||
const remote = remoteBuildSession(process.env, run1(['launchctl', 'managername'], 5000).out.trim());
|
const remote = remoteBuildSession(process.env, run1(['launchctl', 'managername'], 5000).out.trim());
|
||||||
if (remote && !unsigned && !a.has('allow-ssh')) throw new Error(`${sshBuildRefusal(remote, { unlockFlag: false })}
|
if (remote && !unsigned && !a.has('allow-ssh')) throw new Error(`${sshBuildRefusal(remote, { unlockFlag: false })}
|
||||||
|
|
@ -164,6 +214,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
mkdirSync(out, { recursive: true });
|
mkdirSync(out, { recursive: true });
|
||||||
writeFileSync(entFile, entitlementsXml(ent));
|
writeFileSync(entFile, entitlementsXml(ent));
|
||||||
writeFileSync(configFile, `${JSON.stringify(overlay, null, 2)}\n`);
|
writeFileSync(configFile, `${JSON.stringify(overlay, null, 2)}\n`);
|
||||||
|
if (prebuild && !prebuildSkip) await runPrebuild(prebuild, root, TAG);
|
||||||
shipPhase('build', `tauri build ${target}, build ${buildNo}`);
|
shipPhase('build', `tauri build ${target}, build ${buildNo}`);
|
||||||
await runLogged(steps.tauri, tauri.cwd, join(out, 'tauri-build.log'), showCmd(steps.tauri, null), env);
|
await runLogged(steps.tauri, tauri.cwd, join(out, 'tauri-build.log'), showCmd(steps.tauri, null), env);
|
||||||
const appDir = findBuiltApp(tauri.dir, root, target, tauri.productName);
|
const appDir = findBuiltApp(tauri.dir, root, target, tauri.productName);
|
||||||
|
|
@ -176,9 +227,16 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const entOut = unsigned ? null : entitlementKeysOf(run1(['codesign', '-d', '--entitlements', ':-', appDir]).out);
|
const entOut = unsigned ? null : entitlementKeysOf(run1(['codesign', '-d', '--entitlements', ':-', appDir]).out);
|
||||||
const leaks = pathFree || a.has('scan-paths') ? scanPathLeaks(appDir, leakNeedles(home, user, root)) : [];
|
const leaks = pathFree || a.has('scan-paths') ? scanPathLeaks(appDir, leakNeedles(home, user, root)) : [];
|
||||||
const checks = appProblems({ info: readAppInfo(appDir), entitlements: entOut, hasProfile: existsSync(join(appDir, 'Contents', 'embedded.provisionprofile')), leaks },
|
const checks = appProblems({ info: readAppInfo(appDir), entitlements: entOut, hasProfile: existsSync(join(appDir, 'Contents', 'embedded.provisionprofile')), leaks },
|
||||||
{ bundleId, version, build: buildNo, signed: !unsigned, pathFree });
|
{ bundleId, version, build: buildNo, signed: !unsigned, pathFree, allowEntitlements: allowEnt });
|
||||||
for (const w of checks.warnings) warn(TAG, w);
|
for (const w of checks.warnings) warn(TAG, w);
|
||||||
if (checks.errors.length) throw new Error(`${basenameOf(appDir)} was built, but the Mac App Store would refuse it:\n${checks.errors.map(x => ` ${x}`).join('\n')}`);
|
if (checks.errors.length) throw new Error(`${basenameOf(appDir)} was built, but the Mac App Store would refuse it:\n${checks.errors.map(x => ` ${x}`).join('\n')}`);
|
||||||
|
if (appCheck) {
|
||||||
|
const cmd = preCheckCommand(appCheck, appDir);
|
||||||
|
log(TAG, `apple.macAppCheck: $ ${cmd}`);
|
||||||
|
const r = await runCheck(cmd, root);
|
||||||
|
if (!r.ok) throw new Error(`apple.macAppCheck failed (exit ${r.code}) on ${basenameOf(appDir)}; nothing packaged:\n${r.tail}`);
|
||||||
|
log(TAG, 'apple.macAppCheck: ok');
|
||||||
|
}
|
||||||
shipPhase('sign', 'productbuild');
|
shipPhase('sign', 'productbuild');
|
||||||
rmSync(exportPath, { recursive: true, force: true });
|
rmSync(exportPath, { recursive: true, force: true });
|
||||||
mkdirSync(exportPath, { recursive: true });
|
mkdirSync(exportPath, { recursive: true });
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,9 @@
|
||||||
// Archive and export an App Store IPA with xcodebuild, no Xcode UI.
|
// Archive and export an App Store IPA with xcodebuild, no Xcode UI.
|
||||||
// storebound apple build --platform macos --tauri <src-tauri> [--path-free] [--unsigned] [--target T] [--profile F] [--version x.y.z] [--build-number N] [--out D]
|
// storebound apple build --platform macos --tauri <src-tauri> [--path-free] [--unsigned] [--target T] [--profile F] [--entitlements <plist>] [--allow-entitlements] [--version x.y.z] [--build-number N] [--out D]
|
||||||
// (Mac App Store build of a Tauri app: cli/apple/build-mas.ts)
|
// (Mac App Store build of a Tauri app: cli/apple/build-mas.ts)
|
||||||
// storebound apple build [--version 1.2.0] [--build-number N] [--scheme S] [--workspace W | --project P]
|
// storebound apple build [--version 1.2.0] [--build-number N] [--scheme S] [--workspace W | --project P]
|
||||||
// [--configuration Release] [--out build/ios] [--no-prebuild] [--allow-stale-web] [--dry] [--json]
|
// [--configuration Release] [--out build/ios] [--no-prebuild] [--allow-stale-web] [--dry] [--json]
|
||||||
|
// [--derived-data <dir>] [--path-free] [--scan-paths]
|
||||||
// [--keychain <path>] [--keychain-unlock] [--allow-ssh] [--allow-app-group-gap]
|
// [--keychain <path>] [--keychain-unlock] [--allow-ssh] [--allow-app-group-gap]
|
||||||
// Over SSH (no GUI session) codesign needs an unlocked keychain: --keychain-unlock unlocks it with the password in
|
// Over SSH (no GUI session) codesign needs an unlocked keychain: --keychain-unlock unlocks it with the password in
|
||||||
// STOREBOUND_KEYCHAIN_PASSWORD (never printed) and sets its key partition list; --keychain <path> signs with a build
|
// STOREBOUND_KEYCHAIN_PASSWORD (never printed) and sets its key partition list; --keychain <path> signs with a build
|
||||||
|
|
@ -16,23 +17,31 @@
|
||||||
// profiles from apple.signing), runs xcodebuild archive and -exportArchive with the API key
|
// profiles from apple.signing), runs xcodebuild archive and -exportArchive with the API key
|
||||||
// (-allowProvisioningUpdates -authenticationKey*), and leaves <out>/export/<version>-<build>/<App>.ipa for `storebound apple upload`. Each build exports into its own
|
// (-allowProvisioningUpdates -authenticationKey*), and leaves <out>/export/<version>-<build>/<App>.ipa for `storebound apple upload`. Each build exports into its own
|
||||||
// folder, cleaned first: xcodebuild refuses to overwrite an earlier App.ipa ("exportArchive Copy failed", pitfall 53).
|
// folder, cleaned first: xcodebuild refuses to overwrite an earlier App.ipa ("exportArchive Copy failed", pitfall 53).
|
||||||
|
// DerivedData: --derived-data <dir> (apple.build.derivedData) is xcodebuild -derivedDataPath; with --out (or apple.build.out)
|
||||||
|
// it defaults to <out>/DerivedData, so a build is hermetic per output folder (without --out Xcode keeps ~/Library/...).
|
||||||
|
// --path-free (apple.build.pathFree) remaps the home folder, checkout, out and DerivedData out of the binary and the dSYM /
|
||||||
|
// Symbols (Swift -debug-prefix-map / -file-prefix-map, clang -ffile-prefix-map), then scans the archive and stops before the
|
||||||
|
// export when a home path is left; --scan-paths only scans and warns. A --out outside the home folder prints a hint.
|
||||||
// Full xcodebuild output goes to <out>/xcodebuild-*.log; the terminal gets the result lines.
|
// Full xcodebuild output goes to <out>/xcodebuild-*.log; the terminal gets the result lines.
|
||||||
// Local only: nothing is sent to App Store Connect except reads (build numbers, team id, profiles).
|
// Local only: nothing is sent to App Store Connect except reads (build numbers, team id, profiles).
|
||||||
import { existsSync, mkdirSync, readdirSync, readFileSync, rmSync, writeFileSync } from 'node:fs';
|
import { existsSync, mkdirSync, readdirSync, readFileSync, rmSync, writeFileSync } from 'node:fs';
|
||||||
import { homedir } from 'node:os';
|
import { homedir, userInfo } from 'node:os';
|
||||||
import { dirname, join, relative } from 'node:path';
|
import { dirname, join, relative } from 'node:path';
|
||||||
import { ascKeyFile } from '../lib/credentials';
|
import { ascKeyFile } from '../lib/credentials';
|
||||||
import type { Ctx } from '../lib/ctx';
|
import type { Ctx } from '../lib/ctx';
|
||||||
import { need } from '../lib/ctx';
|
import { need } from '../lib/ctx';
|
||||||
import { done, log, printJson, warn } from '../lib/log';
|
import { done, log, printJson, warn } from '../lib/log';
|
||||||
|
import { derivedDataFor, archiveScanDirs, leakNeedles, leakProblem, outsideHome, pathFreeSettings, scanForPaths } from '../lib/path-free';
|
||||||
import { pump } from '../lib/runner';
|
import { pump } from '../lib/runner';
|
||||||
import { parseMobileprovision, toXmlPlist } from '../lib/plist';
|
import { parseMobileprovision, toXmlPlist } from '../lib/plist';
|
||||||
import { nextBuildNumber } from '../lib/release';
|
import { appNextBuild } from './next-build';
|
||||||
import { exportOptions, profileDirs } from '../lib/signing';
|
import { exportOptions, profileDirs } from '../lib/signing';
|
||||||
|
import { type FamilyVerdict, familyVerdicts, projectFamilies } from '../lib/device-families';
|
||||||
|
import { liveDeviceFamilies } from './device-families';
|
||||||
import { keychainPassword, keychainSigningArgs, parseKeychainList, showSecurity, sshBuildRefusal, unlockSteps } from '../lib/keychain';
|
import { keychainPassword, keychainSigningArgs, parseKeychainList, showSecurity, sshBuildRefusal, unlockSteps } from '../lib/keychain';
|
||||||
import { appGroupSteps, appGroupVerdicts, type GroupEvidence } from '../lib/targets';
|
import { appGroupSteps, appGroupVerdicts, type GroupEvidence } from '../lib/targets';
|
||||||
import { capacitorProject, webStep } from '../lib/web-assets';
|
import { capacitorProject, webStep } from '../lib/web-assets';
|
||||||
import { archiveArgs, type AscAuth, distributionErrors, exportArgs, foreignRsync, remoteBuildSession, xcodePath, flutterConfigArgs, ipaInfo, ipaVersionProblem, pickXcode, scanXcode, showCmd } from '../lib/xcode';
|
import { archiveArgs, type AscAuth, distributionErrors, exportArgs, foreignRsync, remoteBuildSession, xcodePath, flutterConfigArgs, ipaInfo, ipaVersionProblem, pickXcode, recordLastBuild, scanXcode, showCmd } from '../lib/xcode';
|
||||||
import { bundleTrackingIssues, ipaManifests } from '../lib/privacy-files';
|
import { bundleTrackingIssues, ipaManifests } from '../lib/privacy-files';
|
||||||
import { ascClient } from './asc';
|
import { ascClient } from './asc';
|
||||||
import { parsePlatform } from './platform';
|
import { parsePlatform } from './platform';
|
||||||
|
|
@ -148,6 +157,14 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (sub) target.notes.unshift(`Capacitor project: ${sub} (${sub}/${cap!.config}; the only one found; set apple.build.workspace to use another)`);
|
if (sub) target.notes.unshift(`Capacitor project: ${sub} (${sub}/${cap!.config}; the only one found; set apple.build.workspace to use another)`);
|
||||||
const configuration = a.str('configuration', cfg.configuration ?? 'Release');
|
const configuration = a.str('configuration', cfg.configuration ?? 'Release');
|
||||||
const out = resolve(a.get('out') ?? cfg.out ?? 'build/ios');
|
const out = resolve(a.get('out') ?? cfg.out ?? 'build/ios');
|
||||||
|
const outChosen = !!(a.get('out') ?? cfg.out);
|
||||||
|
const derivedData = derivedDataFor({ flag: a.get('derived-data'), config: cfg.derivedData, out, outChosen, resolve });
|
||||||
|
const pathFree = a.has('path-free') || cfg.pathFree === true;
|
||||||
|
const scanPaths = pathFree || a.has('scan-paths');
|
||||||
|
const home = homedir();
|
||||||
|
const pfSettings = pathFree ? pathFreeSettings({ home, root, out, derivedData }) : [];
|
||||||
|
if (!pathFree && outsideHome(out, home)) warn(TAG, `--out is outside the home folder, but the build embeds the home folder and checkout paths (binary, dSYM, Symbols): add --path-free (or apple.build.pathFree) to remap them and scan the archive`);
|
||||||
|
if (pathFree && (!derivedData || !outsideHome(derivedData, home))) warn(TAG, `--path-free: DerivedData ${derivedData ? 'is' : 'defaults to'} inside the home folder, and dsymutil / Xcode record that path in the dSYM, so the scan below will find it. Build with --out (or --derived-data) outside the home folder, e.g. a shared folder.`);
|
||||||
const version = a.get('version');
|
const version = a.get('version');
|
||||||
if (version && !/^\d+(\.\d+){0,2}$/.test(version)) throw new Error('--version: x.y.z');
|
if (version && !/^\d+(\.\d+){0,2}$/.test(version)) throw new Error('--version: x.y.z');
|
||||||
|
|
||||||
|
|
@ -155,12 +172,14 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
let build = a.get('build-number');
|
let build = a.get('build-number');
|
||||||
let teamId = signing.teamId ?? null;
|
let teamId = signing.teamId ?? null;
|
||||||
if (!build || !teamId) {
|
if (!build || !teamId) {
|
||||||
|
// a line before each slow step: a run without a terminal (launchd job, CI) that stalls shows where
|
||||||
|
log(TAG, `reading App Store Connect (${[!build ? 'next build number' : '', !teamId ? 'team id' : ''].filter(Boolean).join(', ')})`);
|
||||||
try {
|
try {
|
||||||
const c = await ascClient(root, bundleId, config.apple?.appId);
|
const c = await ascClient(root, bundleId, config.apple?.appId);
|
||||||
if (!build) {
|
if (!build) {
|
||||||
const builds = await c.all(`/v1/builds?filter[app]=${await c.app()}&limit=200&fields[builds]=version`);
|
const found = await appNextBuild(c);
|
||||||
build = nextBuildNumber(builds.map(b => String(b.attributes.version)));
|
build = found.next;
|
||||||
log(TAG, `${builds.length} builds on App Store Connect: next build number ${build}`);
|
log(TAG, `${found.builds} builds on App Store Connect: next build number ${build}`);
|
||||||
}
|
}
|
||||||
if (!teamId) teamId = (await findBundleId(c, bundleId))?.attributes?.seedId ?? null;
|
if (!teamId) teamId = (await findBundleId(c, bundleId))?.attributes?.seedId ?? null;
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
@ -171,6 +190,19 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (build && !/^\d+(\.\d+){0,2}$/.test(build)) throw new Error('--build-number: digits, e.g. 42 or 1.0.42');
|
if (build && !/^\d+(\.\d+){0,2}$/.test(build)) throw new Error('--build-number: digits, e.g. 42 or 1.0.42');
|
||||||
const buildNo = build ?? '<next build number>';
|
const buildNo = build ?? '<next build number>';
|
||||||
|
|
||||||
|
// device families: an upload that drops one the live version supports (iPad) is refused only AFTER the archive (ITMS-90101)
|
||||||
|
// so compare first: stop before building with the exact fix (--allow-device-gap builds anyway)
|
||||||
|
let deviceFamilies: FamilyVerdict[] = [];
|
||||||
|
log(TAG, 'reading the device families of the live version');
|
||||||
|
try {
|
||||||
|
const c = await ascClient(root, bundleId, config.apple?.appId);
|
||||||
|
deviceFamilies = familyVerdicts({ live: await liveDeviceFamilies(c, await c.app()), project: projectFamilies(root, bundleId, target.project), ipad: config.apple?.ipad });
|
||||||
|
} catch (e) { warn(TAG, `device families of the live version not compared (${(e as Error).message.split('\n')[0]?.slice(0, 120)})`); }
|
||||||
|
const familyBlockers = deviceFamilies.filter(d => d.level === 'blocker');
|
||||||
|
for (const d of deviceFamilies) if (d.level === 'warn' || (d.level === 'blocker' && (dry || a.has('allow-device-gap')))) warn(TAG, `${d.msg}${d.fix ? ` -> ${d.fix}` : ''}`);
|
||||||
|
if (familyBlockers.length && !dry && !a.has('allow-device-gap'))
|
||||||
|
throw new Error(`${familyFixLines(familyBlockers, config.apple?.ipad).join('\n')}\nstopped before the archive: ${familyBlockers.map(d => `${d.msg}. Fix: ${d.fix}`).join('\n')}\n(--allow-device-gap builds anyway)`);
|
||||||
|
|
||||||
const scan = discoverTargets(root, config);
|
const scan = discoverTargets(root, config);
|
||||||
const ids = [bundleId, ...scan.extensions.map(t => t.bundleId)];
|
const ids = [bundleId, ...scan.extensions.map(t => t.bundleId)];
|
||||||
const profiles: Record<string, string> = {};
|
const profiles: Record<string, string> = {};
|
||||||
|
|
@ -212,12 +244,12 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const auth = style === 'automatic' ? authPreview : null;
|
const auth = style === 'automatic' ? authPreview : null;
|
||||||
const steps = [
|
const steps = [
|
||||||
...(target.framework === 'flutter' ? [showCmd(flutterConfigArgs(buildNo, version), null)] : []),
|
...(target.framework === 'flutter' ? [showCmd(flutterConfigArgs(buildNo, version), null)] : []),
|
||||||
showCmd(archiveArgs({ target, root, configuration, archivePath, version, build: buildNo, teamId: teamId ?? undefined, auth, settings: keychain ? keychainSigningArgs(keychain) : undefined }), auth),
|
showCmd(archiveArgs({ target, root, configuration, archivePath, version, build: buildNo, teamId: teamId ?? undefined, auth, settings: [...(keychain ? keychainSigningArgs(keychain) : []), ...pfSettings], derivedData }), auth),
|
||||||
showCmd(exportArgs(archivePath, join(out, 'ExportOptions.plist'), exportPath, auth), auth),
|
showCmd(exportArgs(archivePath, join(out, 'ExportOptions.plist'), exportPath, auth), auth),
|
||||||
];
|
];
|
||||||
const unlockPreview = unlock ? unlockSteps(keychain ?? '<login keychain>', []).map(showSecurity) : [];
|
const unlockPreview = unlock ? unlockSteps(keychain ?? '<login keychain>', []).map(showSecurity) : [];
|
||||||
const plan = { framework: target.framework, workspace: target.workspace ?? null, project: target.project ?? null, scheme: target.scheme, configuration,
|
const plan = { framework: target.framework, workspace: target.workspace ?? null, project: target.project ?? null, scheme: target.scheme, configuration,
|
||||||
version: version ?? '(project value)', build: buildNo, teamId, signingStyle: style, exportOptions: opts, out: relative(root, out) || '.', steps: [...unlockPreview, ...steps], notes: target.notes };
|
version: version ?? '(project value)', build: buildNo, deviceFamilies, derivedData: derivedData ?? '(Xcode default)', pathFree, teamId, signingStyle: style, exportOptions: opts, out: relative(root, out) || '.', steps: [...unlockPreview, ...steps], notes: target.notes };
|
||||||
const webOpts = { config, root, cap, store: 'apple' as const, tag: TAG, noPrebuild: a.has('no-prebuild'), allowStale: a.has('allow-stale-web') };
|
const webOpts = { config, root, cap, store: 'apple' as const, tag: TAG, noPrebuild: a.has('no-prebuild'), allowStale: a.has('allow-stale-web') };
|
||||||
if (dry) {
|
if (dry) {
|
||||||
const web = await webStep({ ...webOpts, dry: true, quiet: json });
|
const web = await webStep({ ...webOpts, dry: true, quiet: json });
|
||||||
|
|
@ -239,19 +271,28 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
else addToSearchList(keychain!);
|
else addToSearchList(keychain!);
|
||||||
}
|
}
|
||||||
shipPhase('prebuild', 'web build / prebuild');
|
shipPhase('prebuild', 'web build / prebuild');
|
||||||
|
log(TAG, 'web build / prebuild step');
|
||||||
const web = await webStep({ ...webOpts, dry: false });
|
const web = await webStep({ ...webOpts, dry: false });
|
||||||
for (const n of target.notes) log(TAG, n);
|
for (const n of target.notes) log(TAG, n);
|
||||||
const rsync = foreignRsync(process.env.PATH);
|
const rsync = foreignRsync(process.env.PATH);
|
||||||
if (rsync) log(TAG, `note: ${rsync} is first on your PATH; xcodebuild runs with /usr/bin first (a non-Apple rsync breaks Xcode's IPA export)`);
|
if (rsync) log(TAG, `note: ${rsync} is first on your PATH; xcodebuild runs with /usr/bin first (a non-Apple rsync breaks Xcode's IPA export)`);
|
||||||
mkdirSync(out, { recursive: true });
|
mkdirSync(out, { recursive: true });
|
||||||
writeFileSync(join(out, 'ExportOptions.plist'), plist);
|
writeFileSync(join(out, 'ExportOptions.plist'), plist);
|
||||||
|
let leaks = 0;
|
||||||
const key = style === 'automatic' ? ascKeyFile(root) : null;
|
const key = style === 'automatic' ? ascKeyFile(root) : null;
|
||||||
const realAuth: AscAuth | null = key ? { keyPath: key.keyPath, keyId: key.keyId, issuerId: key.issuerId } : null;
|
const realAuth: AscAuth | null = key ? { keyPath: key.keyPath, keyId: key.keyId, issuerId: key.issuerId } : null;
|
||||||
try {
|
try {
|
||||||
if (target.framework === 'flutter') await runLogged(flutterConfigArgs(build!, version), root, join(out, 'flutter-config.log'), showCmd(flutterConfigArgs(build!, version), null));
|
if (target.framework === 'flutter') await runLogged(flutterConfigArgs(build!, version), root, join(out, 'flutter-config.log'), showCmd(flutterConfigArgs(build!, version), null));
|
||||||
shipPhase('build', `xcodebuild archive, build ${build}`);
|
shipPhase('build', `xcodebuild archive, build ${build}`);
|
||||||
const arch = archiveArgs({ target, root, configuration, archivePath, version, build: build!, teamId: teamId ?? undefined, auth: realAuth, settings: keychain ? keychainSigningArgs(keychain) : undefined });
|
const arch = archiveArgs({ target, root, configuration, archivePath, version, build: build!, teamId: teamId ?? undefined, auth: realAuth, settings: [...(keychain ? keychainSigningArgs(keychain) : []), ...pfSettings], derivedData });
|
||||||
await runLogged(arch, root, join(out, 'xcodebuild-archive.log'), showCmd(arch, realAuth));
|
await runLogged(arch, root, join(out, 'xcodebuild-archive.log'), showCmd(arch, realAuth));
|
||||||
|
if (scanPaths) {
|
||||||
|
shipPhase('verify', 'scanning the archive for local paths');
|
||||||
|
const found = scanForPaths(archiveScanDirs(archivePath), leakNeedles({ home, user: userInfo().username, root }));
|
||||||
|
leaks = found.total;
|
||||||
|
const why = leakProblem(found, relative(root, archivePath));
|
||||||
|
if (why) { if (pathFree) throw new Error(why); warn(TAG, why.split(String.fromCharCode(10))[0]!); } else log(TAG, 'no local path in the archive (app, dSYMs, Symbols)');
|
||||||
|
}
|
||||||
shipPhase('sign', 'xcodebuild -exportArchive (signing)');
|
shipPhase('sign', 'xcodebuild -exportArchive (signing)');
|
||||||
await exportIpa({ root, out, archivePath, exportPath, auth: realAuth });
|
await exportIpa({ root, out, archivePath, exportPath, auth: realAuth });
|
||||||
} finally { key?.cleanup(); }
|
} finally { key?.cleanup(); }
|
||||||
|
|
@ -265,9 +306,20 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
// ITMS-91064 (Invalid Binary after the upload): NSPrivacyTracking / NSPrivacyTrackingDomains of every manifest in the IPA
|
// ITMS-91064 (Invalid Binary after the upload): NSPrivacyTracking / NSPrivacyTrackingDomains of every manifest in the IPA
|
||||||
const privacy = bundleTrackingIssues(ipaManifests(join(exportPath, ipa)));
|
const privacy = bundleTrackingIssues(ipaManifests(join(exportPath, ipa)));
|
||||||
if (privacy.length) throw new Error(`${relative(root, join(exportPath, ipa))} was built, but Apple would refuse it at upload:\n${privacy.map(x => ` ${x}`).join('\n')}\nFix the manifest and build again.`);
|
if (privacy.length) throw new Error(`${relative(root, join(exportPath, ipa))} was built, but Apple would refuse it at upload:\n${privacy.map(x => ` ${x}`).join('\n')}\nFix the manifest and build again.`);
|
||||||
const result = { ipa: join(exportPath, ipa), bundleId: info.bundleId, version: info.version, build: info.build, web: web.bundle };
|
const result = { ipa: join(exportPath, ipa), bundleId: info.bundleId, version: info.version, build: info.build, web: web.bundle, derivedData: derivedData ?? null, pathFree, ...(scanPaths ? { leaks } : {}) };
|
||||||
writeFileSync(join(out, 'latest.json'), `${JSON.stringify(result, null, 2)}
|
writeFileSync(join(out, 'latest.json'), `${JSON.stringify(result, null, 2)}
|
||||||
`);
|
`);
|
||||||
|
recordLastBuild(root, { ipa: result.ipa, out, version: info.version, build: info.build });
|
||||||
if (json) printJson(result);
|
if (json) printJson(result);
|
||||||
done(TAG, `${relative(root, result.ipa)}: ${info.bundleId} ${info.version} (${info.build}). Next: storebound apple upload ${relative(root, result.ipa)} --dry`);
|
done(TAG, `${relative(root, result.ipa)}: ${info.bundleId} ${info.version} (${info.build}). Next: storebound apple upload ${relative(root, result.ipa)} --dry`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Short "fix:" lines put first in the device-family stop, so a truncated or piped log still shows the fix. Pure. */
|
||||||
|
export function familyFixLines(blockers: { msg: string }[], ipad: boolean | undefined): string[] {
|
||||||
|
const out = new Set<string>();
|
||||||
|
for (const b of blockers) {
|
||||||
|
if (/TARGETED_DEVICE_FAMILY = 1\b|no iPad\)/.test(b.msg)) out.add('fix: TARGETED_DEVICE_FAMILY "1,2" in the Xcode project (Supported Destinations: add iPad)');
|
||||||
|
if (ipad !== true && /iPad/.test(b.msg)) out.add('fix: apple.ipad: true in storebound.config.ts');
|
||||||
|
}
|
||||||
|
return [...out];
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -29,61 +29,17 @@ import { need } from '../lib/ctx';
|
||||||
import { consoleLink } from '../lib/console-links';
|
import { consoleLink } from '../lib/console-links';
|
||||||
import { done, log, warn } from '../lib/log';
|
import { done, log, warn } from '../lib/log';
|
||||||
import { elapsed } from '../lib/progress';
|
import { elapsed } from '../lib/progress';
|
||||||
import * as rt from '../lib/rt';
|
|
||||||
import { ffprobe } from '../shots/report';
|
import { ffprobe } from '../shots/report';
|
||||||
import { imageInfo } from '../shots/spec';
|
import { imageInfo } from '../shots/spec';
|
||||||
import { checkCreativeImage, checkCreativeVideo, type CreativeFile, creativeFiles, PLACEMENT_TYPE, type Placement } from '../shots/creative';
|
import { checkCreativeImage, checkCreativeVideo, type CreativeFile, creativeFiles, PLACEMENT_TYPE, type Placement } from '../shots/creative';
|
||||||
import { type Asc, ascClient, md5, type J } from './asc';
|
import { type Asc, ascClient, md5, type J } from './asc';
|
||||||
|
import { type AssetClass, ASSET_STATES, classify, MAX_FAILED, pickAsset, processingTiming, reason, REF, selectable, sumOf } from './asset-library';
|
||||||
|
export { type AssetClass, ASSET_STATES, classify, MAX_FAILED, pickAsset, processingTiming, REF, selectable };
|
||||||
import { partHeaders } from './screenshot-health';
|
import { partHeaders } from './screenshot-health';
|
||||||
import { AmbiguousWriteError } from '../lib/upsert';
|
import { AmbiguousWriteError } from '../lib/upsert';
|
||||||
import { addItem, ensureDraft, OtherSubmissionError } from './submission';
|
import { addItem, ensureDraft, OtherSubmissionError } from './submission';
|
||||||
|
|
||||||
const TAG = 'apple';
|
const TAG = 'apple';
|
||||||
export const REF = (sum: string): string => `storebound ${sum}`;
|
|
||||||
const sumOf = (a: J): string | undefined => /^storebound ([0-9a-f]{32})$/.exec(String(a?.attributes?.referenceName ?? ''))?.[1];
|
|
||||||
|
|
||||||
/** Asset states (AppAssetLibraryAssetState, API 4.5.1) by what storebound may do with them. */
|
|
||||||
export const ASSET_STATES = {
|
|
||||||
/** still uploading / processing: wait (bounded), then select */
|
|
||||||
processing: ['AWAITING_UPLOAD', 'UPLOAD_COMPLETE'],
|
|
||||||
/** processed and usable in a slot; not reviewed yet: goes into a review submission */
|
|
||||||
unreviewed: ['COMPLETE', 'PREPARE_FOR_SUBMISSION'],
|
|
||||||
/** in a submission or reviewed: usable in a slot, nothing to add */
|
|
||||||
reviewing: ['READY_FOR_REVIEW', 'WAITING_FOR_REVIEW', 'IN_REVIEW', 'ACCEPTED', 'APPROVED'],
|
|
||||||
} as const;
|
|
||||||
export type AssetClass = 'processing' | 'unreviewed' | 'reviewing' | 'failed' | 'rejected' | 'archived' | 'unknown';
|
|
||||||
|
|
||||||
/** What a library asset's state means for storebound. Pure. */
|
|
||||||
export function classify(state: string | undefined): AssetClass {
|
|
||||||
const s = String(state ?? '');
|
|
||||||
for (const [k, v] of Object.entries(ASSET_STATES)) if ((v as readonly string[]).includes(s)) return k as AssetClass;
|
|
||||||
if (s === 'FAILED') return 'failed';
|
|
||||||
if (s === 'REJECTED') return 'rejected';
|
|
||||||
if (s === 'ARCHIVED') return 'archived';
|
|
||||||
return s ? 'unknown' : 'processing';
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Selectable for a slot: processed and not failed / rejected / archived (Prepare for Submission is enough). */
|
|
||||||
export const selectable = (c: AssetClass): boolean => c === 'unreviewed' || c === 'reviewing';
|
|
||||||
|
|
||||||
/** Stop re-uploading a file whose earlier uploads failed processing this many times. */
|
|
||||||
export const MAX_FAILED = 2;
|
|
||||||
|
|
||||||
/** The library asset to use for one MD5: a live one first (newest state wins: reviewing > unreviewed > processing),
|
|
||||||
* else an archived one (unarchive it), else none; plus why not to upload (a rejected file, repeated failures). Pure. */
|
|
||||||
export function pickAsset(assets: J[], sum: string): { asset?: J; unarchive?: boolean; refuse?: string } {
|
|
||||||
const mine = assets.filter(x => sumOf(x) === sum);
|
|
||||||
const rank: Record<AssetClass, number> = { reviewing: 0, unreviewed: 1, processing: 2, unknown: 3, archived: 4, rejected: 5, failed: 6 };
|
|
||||||
const by = (c: AssetClass) => mine.filter(x => classify(x.attributes?.state) === c);
|
|
||||||
const live = mine.filter(x => rank[classify(x.attributes?.state)] <= 3).sort((a, b) => rank[classify(a.attributes?.state)] - rank[classify(b.attributes?.state)]);
|
|
||||||
if (live[0]) return { asset: live[0] };
|
|
||||||
if (by('archived')[0]) return { asset: by('archived')[0], unarchive: true };
|
|
||||||
const rej = by('rejected')[0];
|
|
||||||
if (rej) return { refuse: `rejected by App Review${reason(rej)}: uploading the same file again changes nothing; change the file` };
|
|
||||||
if (by('failed').length >= MAX_FAILED) return { refuse: `${by('failed').length} earlier uploads of this file failed processing${reason(by('failed')[0]!)}: check the file (format, size) before trying again` };
|
|
||||||
return {};
|
|
||||||
}
|
|
||||||
|
|
||||||
/** "uploaded 2026-10-19, waiting for Apple's approval (IN_REVIEW); run `storebound apple creative-assets` again later".
|
/** "uploaded 2026-10-19, waiting for Apple's approval (IN_REVIEW); run `storebound apple creative-assets` again later".
|
||||||
* The version page's header / search slots offer only approved assets ("Browse approved assets"), so an asset that
|
* The version page's header / search slots offer only approved assets ("Browse approved assets"), so an asset that
|
||||||
* is not APPROVED waits; a later run places it. Pure. */
|
* is not APPROVED waits; a later run places it. Pure. */
|
||||||
|
|
@ -107,14 +63,6 @@ export async function creativeWaiting(c: Asc, appId: string, local: Map<string,
|
||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
const reason = (a: J): string => {
|
|
||||||
const d = ((a.attributes?.stateDetails ?? []) as J[]).map(x => x?.code ?? x?.message ?? x?.description).filter(Boolean);
|
|
||||||
return d.length ? ` (${d.join(', ')})` : '';
|
|
||||||
};
|
|
||||||
|
|
||||||
/** Bounded wait for processing (every wait has a timeout and a heartbeat); tests set waitMs 0 / timeoutMs 0. */
|
|
||||||
export const processingTiming = { pollMs: 3000, timeoutMs: 120_000, heartbeatMs: 20_000, sleep: (ms: number): Promise<void> => (ms > 0 ? rt.sleep(ms) : Promise.resolve()) };
|
|
||||||
|
|
||||||
export interface Row { locale: string; placement: Placement; file: string; action: 'keep' | 'upload' | 'reuse' | 'wait' | 'select' | 'replace' | 'approve' | 'refuse'; state?: string; asset?: J }
|
export interface Row { locale: string; placement: Placement; file: string; action: 'keep' | 'upload' | 'reuse' | 'wait' | 'select' | 'replace' | 'approve' | 'refuse'; state?: string; asset?: J }
|
||||||
|
|
||||||
/** Local files per App Store locale, checked; throws on any error before a network call. */
|
/** Local files per App Store locale, checked; throws on any error before a network call. */
|
||||||
|
|
|
||||||
41
cli/apple/device-families.ts
Normal file
41
cli/apple/device-families.ts
Normal file
|
|
@ -0,0 +1,41 @@
|
||||||
|
// The device families of the app's last live iOS version, read from App Store Connect (cli/lib/device-families.ts compares
|
||||||
|
// them with the project and the config). Signals, merged because none is documented as THE answer:
|
||||||
|
// - the live version's build bundle: buildBundles.deviceProtocols and the device models of buildBundleFileSizes
|
||||||
|
// - the screenshot sets of the live version: an APP_IPAD_* display type means the version was submitted for iPad
|
||||||
|
// Live version = READY_FOR_SALE / READY_FOR_DISTRIBUTION; else the newest one that was on sale (REPLACED_WITH_NEW_VERSION).
|
||||||
|
import { compareVersions } from '../lib/listing-plan';
|
||||||
|
import { liveFamilies, type LiveFamilies } from '../lib/device-families';
|
||||||
|
import type { Asc, J } from './asc';
|
||||||
|
import { type AscPlatform, versionsPath } from './platform';
|
||||||
|
|
||||||
|
const ON_SALE = ['READY_FOR_SALE', 'READY_FOR_DISTRIBUTION'];
|
||||||
|
const WAS_ON_SALE = [...ON_SALE, 'REPLACED_WITH_NEW_VERSION'];
|
||||||
|
|
||||||
|
/** The live (or last live) version among the rows of GET appStoreVersions, newest first. Pure. */
|
||||||
|
export function lastLiveVersion(rows: J[]): J | null {
|
||||||
|
const state = (v: J): string => v.attributes.appVersionState ?? v.attributes.appStoreState;
|
||||||
|
const pick = (states: string[]): J | null => rows.filter(v => states.includes(state(v)))
|
||||||
|
.sort((a, b) => compareVersions(String(b.attributes.versionString), String(a.attributes.versionString)))[0] ?? null;
|
||||||
|
return pick(ON_SALE) ?? pick(WAS_ON_SALE);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Reads the families of the last live version of the platform (iOS unless named); null when there is none or no signal names a family. */
|
||||||
|
export async function liveDeviceFamilies(c: Asc, appId: string, platform: AscPlatform = 'IOS'): Promise<LiveFamilies | null> {
|
||||||
|
const v = lastLiveVersion(await c.all(versionsPath(appId, platform, 20)));
|
||||||
|
if (!v) return null;
|
||||||
|
const signals: { name: string; values: string[] }[] = [];
|
||||||
|
const b = (await c.maybe(`/v1/appStoreVersions/${v.id}/build`))?.data;
|
||||||
|
if (b) {
|
||||||
|
const full = await c.maybe(`/v1/builds/${b.id}?include=buildBundles`);
|
||||||
|
const bundles = (full?.included ?? []).filter((x: J) => x.type === 'buildBundles' && (x.attributes?.bundleType ?? 'APP') === 'APP');
|
||||||
|
signals.push({ name: `build ${b.attributes?.version ?? b.id} deviceProtocols`, values: bundles.flatMap((x: J) => (x.attributes?.deviceProtocols ?? []) as string[]) });
|
||||||
|
const models: string[] = [];
|
||||||
|
for (const x of bundles) for (const f of await c.all(`/v1/buildBundles/${x.id}/buildBundleFileSizes?limit=200`)) models.push(String(f.attributes?.deviceModel ?? ''));
|
||||||
|
signals.push({ name: `build ${b.attributes?.version ?? b.id} device models`, values: models });
|
||||||
|
}
|
||||||
|
const types: string[] = [];
|
||||||
|
for (const l of (await c.all(`/v1/appStoreVersions/${v.id}/appStoreVersionLocalizations?limit=50`)).slice(0, 5))
|
||||||
|
for (const s of await c.all(`/v1/appStoreVersionLocalizations/${l.id}/appScreenshotSets?limit=50`)) types.push(String(s.attributes?.screenshotDisplayType ?? ''));
|
||||||
|
signals.push({ name: 'screenshot sets', values: types });
|
||||||
|
return liveFamilies(String(v.attributes.versionString), String(v.attributes.appVersionState ?? v.attributes.appStoreState), signals);
|
||||||
|
}
|
||||||
131
cli/apple/duo-library.ts
Normal file
131
cli/apple/duo-library.ts
Normal file
|
|
@ -0,0 +1,131 @@
|
||||||
|
// iPhone Duo screenshots through the App Asset Library (App Store Connect API 4.5.1, pitfall 130). ScreenshotDisplayType
|
||||||
|
// has no Duo value and never will: Apple added the display class IPHONE_DUO only to AppAssetLibraryDisplayClass and
|
||||||
|
// deprecated appScreenshotSets / appScreenshots in the same release. Flow:
|
||||||
|
// 1. GET /v1/appAssetLibraryRefData?filter[placementTypes]=APP_SCREENSHOT -> the iOS placementProfileGroup whose
|
||||||
|
// displayClassId is IPHONE_DUO (its id is the placementGroup of every Duo screenshot);
|
||||||
|
// 2. each file is uploaded once to the app's library (POST appAssetLibraryImages, category
|
||||||
|
// APP_SCREENSHOTS_AND_PREVIEWS, referenceName "storebound <md5>", the same MD5 reuse as creative assets);
|
||||||
|
// 3. POST appAssetLibraryPlacements (placementType APP_SCREENSHOT, placementGroup, the version localization).
|
||||||
|
// Screenshots are reviewed with the version, so a processed asset is placed at once (no approval wait).
|
||||||
|
// Upsert: a group whose placements already show the local files in order is left alone; otherwise its placements are
|
||||||
|
// removed and the files placed in order (outer display files first, then inner). Never truncated: more files than
|
||||||
|
// the limit Apple publishes for the group (refData groupLimits) changes nothing and says so. Read back at the end.
|
||||||
|
import { readFileSync } from 'node:fs';
|
||||||
|
import { basename } from 'node:path';
|
||||||
|
import { log, warn } from '../lib/log';
|
||||||
|
import { elapsed } from '../lib/progress';
|
||||||
|
import { classify, pickAsset, processingTiming, REF, selectable } from './asset-library';
|
||||||
|
import { type Asc, md5, type J } from './asc';
|
||||||
|
import { partHeaders } from './screenshot-health';
|
||||||
|
|
||||||
|
const TAG = 'apple';
|
||||||
|
export const DUO_CATEGORY = 'APP_SCREENSHOTS_AND_PREVIEWS';
|
||||||
|
const sumOf = (a: J | undefined): string | undefined => /^storebound ([0-9a-f]{32})$/.exec(String(a?.attributes?.referenceName ?? ''))?.[1];
|
||||||
|
|
||||||
|
/** iPhone placement profile group ids (platform IOS or IPHONE_APP_STORE, as the live API answers) of the IPHONE_DUO display class in an appAssetLibraryRefData response. Pure. */
|
||||||
|
export function duoGroups(refData: J[]): string[] {
|
||||||
|
const ids = new Set<string>();
|
||||||
|
for (const r of refData) for (const g of (r?.attributes?.placementProfileGroups ?? []) as J[])
|
||||||
|
if (g?.displayClassId === 'IPHONE_DUO' && (!g.platform || /IOS|IPHONE/.test(String(g.platform))) && g.placementProfileGroupId) ids.add(String(g.placementProfileGroupId));
|
||||||
|
return [...ids];
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Apple's screenshot limit for a placement group on a version page, or null when refData publishes none. Pure. */
|
||||||
|
export function duoLimit(refData: J[], group: string): number | null {
|
||||||
|
for (const r of refData) for (const f of (r?.attributes?.features ?? []) as J[]) {
|
||||||
|
if (f?.featureId !== 'APP_STORE_VERSIONS') continue;
|
||||||
|
for (const p of (f.placementPolicies ?? []) as J[]) {
|
||||||
|
if (p?.placementType !== 'APP_SCREENSHOT') continue;
|
||||||
|
for (const l of (p.groupLimits ?? []) as J[]) if ((l?.groupIds ?? []).includes(group) && typeof l.maxCount === 'number') return l.maxCount;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Whether a group's current placements (asset MD5s in order) already show `want`. Pure. */
|
||||||
|
export const duoUpToDate = (shown: (string | undefined)[], want: string[]): boolean => shown.length === want.length && shown.every((s, i) => s === want[i]);
|
||||||
|
|
||||||
|
export interface DuoResult { locale: string; action: 'keep' | 'place' | 'wait' | 'refuse' | 'plan'; files: number }
|
||||||
|
|
||||||
|
/** Resolves the Duo placement group once per run; throws with the guardrail text when the API lists none. */
|
||||||
|
export async function duoGroup(c: Asc): Promise<{ id: string; limit: number | null }> {
|
||||||
|
const ref = await c.all('/v1/appAssetLibraryRefData?filter[placementTypes]=APP_SCREENSHOT');
|
||||||
|
const g = duoGroups(ref);
|
||||||
|
if (!g.length) throw new Error('appAssetLibraryRefData lists no iOS IPHONE_DUO placement group for APP_SCREENSHOT: report it (pitfall 130); the console version page > App Previews and Screenshots > iPhone Duo takes them meanwhile');
|
||||||
|
if (g.length > 1) log(TAG, `iPhone Duo: ${g.length} placement groups (${g.join(', ')}), using ${g[0]}`);
|
||||||
|
const limit = duoLimit(ref, g[0]!);
|
||||||
|
log(TAG, `iPhone Duo: placement group ${g[0]}, limit ${limit ?? 'not published'}`);
|
||||||
|
return { id: g[0]!, limit };
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Makes the iPhone Duo screenshots of one version localization show `files` in order. */
|
||||||
|
export async function syncDuo(c: Asc, o: { appId: string; group: string; limit: number | null; loc: J; files: string[]; dry: boolean }): Promise<DuoResult> {
|
||||||
|
const locale: string = o.loc.attributes.locale;
|
||||||
|
const tag = `${locale} IPHONE_DUO`;
|
||||||
|
const files = o.files;
|
||||||
|
if (o.limit !== null && files.length > o.limit) {
|
||||||
|
warn(TAG, `${tag}: ${files.length} files (outer + inner) but Apple allows ${o.limit} in this group: nothing changed, none dropped. Keep at most ${o.limit} across iphone-duo-outer/ and iphone-duo-inner/`);
|
||||||
|
process.exitCode = 1;
|
||||||
|
return { locale, action: 'refuse', files: files.length };
|
||||||
|
}
|
||||||
|
const lib = (await c.asc('GET', `/v1/apps/${o.appId}/assetLibrary`)).data as J;
|
||||||
|
const library = () => c.all(`/v1/appAssetLibraries/${lib.id}/images?filter[category]=${DUO_CATEGORY}&limit=200`);
|
||||||
|
let assets = await library();
|
||||||
|
const want = files.map(f => md5(readFileSync(f)));
|
||||||
|
const placedAll = await c.all(`/v1/appStoreVersionLocalizations/${o.loc.id}/placements?filter[placementType]=APP_SCREENSHOT&include=image`);
|
||||||
|
const placed = placedAll.filter(p => p.attributes?.placementGroup === o.group);
|
||||||
|
const shown = placed.map(p => sumOf(assets.find(a => a.id === p.relationships?.image?.data?.id)));
|
||||||
|
if (duoUpToDate(shown, want)) { log(TAG, `${tag}: ${files.length} up to date`); return { locale, action: 'keep', files: files.length }; }
|
||||||
|
if (o.dry) {
|
||||||
|
const up = want.filter(s => !pickAsset(assets, s).asset).length;
|
||||||
|
log(TAG, `${tag}: would ${placed.length ? `replace ${placed.length} placed` : 'place'} ${files.length} screenshot(s) through the Asset Library (${up} to upload)`);
|
||||||
|
return { locale, action: 'plan', files: files.length };
|
||||||
|
}
|
||||||
|
const chosen: J[] = [];
|
||||||
|
for (let i = 0; i < files.length; i++) {
|
||||||
|
const f = files[i]!, sum = want[i]!;
|
||||||
|
const pick = pickAsset(assets, sum);
|
||||||
|
if (pick.refuse) { warn(TAG, `${tag} ${basename(f)}: ${pick.refuse}`); return { locale, action: 'refuse', files: files.length }; }
|
||||||
|
let a = pick.asset;
|
||||||
|
if (!a) { log(TAG, `${tag}: uploading ${basename(f)} to the Asset Library`); a = await uploadImage(c, lib.id, f, sum); assets = await library(); a = pickAsset(assets, sum).asset ?? a; }
|
||||||
|
else if (pick.unarchive) a = (await c.asc('PATCH', `/v1/${a.type}/${a.id}`, { data: { type: a.type, id: a.id, attributes: { archived: false } } })).data as J;
|
||||||
|
a = await processed(c, a, `${tag} ${basename(f)}`);
|
||||||
|
const cls = classify(a.attributes?.state);
|
||||||
|
if (cls === 'processing') return { locale, action: 'wait', files: files.length };
|
||||||
|
if (!selectable(cls)) { warn(TAG, `${tag} ${basename(f)}: ${a.attributes?.state}; nothing changed`); return { locale, action: 'refuse', files: files.length }; }
|
||||||
|
chosen.push(a);
|
||||||
|
}
|
||||||
|
// every file is ready before the old placements go, so a failed upload leaves the page as it was
|
||||||
|
for (const p of placed) await c.asc('DELETE', `/v1/appAssetLibraryPlacements/${p.id}`);
|
||||||
|
for (const a of chosen) await c.asc('POST', '/v1/appAssetLibraryPlacements', { data: { type: 'appAssetLibraryPlacements', attributes: { placementType: 'APP_SCREENSHOT', placementGroup: o.group },
|
||||||
|
relationships: { image: { data: { type: 'appAssetLibraryImages', id: a.id } }, appStoreVersionLocalization: { data: { type: 'appStoreVersionLocalizations', id: o.loc.id } } } } });
|
||||||
|
const now = (await c.all(`/v1/appStoreVersionLocalizations/${o.loc.id}/placements?filter[placementType]=APP_SCREENSHOT&include=image`)).filter(p => p.attributes?.placementGroup === o.group);
|
||||||
|
const ids = now.map(p => p.relationships?.image?.data?.id);
|
||||||
|
if (ids.length !== chosen.length || chosen.some(a => !ids.includes(a.id))) { warn(TAG, `${tag}: read back ${ids.length} placements, wanted ${chosen.length}`); process.exitCode = 1; }
|
||||||
|
else log(TAG, `${tag}: placed ${chosen.length} (removed ${placed.length})`);
|
||||||
|
return { locale, action: 'place', files: chosen.length };
|
||||||
|
}
|
||||||
|
|
||||||
|
async function uploadImage(c: Asc, libId: string, file: string, sum: string): Promise<J> {
|
||||||
|
const buf = readFileSync(file);
|
||||||
|
const type = 'appAssetLibraryImages';
|
||||||
|
const res = (await c.asc('POST', `/v1/${type}`, { data: { type, attributes: { fileName: basename(file), fileSize: buf.length, category: DUO_CATEGORY, referenceName: REF(sum) },
|
||||||
|
relationships: { assetLibrary: { data: { type: 'appAssetLibraries', id: libId } } } } })).data as J;
|
||||||
|
for (const op of (res.attributes.uploadOperations ?? []) as J[]) {
|
||||||
|
const r = await fetch(op.url, { method: op.method, headers: partHeaders(op), body: buf.subarray(op.offset, op.offset + op.length), signal: AbortSignal.timeout(300_000) });
|
||||||
|
if (r.status < 200 || r.status > 299) { await c.asc('DELETE', `/v1/${type}/${res.id}`).catch(() => {}); throw new Error(`upload ${basename(file)} part ${op.offset} -> ${r.status} (reservation deleted, nothing committed)`); }
|
||||||
|
}
|
||||||
|
return (await c.asc('PATCH', `/v1/${type}/${res.id}`, { data: { type, id: res.id, attributes: { uploaded: true } } })).data as J;
|
||||||
|
}
|
||||||
|
|
||||||
|
async function processed(c: Asc, a: J, label: string): Promise<J> {
|
||||||
|
const t0 = Date.now();
|
||||||
|
let beat = t0, cur = a;
|
||||||
|
while (classify(cur.attributes?.state) === 'processing') {
|
||||||
|
if (Date.now() - t0 >= processingTiming.timeoutMs) { warn(TAG, `${label}: still ${cur.attributes?.state ?? 'processing'} after ${elapsed(Date.now() - t0)}; re-run later to place it`); return cur; }
|
||||||
|
await processingTiming.sleep(processingTiming.pollMs);
|
||||||
|
cur = ((await c.maybe(`/v1/${cur.type}/${cur.id}`))?.data as J) ?? cur;
|
||||||
|
if (Date.now() - beat >= processingTiming.heartbeatMs) { beat = Date.now(); log(TAG, `${label}: processing (${cur.attributes?.state}, ${elapsed(Date.now() - t0)})`); }
|
||||||
|
}
|
||||||
|
return cur;
|
||||||
|
}
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
// refuse with the reason), the build, and per locale create / update with old -> new per field. --dry stops there
|
// refuse with the reason), the build, and per locale create / update with old -> new per field. --dry stops there
|
||||||
// (read-only); the real run asks in a terminal and applies exactly that plan. Locales marked status=draft or
|
// (read-only); the real run asks in a terminal and applies exactly that plan. Locales marked status=draft or
|
||||||
// status=translate (listing translate) are skipped unless --include-drafts.
|
// status=translate (listing translate) are skipped unless --include-drafts.
|
||||||
// - the editable iOS version: versionString, copyright, release type MANUAL; with --build that processed build is attached
|
// - the editable iOS version: versionString, copyright, release type (apple.releaseType, MANUAL when new and unset); with --build that processed build is attached
|
||||||
// - appInfoLocalizations: name, subtitle, privacy policy URL per locale
|
// - appInfoLocalizations: name, subtitle, privacy policy URL per locale
|
||||||
// - appStoreVersionLocalizations: description, keywords, promotional text, what's new (not on a first version),
|
// - appStoreVersionLocalizations: description, keywords, promotional text, what's new (not on a first version),
|
||||||
// support + marketing URL per locale
|
// support + marketing URL per locale
|
||||||
|
|
@ -20,7 +20,8 @@ import { compactDiff } from '../lib/diff';
|
||||||
import { mergeAppleListing, overLimits } from '../lib/listing-pull';
|
import { mergeAppleListing, overLimits } from '../lib/listing-pull';
|
||||||
import { counts, draftReason, draftSections, type ItemPlan, itemLines, planItem, planLocales, planVersion, short, type Skipped, type VersionPlan } from '../lib/listing-plan';
|
import { counts, draftReason, draftSections, type ItemPlan, itemLines, planItem, planLocales, planVersion, short, type Skipped, type VersionPlan } from '../lib/listing-plan';
|
||||||
import { createOnce, findOrCreate, getById } from '../lib/upsert';
|
import { createOnce, findOrCreate, getById } from '../lib/upsert';
|
||||||
import { appleName } from '../lib/config';
|
import { appleName, listingPathFor } from '../lib/config';
|
||||||
|
import { wantedRelease } from '../lib/release-type';
|
||||||
import type { Ctx } from '../lib/ctx';
|
import type { Ctx } from '../lib/ctx';
|
||||||
import { confirm, need } from '../lib/ctx';
|
import { confirm, need } from '../lib/ctx';
|
||||||
import { done, log, printJson, warn } from '../lib/log';
|
import { done, log, printJson, warn } from '../lib/log';
|
||||||
|
|
@ -28,10 +29,10 @@ import { ascClient, EDITABLE, type J, noAppInfo } from './asc';
|
||||||
import { stdinIsTTY } from '../lib/tty';
|
import { stdinIsTTY } from '../lib/tty';
|
||||||
import { allVersions, type AscPlatform, parsePlatform, pickPlatform, platformLabel, versionsPath } from './platform';
|
import { allVersions, type AscPlatform, parsePlatform, pickPlatform, platformLabel, versionsPath } from './platform';
|
||||||
|
|
||||||
export function readAppleCopy(ctx: Ctx) {
|
export function readAppleCopy(ctx: Ctx, platform?: string) {
|
||||||
const { config, resolve } = ctx.loaded;
|
const { config, resolve } = ctx.loaded;
|
||||||
const only = ctx.args.list('only');
|
const only = ctx.args.list('only');
|
||||||
const all = parseAppStoreListing(readFileSync(resolve(config.apple?.listing ?? 'store/appstore.md'), 'utf8'));
|
const all = parseAppStoreListing(readFileSync(resolve(listingPathFor(config, platform)), 'utf8'));
|
||||||
return Object.fromEntries(Object.entries(all).filter(([l]) => !only.length || only.includes(l)));
|
return Object.fromEntries(Object.entries(all).filter(([l]) => !only.length || only.includes(l)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -62,7 +63,7 @@ async function pull(ctx: Ctx): Promise<void> {
|
||||||
const at = l.attributes;
|
const at = l.attributes;
|
||||||
remote[at.locale] = { ...remote[at.locale], description: at.description ?? undefined, keywords: at.keywords ?? undefined, promotionalText: at.promotionalText ?? undefined, whatsNew: at.whatsNew ?? undefined };
|
remote[at.locale] = { ...remote[at.locale], description: at.description ?? undefined, keywords: at.keywords ?? undefined, promotionalText: at.promotionalText ?? undefined, whatsNew: at.whatsNew ?? undefined };
|
||||||
}
|
}
|
||||||
const file = resolve(config.apple?.listing ?? 'store/appstore.md');
|
const file = resolve(listingPathFor(config, platform));
|
||||||
const before = existsSync(file) ? readFileSync(file, 'utf8') : '# App Store listing copy\n\nPulled from App Store Connect by `storebound apple listing pull`.\n';
|
const before = existsSync(file) ? readFileSync(file, 'utf8') : '# App Store listing copy\n\nPulled from App Store Connect by `storebound apple listing pull`.\n';
|
||||||
const r = mergeAppleListing(before, remote, appleName(config));
|
const r = mergeAppleListing(before, remote, appleName(config));
|
||||||
const over = overLimits(r.changes, 'apple');
|
const over = overLimits(r.changes, 'apple');
|
||||||
|
|
@ -103,8 +104,8 @@ type Asc = Awaited<ReturnType<typeof ascClient>>;
|
||||||
async function planListing(ctx: Ctx, c: Asc, appId: string, version: string, platform: AscPlatform): Promise<AppleListingPlan> {
|
async function planListing(ctx: Ctx, c: Asc, appId: string, version: string, platform: AscPlatform): Promise<AppleListingPlan> {
|
||||||
const { config, resolve } = ctx.loaded;
|
const { config, resolve } = ctx.loaded;
|
||||||
const app = config.app;
|
const app = config.app;
|
||||||
const listing = readAppleCopy(ctx);
|
const listing = readAppleCopy(ctx, platform);
|
||||||
const md = readFileSync(resolve(config.apple?.listing ?? 'store/appstore.md'), 'utf8');
|
const md = readFileSync(resolve(listingPathFor(config, platform)), 'utf8');
|
||||||
const drafts = draftSections(md, 'apple');
|
const drafts = draftSections(md, 'apple');
|
||||||
const include = ctx.args.has('include-drafts');
|
const include = ctx.args.has('include-drafts');
|
||||||
const skipped: Skipped[] = [];
|
const skipped: Skipped[] = [];
|
||||||
|
|
@ -117,7 +118,8 @@ async function planListing(ctx: Ctx, c: Asc, appId: string, version: string, pla
|
||||||
}
|
}
|
||||||
const copyright = app.copyright ?? `${new Date().getFullYear()} ${app.name}`;
|
const copyright = app.copyright ?? `${new Date().getFullYear()} ${app.name}`;
|
||||||
const rows = await c.all(versionsPath(appId, platform));
|
const rows = await c.all(versionsPath(appId, platform));
|
||||||
const versionPlan = planVersion(rows, version, { copyright, releaseType: 'MANUAL' }, platform);
|
const rel = wantedRelease(config.apple);
|
||||||
|
const versionPlan = planVersion(rows, version, { copyright, releaseType: rel?.releaseType, earliestReleaseDate: rel?.earliestReleaseDate }, platform);
|
||||||
|
|
||||||
let build: AppleListingPlan['build'] = null;
|
let build: AppleListingPlan['build'] = null;
|
||||||
const number = ctx.args.get('build');
|
const number = ctx.args.get('build');
|
||||||
|
|
@ -155,6 +157,7 @@ export function listingPlanLines(p: AppleListingPlan): string[] {
|
||||||
const v = p.versionPlan;
|
const v = p.versionPlan;
|
||||||
const out = [`Version ${p.version} (${platformLabel(p.platform)}; App Store Connect has: ${v.existing.length ? v.existing.map(x => `${x.versionString} ${x.state} ${platformLabel(x.platform)}`).join(', ') : `no ${platformLabel(p.platform)} version yet`})`];
|
const out = [`Version ${p.version} (${platformLabel(p.platform)}; App Store Connect has: ${v.existing.length ? v.existing.map(x => `${x.versionString} ${x.state} ${platformLabel(x.platform)}`).join(', ') : `no ${platformLabel(p.platform)} version yet`})`];
|
||||||
out.push(` ${v.action === 'refuse' ? 'REFUSE' : v.action.toUpperCase()}: ${v.reason}`);
|
out.push(` ${v.action === 'refuse' ? 'REFUSE' : v.action.toUpperCase()}: ${v.reason}`);
|
||||||
|
if (v.warning) out.push(` WARN: ${v.warning}`);
|
||||||
for (const ch of v.changes) out.push(` ${ch.field}: ${v.action === 'create' ? short(ch.to) : `${short(ch.from)} -> ${short(ch.to)}`}`);
|
for (const ch of v.changes) out.push(` ${ch.field}: ${v.action === 'create' ? short(ch.to) : `${short(ch.from)} -> ${short(ch.to)}`}`);
|
||||||
if (p.build) out.push(`Build: ${p.build.action === 'refuse' ? 'REFUSE: ' : ''}${p.build.reason}`);
|
if (p.build) out.push(`Build: ${p.build.action === 'refuse' ? 'REFUSE: ' : ''}${p.build.reason}`);
|
||||||
out.push(`App info ${p.appInfo.state ? `(${p.appInfo.state})` : ''}: name, subtitle, privacy policy URL per locale · ${counts(p.appInfo.locales)}`);
|
out.push(`App info ${p.appInfo.state ? `(${p.appInfo.state})` : ''}: name, subtitle, privacy policy URL per locale · ${counts(p.appInfo.locales)}`);
|
||||||
|
|
|
||||||
|
|
@ -7,15 +7,25 @@ import type { Ctx } from '../lib/ctx';
|
||||||
import { need } from '../lib/ctx';
|
import { need } from '../lib/ctx';
|
||||||
import { printJson } from '../lib/log';
|
import { printJson } from '../lib/log';
|
||||||
import { nextBuildNumber } from '../lib/release';
|
import { nextBuildNumber } from '../lib/release';
|
||||||
import { ascClient } from './asc';
|
import { ascClient, type Asc } from './asc';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The one place that computes the next CFBundleVersion: the highest build of the app over EVERY platform (iOS, macOS,
|
||||||
|
* tvOS, visionOS), every processing state and every page, plus one. CFBundleVersion must be unique across the app
|
||||||
|
* record's builds, so a platform filter (a macOS build once got a number an uploaded macOS build already had) or a
|
||||||
|
* missed page gives a number the store refuses. `apple next-build`, `apple build` and `apple build --platform macos`
|
||||||
|
* (also their dry runs) all call this, so they agree.
|
||||||
|
*/
|
||||||
|
export async function appNextBuild(c: Pick<Asc, 'all' | 'app'>): Promise<{ next: string; builds: number }> {
|
||||||
|
const builds = await c.all(`/v1/builds?filter[app]=${await c.app()}&limit=200&fields[builds]=version`);
|
||||||
|
return { next: nextBuildNumber(builds.map(b => String(b.attributes.version))), builds: builds.length };
|
||||||
|
}
|
||||||
|
|
||||||
export async function run(ctx: Ctx): Promise<void> {
|
export async function run(ctx: Ctx): Promise<void> {
|
||||||
const { config, root } = ctx.loaded;
|
const { config, root } = ctx.loaded;
|
||||||
const c = await ascClient(root, need(config.apple?.bundleId, 'apple.bundleId'), config.apple?.appId);
|
const c = await ascClient(root, need(config.apple?.bundleId, 'apple.bundleId'), config.apple?.appId);
|
||||||
const appId = await c.app();
|
const { next, builds } = await appNextBuild(c);
|
||||||
const builds = await c.all(`/v1/builds?filter[app]=${appId}&limit=200&fields[builds]=version`);
|
if (ctx.args.has('json')) { printJson({ next, builds }); return; }
|
||||||
const next = nextBuildNumber(builds.map(b => String(b.attributes.version)));
|
console.error(`[apple] ${builds} builds on App Store Connect; next build number:`);
|
||||||
if (ctx.args.has('json')) { printJson({ next, builds: builds.length }); return; }
|
|
||||||
console.error(`[apple] ${builds.length} builds on App Store Connect; next build number:`);
|
|
||||||
console.log(next);
|
console.log(next);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,17 @@
|
||||||
// Release management for an App Store version.
|
// Release management for an App Store version.
|
||||||
// storebound apple release --phased on|pause|resume|complete [--version 1.2.0] [--dry] [--yes]
|
// storebound apple release --phased on|pause|resume|complete [--version 1.2.0] [--dry] [--yes]
|
||||||
// storebound apple release --manual-release [--version 1.2.0] [--first-release] [--yes] [--json]
|
// storebound apple release --manual-release [--version 1.2.0] [--first-release] [--yes] [--json]
|
||||||
|
// storebound apple release --after-approval | --manual | --scheduled <ISO date> [--version 1.2.0] [--first-release] [--yes] [--json]
|
||||||
// Both take --platform ios|macos|tvos|visionos; without it the platform that has the version this needs is used (both: asks).
|
// Both take --platform ios|macos|tvos|visionos; without it the platform that has the version this needs is used (both: asks).
|
||||||
// Phased release: 7-day automatic rollout to users with automatic updates (1, 2, 5, 10, 20, 50, 100 %); anyone can
|
// Phased release: 7-day automatic rollout to users with automatic updates (1, 2, 5, 10, 20, 50, 100 %); anyone can
|
||||||
// still update by hand from the App Store. Pause holds it (up to 30 days in total), it is NOT a rollback: users who
|
// still update by hand from the App Store. Pause holds it (up to 30 days in total), it is NOT a rollback: users who
|
||||||
// updated keep the build. "complete" releases to everyone at once.
|
// updated keep the build. "complete" releases to everyone at once.
|
||||||
|
// --after-approval / --manual / --scheduled set how the version goes live (appStoreVersions.releaseType; the config's
|
||||||
|
// apple.releaseType does the same in `apple listing` and `apple submit`). Allowed until App Review approves the version
|
||||||
|
// (Prepare for Submission, rejected, Waiting for Review, In Review); an approved one (Pending Developer Release) is
|
||||||
|
// released with --manual-release, a released one is final. Setting it when it is that type already is exit 7 under the
|
||||||
|
// ship-step contract. An update of an app on sale is an agent step; --after-approval on the first version of an app
|
||||||
|
// puts it on sale by itself, so that one is the owner's (exit 3 OWNER_STEP unless --first-release).
|
||||||
// --manual-release releases an approved version (PENDING_DEVELOPER_RELEASE). Public and irreversible: asks first
|
// --manual-release releases an approved version (PENDING_DEVELOPER_RELEASE). Public and irreversible: asks first
|
||||||
// (--yes in scripts). Releasing an UPDATE of an app already on sale is an agent step (no owner gate, also in a
|
// (--yes in scripts). Releasing an UPDATE of an app already on sale is an agent step (no owner gate, also in a
|
||||||
// pipeline; under the ship-step contract: exit 7 when the version is released already). The first-ever release of an
|
// pipeline; under the ship-step contract: exit 7 when the version is released already). The first-ever release of an
|
||||||
|
|
@ -18,6 +25,7 @@ import { consoleUrl } from '../lib/console-links';
|
||||||
import { appleReleaseKind, enforceFirstRelease } from '../lib/release-kind';
|
import { appleReleaseKind, enforceFirstRelease } from '../lib/release-kind';
|
||||||
import { type PhasedAction, phasedRequest } from '../lib/release';
|
import { type PhasedAction, phasedRequest } from '../lib/release';
|
||||||
import { createOnce } from '../lib/upsert';
|
import { createOnce } from '../lib/upsert';
|
||||||
|
import { ASC_RELEASE_TYPE, changeText, RELEASE_TYPE_EDITABLE, releaseTypeChanges, type WantedRelease } from '../lib/release-type';
|
||||||
import { ascClient, type J } from './asc';
|
import { ascClient, type J } from './asc';
|
||||||
import { allVersions, parsePlatform, pickPlatform, platformLabel, versionsPath } from './platform';
|
import { allVersions, parsePlatform, pickPlatform, platformLabel, versionsPath } from './platform';
|
||||||
|
|
||||||
|
|
@ -26,12 +34,16 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const a = ctx.args;
|
const a = ctx.args;
|
||||||
const phased = a.get('phased') as PhasedAction | undefined;
|
const phased = a.get('phased') as PhasedAction | undefined;
|
||||||
const manual = a.has('manual-release');
|
const manual = a.has('manual-release');
|
||||||
if (!phased && !manual) throw new Error('usage: apple release --phased on|pause|resume|complete | --manual-release [--version x.y.z] [--dry] [--yes]');
|
const typeFlags = [a.has('after-approval') && 'afterApproval', a.has('manual') && 'manual', a.has('scheduled') && 'scheduled'].filter((x): x is 'afterApproval' | 'manual' | 'scheduled' => !!x);
|
||||||
|
if (typeFlags.length > 1) throw new Error('--after-approval, --manual and --scheduled are alternatives: give one');
|
||||||
|
if (!phased && !manual && !typeFlags.length) throw new Error('usage: apple release --phased on|pause|resume|complete | --manual-release | --after-approval | --manual | --scheduled <ISO date> [--version x.y.z] [--dry] [--yes]');
|
||||||
|
if (typeFlags.length && (phased || manual)) throw new Error('the release type flags (--after-approval, --manual, --scheduled) are a command of their own: run --phased / --manual-release separately');
|
||||||
if (phased && !['on', 'pause', 'resume', 'complete'].includes(phased)) throw new Error('--phased: on | pause | resume | complete');
|
if (phased && !['on', 'pause', 'resume', 'complete'].includes(phased)) throw new Error('--phased: on | pause | resume | complete');
|
||||||
const dry = a.has('dry');
|
const dry = a.has('dry');
|
||||||
const c = await ascClient(root, need(config.apple?.bundleId, 'apple.bundleId'), config.apple?.appId);
|
const c = await ascClient(root, need(config.apple?.bundleId, 'apple.bundleId'), config.apple?.appId);
|
||||||
const appId = await c.app();
|
const appId = await c.app();
|
||||||
const want = a.get('version');
|
const want = a.get('version');
|
||||||
|
if (typeFlags.length) return setReleaseType(ctx, c, appId, typeFlags[0]!);
|
||||||
const state = (v: J): string => v.attributes.appVersionState ?? v.attributes.appStoreState;
|
const state = (v: J): string => v.attributes.appVersionState ?? v.attributes.appStoreState;
|
||||||
shipReport({ version: want, url: consoleUrl('asc.version') });
|
shipReport({ version: want, url: consoleUrl('asc.version') });
|
||||||
// the ship-step contract: the version is released already (and none waits for release): nothing to do, exit 7
|
// the ship-step contract: the version is released already (and none waits for release): nothing to do, exit 7
|
||||||
|
|
@ -96,3 +108,52 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
}
|
}
|
||||||
done('apple', `${tag}: ${req.note}`);
|
done('apple', `${tag}: ${req.note}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** apple release --after-approval | --manual | --scheduled: PATCH appStoreVersions releaseType on a version App Review has not approved yet. */
|
||||||
|
async function setReleaseType(ctx: Ctx, c: Awaited<ReturnType<typeof ascClient>>, appId: string, name: 'afterApproval' | 'manual' | 'scheduled'): Promise<void> {
|
||||||
|
const a = ctx.args;
|
||||||
|
const TAG = 'apple';
|
||||||
|
const want = a.get('version');
|
||||||
|
const state = (v: J): string => v.attributes.appVersionState ?? v.attributes.appStoreState;
|
||||||
|
const date = name === 'scheduled' ? a.required('scheduled', 'ISO date and time', 'e.g. --scheduled 2027-03-01T09:00:00Z') : undefined;
|
||||||
|
if (date && Number.isNaN(Date.parse(date))) throw new Error(`--scheduled ${date}: an ISO 8601 date and time, e.g. 2027-03-01T09:00:00Z`);
|
||||||
|
const target: WantedRelease = { releaseType: ASC_RELEASE_TYPE[name], ...(date ? { earliestReleaseDate: date } : {}) };
|
||||||
|
shipReport({ version: want, url: consoleUrl('asc.version') });
|
||||||
|
const fits = (x: J): boolean => (!want || x.attributes.versionString === want) && (RELEASE_TYPE_EDITABLE.has(state(x)) || state(x) === 'PENDING_DEVELOPER_RELEASE');
|
||||||
|
const platform = parsePlatform(a.get('platform')) ?? pickPlatform(await allVersions(c, appId), want ? [fits, (x: J) => x.attributes.versionString === want] : fits, undefined, 'a version that is not approved yet');
|
||||||
|
const versions = await c.all(versionsPath(appId, platform, 20));
|
||||||
|
const v: J | undefined = want ? versions.find(x => x.attributes.versionString === want) : versions.find(x => RELEASE_TYPE_EDITABLE.has(state(x))) ?? versions.find(x => state(x) === 'PENDING_DEVELOPER_RELEASE');
|
||||||
|
if (!v) throw new Error(`${platformLabel(platform)}: ${want ? `no version ${want}` : 'no version waiting for App Review (Prepare for Submission, rejected, Waiting for Review, In Review)'}`);
|
||||||
|
const versionString = String(v.attributes.versionString);
|
||||||
|
const tag = `${versionString} ${platformLabel(platform)} (${state(v)})`;
|
||||||
|
const changes = releaseTypeChanges(v.attributes, target);
|
||||||
|
const kind = appleReleaseKind(versions.map((x: J) => ({ versionString: String(x.attributes.versionString), state: state(x) })));
|
||||||
|
shipReport({ version: versionString, state: state(v) });
|
||||||
|
const result = (extra: Record<string, unknown>): void => { if (a.has('json')) printJson({ version: versionString, state: state(v), platform, releaseType: target.releaseType, from: v.attributes.releaseType ?? null, releaseKind: kind.kind, ...extra }); };
|
||||||
|
if (!changes.length) {
|
||||||
|
shipNoop({ version: versionString, state: state(v) });
|
||||||
|
result({ changed: false, alreadyThere: true });
|
||||||
|
done(TAG, `${tag}: release type is ${target.releaseType} already: nothing changed`);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (!RELEASE_TYPE_EDITABLE.has(state(v))) {
|
||||||
|
throw new Error(`${tag}: the release type can no longer be changed${state(v) === 'PENDING_DEVELOPER_RELEASE' ? ` (App Review approved it and it waits for you: release it with storebound apple release --manual-release --version ${versionString})` : ' (it is approved or released; App Store Connect only takes the change before approval)'}`);
|
||||||
|
}
|
||||||
|
if (a.has('dry')) {
|
||||||
|
log(TAG, `would set the release type of ${tag}: ${changeText(changes)} (dry)`);
|
||||||
|
result({ changed: false, dryRun: true, changes });
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// after approval = on sale at once: for the first version of an app that is the owner's step
|
||||||
|
if (target.releaseType === 'AFTER_APPROVAL' && !enforceFirstRelease(ctx, kind, { store: 'apple', what: 'the first release of the app (it goes on sale by itself once approved)', consoleUrl: consoleUrl('asc.version') })) return;
|
||||||
|
if (!(await confirm(ctx, `Set the release type of ${tag}: ${changeText(changes)}?`))) return;
|
||||||
|
try {
|
||||||
|
await c.asc('PATCH', `/v1/appStoreVersions/${v.id}`, { data: { type: 'appStoreVersions', id: v.id, attributes: Object.fromEntries(changes.map(ch => [ch.field, ch.to])) } });
|
||||||
|
} catch (e) {
|
||||||
|
if (/-> 409\b/.test((e as Error).message)) throw new Error(`${tag}: App Store Connect refuses the release type change now (409): ${(e as Error).message}
|
||||||
|
It is editable until App Review approves the version; after that use apple release --manual-release.`);
|
||||||
|
throw e;
|
||||||
|
}
|
||||||
|
result({ changed: true, changes });
|
||||||
|
done(TAG, `${tag}: release type ${changeText(changes)}`);
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,8 @@
|
||||||
// `storebound apple submit --build <n>` (cli/apple/submit.ts) runs the same steps for a first submission: the version
|
// `storebound apple submit --build <n>` (cli/apple/submit.ts) runs the same steps for a first submission: the version
|
||||||
// is --version, else the one an open submission holds, else the editable one (Prepare for Submission or rejected).
|
// is --version, else the one an open submission holds, else the editable one (Prepare for Submission or rejected).
|
||||||
// Under `serve` (the desktop's owner action) the plan table is printed next to the --json result.
|
// Under `serve` (the desktop's owner action) the plan table is printed next to the --json result.
|
||||||
import { sellsOn } from '../lib/config';
|
import { macosSubmitSkips, sellsOn } from '../lib/config';
|
||||||
|
import { changeText, RELEASE_TYPE_EDITABLE, releaseTypeChanges, wantedRelease } from '../lib/release-type';
|
||||||
import type { Ctx } from '../lib/ctx';
|
import type { Ctx } from '../lib/ctx';
|
||||||
import { need } from '../lib/ctx';
|
import { need } from '../lib/ctx';
|
||||||
import { done, log, printJson, warn } from '../lib/log';
|
import { done, log, printJson, warn } from '../lib/log';
|
||||||
|
|
@ -85,6 +86,10 @@ export async function submitVersion(ctx: Ctx, mode: 'submit' | 'resubmit'): Prom
|
||||||
&& ((mode === 'submit' ? SUBMITTABLE_APP : REJECTED_APP).has(stateOf(x)) || back.has(platformOf(x)));
|
&& ((mode === 'submit' ? SUBMITTABLE_APP : REJECTED_APP).has(stateOf(x)) || back.has(platformOf(x)));
|
||||||
platform = pickPlatform(every, fits, undefined, mode === 'submit' ? `a version to submit${want ? ` (${want})` : ''}` : `a rejected version${want ? ` (${want})` : ''}`);
|
platform = pickPlatform(every, fits, undefined, mode === 'submit' ? `a version to submit${want ? ` (${want})` : ''}` : `a rejected version${want ? ` (${want})` : ''}`);
|
||||||
}
|
}
|
||||||
|
// the Mac app of a two-platform record may sell nothing and have no Game Center (apple.macos): its submission then
|
||||||
|
// carries the version and build only
|
||||||
|
const macSkips = macosSubmitSkips(config, platform);
|
||||||
|
if (macSkips.iaps && ids.length) { log(TAG, `${ids.length} in-app purchase(s) left out: ${macSkips.iaps}`); ids.length = 0; }
|
||||||
const versions = await c.all(versionsPath(appId, platform));
|
const versions = await c.all(versionsPath(appId, platform));
|
||||||
const open = await openSubmissions(c, appId, undefined, platform);
|
const open = await openSubmissions(c, appId, undefined, platform);
|
||||||
const held = new Set(open.filter(s => s.state === 'UNRESOLVED_ISSUES').flatMap(s => s.items.filter(i => i.kind === 'appStoreVersion').map(i => i.versionId)));
|
const held = new Set(open.filter(s => s.state === 'UNRESOLVED_ISSUES').flatMap(s => s.items.filter(i => i.kind === 'appStoreVersion').map(i => i.versionId)));
|
||||||
|
|
@ -97,6 +102,10 @@ export async function submitVersion(ctx: Ctx, mode: 'submit' | 'resubmit'): Prom
|
||||||
if (mode === 'submit' && !SUBMITTABLE_APP.has(stateOf(v)) && !held.has(v.id)) throw new Error(`App Store version ${String(v.attributes.versionString)} (${pl}) is ${stateOf(v)}: only a version in Prepare for Submission (or a rejected one) can be submitted`);
|
if (mode === 'submit' && !SUBMITTABLE_APP.has(stateOf(v)) && !held.has(v.id)) throw new Error(`App Store version ${String(v.attributes.versionString)} (${pl}) is ${stateOf(v)}: only a version in Prepare for Submission (or a rejected one) can be submitted`);
|
||||||
const versionString = String(v.attributes.versionString);
|
const versionString = String(v.attributes.versionString);
|
||||||
if (!a.has('json')) log(TAG, `app version ${versionString} (${pl}): ${stateOf(v)}`);
|
if (!a.has('json')) log(TAG, `app version ${versionString} (${pl}): ${stateOf(v)}`);
|
||||||
|
// apple.releaseType: the version goes live as the config says (afterApproval | manual | scheduled); set before the submit when it differs
|
||||||
|
const relWant = wantedRelease(config.apple);
|
||||||
|
const relChanges = relWant ? releaseTypeChanges(v.attributes, relWant) : [];
|
||||||
|
if (relChanges.length && !RELEASE_TYPE_EDITABLE.has(stateOf(v))) throw new Error(`App Store version ${versionString} (${pl}) is ${stateOf(v)}: its release type can no longer be changed (apple.releaseType wants ${changeText(relChanges)})`);
|
||||||
|
|
||||||
// the build, by its number
|
// the build, by its number
|
||||||
const b = (await c.all(`/v1/builds?filter[app]=${appId}&filter[version]=${number}&filter[preReleaseVersion.version]=${versionString}&filter[preReleaseVersion.platform]=${platform}`))[0];
|
const b = (await c.all(`/v1/builds?filter[app]=${appId}&filter[version]=${number}&filter[preReleaseVersion.version]=${versionString}&filter[preReleaseVersion.platform]=${platform}`))[0];
|
||||||
|
|
@ -120,10 +129,11 @@ export async function submitVersion(ctx: Ctx, mode: 'submit' | 'resubmit'): Prom
|
||||||
// Game Center: a build with the entitlement needs the app's Game Center detail and the version's switch, else the
|
// Game Center: a build with the entitlement needs the app's Game Center detail and the version's switch, else the
|
||||||
// submission answers 409 STATE_ERROR.BUILD_INDICATES_GAME_CENTER_ENABLED (seen live); the same upsert as apple game-center
|
// submission answers 409 STATE_ERROR.BUILD_INDICATES_GAME_CENTER_ENABLED (seen live); the same upsert as apple game-center
|
||||||
const gcUse = gameCenterInUse(config, root);
|
const gcUse = gameCenterInUse(config, root);
|
||||||
const gc = gcUse.inUse ? await readGcSwitch(c, appId, v) : null;
|
if (gcUse.inUse && macSkips.gameCenter) log(TAG, `Game Center switch left alone: ${macSkips.gameCenter}`);
|
||||||
|
const gc = gcUse.inUse && !macSkips.gameCenter ? await readGcSwitch(c, appId, v) : null;
|
||||||
const gcPlan = gc ? gcSwitchPlan(gc) : [];
|
const gcPlan = gc ? gcSwitchPlan(gc) : [];
|
||||||
if (a.has('json')) {
|
if (a.has('json')) {
|
||||||
printJson({ dryRun: dry, releaseKind: kind.kind, gameCenter: gcPlan, version: { id: v.id, versionString, platform, state: stateOf(v) }, build, submission: state.choice ?? null, resolve: marks, rows, skipped: plan.skipped, blockers });
|
printJson({ dryRun: dry, releaseKind: kind.kind, releaseType: relChanges.length ? { changes: relChanges } : null, gameCenter: gcPlan, version: { id: v.id, versionString, platform, state: stateOf(v) }, build, submission: state.choice ?? null, resolve: marks, rows, skipped: plan.skipped, blockers });
|
||||||
// the desktop's owner dialog shows the output text: the plan table goes with the result there
|
// the desktop's owner dialog shows the output text: the plan table goes with the result there
|
||||||
if (process.env.STOREBOUND_MACHINE === '1') { console.log(formatRows(rows)); for (const x of blockers) warn(TAG, x); }
|
if (process.env.STOREBOUND_MACHINE === '1') { console.log(formatRows(rows)); for (const x of blockers) warn(TAG, x); }
|
||||||
if (blockers.length) process.exitCode = 1;
|
if (blockers.length) process.exitCode = 1;
|
||||||
|
|
@ -132,6 +142,7 @@ export async function submitVersion(ctx: Ctx, mode: 'submit' | 'resubmit'): Prom
|
||||||
} else {
|
} else {
|
||||||
console.log(formatRows(rows));
|
console.log(formatRows(rows));
|
||||||
log(TAG, `${kind.kind === 'update' ? 'update of an app on sale' : 'FIRST release of this app (the owner approves it once: --first-release)'}: ${kind.why}`);
|
log(TAG, `${kind.kind === 'update' ? 'update of an app on sale' : 'FIRST release of this app (the owner approves it once: --first-release)'}: ${kind.why}`);
|
||||||
|
if (relChanges.length) log(TAG, `${dry ? 'would set' : 'setting'} release type: ${changeText(relChanges)} (apple.releaseType)`);
|
||||||
for (const l of gcPlan) log(TAG, `${dry ? 'would ' : ''}${l} (Game Center: ${gcUse.why})`);
|
for (const l of gcPlan) log(TAG, `${dry ? 'would ' : ''}${l} (Game Center: ${gcUse.why})`);
|
||||||
for (const s of plan.skipped) log(TAG, `not added ${s.id}: ${s.why}`);
|
for (const s of plan.skipped) log(TAG, `not added ${s.id}: ${s.why}`);
|
||||||
for (const x of blockers) warn(TAG, x);
|
for (const x of blockers) warn(TAG, x);
|
||||||
|
|
@ -149,6 +160,10 @@ export async function submitVersion(ctx: Ctx, mode: 'submit' | 'resubmit'): Prom
|
||||||
await c.asc('PATCH', `/v1/appStoreVersions/${v.id}/relationships/build`, { data: { type: 'builds', id: build.id } });
|
await c.asc('PATCH', `/v1/appStoreVersions/${v.id}/relationships/build`, { data: { type: 'builds', id: build.id } });
|
||||||
log(TAG, `build ${number} attached to ${versionString}`);
|
log(TAG, `build ${number} attached to ${versionString}`);
|
||||||
}
|
}
|
||||||
|
if (relChanges.length) {
|
||||||
|
await c.asc('PATCH', `/v1/appStoreVersions/${v.id}`, { data: { type: 'appStoreVersions', id: v.id, attributes: Object.fromEntries(relChanges.map(ch => [ch.field, ch.to])) } });
|
||||||
|
log(TAG, `release type of ${versionString}: ${changeText(relChanges)}`);
|
||||||
|
}
|
||||||
if (gc && gcPlan.length) await ensureGcSwitch(c, gc, TAG);
|
if (gc && gcPlan.length) await ensureGcSwitch(c, gc, TAG);
|
||||||
try {
|
try {
|
||||||
await submitPlanned(ctx, c, { appId, ids, state, tag: TAG, withVersion: true, appVersionId: v.id, platform, quiet: true, resolve });
|
await submitPlanned(ctx, c, { appId, ids, state, tag: TAG, withVersion: true, appVersionId: v.id, platform, quiet: true, resolve });
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,11 @@
|
||||||
// App Review information on the editable version: contact, demo account, notes. Idempotent.
|
// App Review information on the editable version: contact, demo account, notes. Idempotent.
|
||||||
// storebound apple review-details [--contact-from <Apple ID of another app>] [--dry]
|
// storebound apple review-details [--platform ios|macos|tvos|visionos] [--contact-from <Apple ID of another app>] [--dry]
|
||||||
// The contact (name, phone, email) is personal data, so it is never in the config: it comes from
|
// The contact (name, phone, email) is personal data, so it is never in the config: it comes from
|
||||||
// .storebound/credentials.json "reviewContact", or is copied from another app of the same team with --contact-from.
|
// .storebound/credentials.json "reviewContact", or is copied from another app of the same team with --contact-from.
|
||||||
// Demo account (reviewAccess.signInRequired: true): "reviewDemoAccount" in .storebound/credentials.json or
|
// Demo account (reviewAccess.signInRequired: true): "reviewDemoAccount" in .storebound/credentials.json or
|
||||||
// REVIEW_DEMO_USER / REVIEW_DEMO_PASSWORD; masked in every log line. Notes: apple.info.reviewNotes plus
|
// REVIEW_DEMO_USER / REVIEW_DEMO_PASSWORD; masked in every log line. Notes: apple.info.reviewNotes plus
|
||||||
// reviewAccess.instructions and accounts.inApp (lib/review-details.ts).
|
// reviewAccess.instructions and accounts.inApp (lib/review-details.ts). --platform macos: apple.macos.reviewNotes
|
||||||
|
// replaces apple.info.reviewNotes when set (a Mac app may have no Game Center, IAP or ads).
|
||||||
import { refuseTemplate } from '../lib/template-answers';
|
import { refuseTemplate } from '../lib/template-answers';
|
||||||
import type { Ctx } from '../lib/ctx';
|
import type { Ctx } from '../lib/ctx';
|
||||||
import { need } from '../lib/ctx';
|
import { need } from '../lib/ctx';
|
||||||
|
|
@ -12,7 +13,8 @@ import { findReviewContact, maskSecret, maskUser, noContactMessage, reviewDemoAc
|
||||||
import { reviewDetailPlan } from '../lib/review-details';
|
import { reviewDetailPlan } from '../lib/review-details';
|
||||||
import { done, log } from '../lib/log';
|
import { done, log } from '../lib/log';
|
||||||
import { createOnce } from '../lib/upsert';
|
import { createOnce } from '../lib/upsert';
|
||||||
import { ascClient } from './asc';
|
import { ascClient, EDITABLE, type J } from './asc';
|
||||||
|
import { allVersions, parsePlatform, pickPlatform, platformLabel } from './platform';
|
||||||
|
|
||||||
type Attrs = Record<string, unknown>;
|
type Attrs = Record<string, unknown>;
|
||||||
const shown = (k: string, v: unknown): string => {
|
const shown = (k: string, v: unknown): string => {
|
||||||
|
|
@ -36,8 +38,10 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const { config, root } = ctx.loaded;
|
const { config, root } = ctx.loaded;
|
||||||
refuseTemplate(config, ['reviewNotes', 'reviewAccess', 'accounts'], 'apple review-details (App Review notes, demo account requirement)');
|
refuseTemplate(config, ['reviewNotes', 'reviewAccess', 'accounts'], 'apple review-details (App Review notes, demo account requirement)');
|
||||||
const c = await ascClient(root, need(config.apple?.bundleId, 'apple.bundleId'), config.apple?.appId);
|
const c = await ascClient(root, need(config.apple?.bundleId, 'apple.bundleId'), config.apple?.appId);
|
||||||
const version = await c.editableVersion();
|
const appId = await c.app();
|
||||||
if (!version) throw new Error('no editable App Store version (apple listing --version x.y.z creates it)');
|
const platform = parsePlatform(ctx.args.get('platform')) ?? pickPlatform(await allVersions(c, appId), (x: J) => EDITABLE.has(x.attributes.appVersionState ?? x.attributes.appStoreState), undefined, 'an editable version');
|
||||||
|
const version = await c.editableVersion(platform);
|
||||||
|
if (!version) throw new Error(`no editable ${platformLabel(platform)} App Store version (apple listing --version x.y.z creates it)`);
|
||||||
|
|
||||||
let contact: Record<string, string> | null = null;
|
let contact: Record<string, string> | null = null;
|
||||||
const from = ctx.args.get('contact-from');
|
const from = ctx.args.get('contact-from');
|
||||||
|
|
@ -57,7 +61,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
}
|
}
|
||||||
if (!contact) throw new Error(noContactMessage(root, checked));
|
if (!contact) throw new Error(noContactMessage(root, checked));
|
||||||
|
|
||||||
const { attributes, summary } = reviewDetailPlan(config, contact, reviewDemoAccount(root));
|
const { attributes, summary } = reviewDetailPlan(config, contact, reviewDemoAccount(root), platform);
|
||||||
const read = async () => (await c.maybe(`/v1/appStoreVersions/${version.id}/appStoreReviewDetail`))?.data ?? null;
|
const read = async () => (await c.maybe(`/v1/appStoreVersions/${version.id}/appStoreReviewDetail`))?.data ?? null;
|
||||||
const cur = await read();
|
const cur = await read();
|
||||||
if (ctx.args.has('dry')) {
|
if (ctx.args.has('dry')) {
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,12 @@
|
||||||
// Store screenshots of every locale on the editable App Store version (idempotent: a set whose files already match
|
// Store screenshots of every locale on the editable App Store version (idempotent: a set whose files already match
|
||||||
// by MD5 and order is left alone, otherwise it is emptied and re-uploaded).
|
// by MD5 and order is left alone, otherwise it is emptied and re-uploaded).
|
||||||
// storebound apple screenshots [--src store/renders] [--only en-US,tr] [--jobs 4] [--variant b] [--dry]
|
// storebound apple screenshots [--src store/renders] [--only en-US,tr] [--jobs 4] [--variant b] [--duo-only] [--dry]
|
||||||
// storebound apple screenshots --repair-stuck [--dry] (only the screenshots stuck outside COMPLETE, in place)
|
// storebound apple screenshots --repair-stuck [--dry] (only the screenshots stuck outside COMPLETE, in place)
|
||||||
// Source per language: <renders>/<language id>/ios69/NN.png (6.9", 1320 x 2868 -> APP_IPHONE_67),
|
// Source per language: <renders>/<language id>/ios69/NN.png (6.9", 1320 x 2868 -> APP_IPHONE_67),
|
||||||
// ios65/NN.png (6.5", 1284 x 2778 -> APP_IPHONE_65) and, only with apple.ipad, ipad13/NN.png (13" iPad, 2064 x 2752 ->
|
// ios65/NN.png (6.5", 1284 x 2778 -> APP_IPHONE_65) and, only with apple.ipad, ipad13/NN.png (13" iPad, 2064 x 2752 ->
|
||||||
// APP_IPAD_PRO_3GEN_129: the API has no "13 inch" value, the 13" display set keeps the 3rd gen 12.9" name). With
|
// APP_IPAD_PRO_3GEN_129: the API has no "13 inch" value, the 13" display set keeps the 3rd gen 12.9" name). With
|
||||||
// --platform macos (or when only the macOS version is editable) and apple.mac: mac/NN.png (2880 x 1800 -> APP_DESKTOP)
|
// --platform macos (or when only the macOS version is editable) and apple.mac: mac/NN.png (2880 x 1800 -> APP_DESKTOP)
|
||||||
// to the macOS version. iPhone Duo sets are skipped with the console deep link (no API display type yet). Up to 10
|
// to the macOS version. iPhone Duo (apple.iphoneDuo: iphone-duo-outer/ then iphone-duo-inner/) goes through the App Asset Library. Up to 10
|
||||||
// per set. --variant <id> uploads <renders>/<id>/<lang>/... instead (an A/B variant from shots.variants, e.g. for a
|
// per set. --variant <id> uploads <renders>/<id>/<lang>/... instead (an A/B variant from shots.variants, e.g. for a
|
||||||
// Product Page Optimization treatment you then set up in App Store Connect). Apple processes uploads asynchronously; failed
|
// Product Page Optimization treatment you then set up in App Store Connect). Apple processes uploads asynchronously; failed
|
||||||
// ones are reported at the end. Long: run in the background with a log file.
|
// ones are reported at the end. Long: run in the background with a log file.
|
||||||
|
|
@ -20,7 +20,8 @@ import { variantRoot } from '../shots/lib';
|
||||||
import { findOrCreate } from '../lib/upsert';
|
import { findOrCreate } from '../lib/upsert';
|
||||||
import { pulledChecksum } from '../lib/art-pull';
|
import { pulledChecksum } from '../lib/art-pull';
|
||||||
import { consoleLink } from '../lib/console-links';
|
import { consoleLink } from '../lib/console-links';
|
||||||
import { IPHONE_DUO_DISPLAY, IPHONE_DUO_NOT_IN_API } from '../shots/spec';
|
import { IPHONE_DUO_DISPLAY } from '../shots/spec';
|
||||||
|
import { duoGroup, syncDuo } from './duo-library';
|
||||||
import { type Asc, ascClient, EDITABLE, keptPrefix, md5, setUpToDate, type J } from './asc';
|
import { type Asc, ascClient, EDITABLE, keptPrefix, md5, setUpToDate, type J } from './asc';
|
||||||
import { pendingScreenshots, repairPlan, repairSet, setRows, updateLedger } from './screenshot-health';
|
import { pendingScreenshots, repairPlan, repairSet, setRows, updateLedger } from './screenshot-health';
|
||||||
import { allVersions, parsePlatform, pickPlatform, platformLabel, stateOf, versionLabel } from './platform';
|
import { allVersions, parsePlatform, pickPlatform, platformLabel, stateOf, versionLabel } from './platform';
|
||||||
|
|
@ -42,18 +43,17 @@ export const displaySets = (apple: { ipad?: boolean; iphoneMedium?: boolean; iph
|
||||||
platform === 'MAC_OS' ? (apple?.mac ? MAC_DISPLAY : {}) : ({ ...DISPLAY, ...(apple?.iphoneMedium ? MEDIUM_DISPLAY : {}), ...(apple?.ipad ? IPAD_DISPLAY : {}),
|
platform === 'MAC_OS' ? (apple?.mac ? MAC_DISPLAY : {}) : ({ ...DISPLAY, ...(apple?.iphoneMedium ? MEDIUM_DISPLAY : {}), ...(apple?.ipad ? IPAD_DISPLAY : {}),
|
||||||
...(apple?.iphoneDuo ? Object.fromEntries(Object.entries(IPHONE_DUO_DISPLAY).filter((e): e is [string, string] => !!e[1])) : {}) });
|
...(apple?.iphoneDuo ? Object.fromEntries(Object.entries(IPHONE_DUO_DISPLAY).filter((e): e is [string, string] => !!e[1])) : {}) });
|
||||||
|
|
||||||
/** iPhone Duo size keys `apple screenshots` skips (apple.iphoneDuo on, no API display type yet), with the message. */
|
/** iPhone Duo size keys (render folders) `apple screenshots` uploads through the App Asset Library (no
|
||||||
export function skippedDuoSets(apple: { iphoneDuo?: boolean; appId?: string } | undefined): { dirs: string[]; msg: string } | null {
|
* ScreenshotDisplayType exists for Duo: cli/apple/duo-library.ts, pitfall 130), outer display first. */
|
||||||
const dirs = apple?.iphoneDuo ? Object.entries(IPHONE_DUO_DISPLAY).filter(([, t]) => !t).map(([k]) => k) : [];
|
export const duoDirs = (apple: { iphoneDuo?: boolean } | undefined): string[] => (apple?.iphoneDuo ? Object.keys(IPHONE_DUO_DISPLAY) : []);
|
||||||
// the console takes them (its own "iPhone Duo" tab): send the owner straight to the version page
|
|
||||||
return dirs.length ? { dirs, msg: `${dirs.join(', ')}: ${IPHONE_DUO_NOT_IN_API}. Add them in ${consoleLink('asc.version', '> App Previews and Screenshots > iPhone Duo', { appleAppId: apple?.appId })}` } : null;
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Display types `validate` requires on every locale: apple.screenshotTypes, else the classes App Store Connect's
|
/** Display types `validate` requires on every locale: apple.screenshotTypes, else the classes App Store Connect's
|
||||||
* "App Previews and Screenshots" tab lists (October 2026): iPhone with Dynamic Island (medium display), filled by
|
* "App Previews and Screenshots" tab lists (October 2026): iPhone with Dynamic Island (medium display), filled by
|
||||||
* scaling a 6.9" or 6.5" set down (ACCEPTED_INSTEAD), plus iPad 13" display with ipad. iPhone Duo is optional. */
|
* scaling a 6.9" or 6.5" set down (ACCEPTED_INSTEAD), plus iPad 13" display with ipad. iPhone Duo is optional. */
|
||||||
export const requiredDisplayTypes = (apple: { ipad?: boolean; screenshotTypes?: string[] } | undefined): string[] =>
|
export const requiredDisplayTypes = (apple: { ipad?: boolean; mac?: boolean; screenshotTypes?: string[] } | undefined, platform: string = 'IOS'): string[] =>
|
||||||
apple?.screenshotTypes ?? ['APP_IPHONE_61', ...(apple?.ipad ? ['APP_IPAD_PRO_3GEN_129'] : [])];
|
platform === 'MAC_OS' ? (apple?.mac ? Object.values(MAC_DISPLAY) : []) // a macOS version takes the Mac set only (apple.screenshotTypes is the iOS list)
|
||||||
|
: platform !== 'IOS' ? []
|
||||||
|
: apple?.screenshotTypes ?? ['APP_IPHONE_61', ...(apple?.ipad ? ['APP_IPAD_PRO_3GEN_129'] : [])];
|
||||||
|
|
||||||
/** Makes one screenshot set (of a version localization, a custom product page localization or a Product Page
|
/** Makes one screenshot set (of a version localization, a custom product page localization or a Product Page
|
||||||
* Optimization treatment localization) hold exactly `files`, in order: left alone when the MD5s match, else the
|
* Optimization treatment localization) hold exactly `files`, in order: left alone when the MD5s match, else the
|
||||||
|
|
@ -96,8 +96,10 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const version = await c.editableVersion(platform);
|
const version = await c.editableVersion(platform);
|
||||||
if (!version) throw new Error(`no editable ${platformLabel(platform)} App Store version (run apple listing --version x.y.z first)`);
|
if (!version) throw new Error(`no editable ${platformLabel(platform)} App Store version (run apple listing --version x.y.z first)`);
|
||||||
log('apple', `screenshots for version ${versionLabel(version)}`);
|
log('apple', `screenshots for version ${versionLabel(version)}`);
|
||||||
const duoSkip = platform === 'MAC_OS' ? null : skippedDuoSets(config.apple);
|
let duo = platform === 'MAC_OS' ? [] : duoDirs(config.apple);
|
||||||
if (duoSkip) warn('apple', duoSkip.msg);
|
// a Duo problem never stops the other sets
|
||||||
|
const duoGroupId = duo.length ? await duoGroup(c).catch((e: Error) => { warn('apple', `iPhone Duo skipped: ${e.message}`); duo = []; return null; }) : null;
|
||||||
|
const appId = duo.length ? await c.app() : '';
|
||||||
if (platform === 'MAC_OS' && !config.apple?.mac) throw new Error('macOS version: set apple.mac: true and render the mac size (storebound shots render --size mac) first');
|
if (platform === 'MAC_OS' && !config.apple?.mac) throw new Error('macOS version: set apple.mac: true and render the mac size (storebound shots render --size mac) first');
|
||||||
if (platform !== 'MAC_OS' && config.apple?.mac) log('apple', 'Mac screenshots (mac/, APP_DESKTOP) go to the macOS version: run apple screenshots --platform macos');
|
if (platform !== 'MAC_OS' && config.apple?.mac) log('apple', 'Mac screenshots (mac/, APP_DESKTOP) go to the macOS version: run apple screenshots --platform macos');
|
||||||
const langOf = byAppleLocale(config.languages);
|
const langOf = byAppleLocale(config.languages);
|
||||||
|
|
@ -119,12 +121,17 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (!lang) { warn('apple', `${locale}: no language with apple: "${locale}", skipped`); continue; }
|
if (!lang) { warn('apple', `${locale}: no language with apple: "${locale}", skipped`); continue; }
|
||||||
tasks.push(async () => {
|
tasks.push(async () => {
|
||||||
const sets = await c.all(`/v1/appStoreVersionLocalizations/${loc.id}/appScreenshotSets`);
|
const sets = await c.all(`/v1/appStoreVersionLocalizations/${loc.id}/appScreenshotSets`);
|
||||||
for (const [dir, type] of Object.entries(displaySets(config.apple, platform))) {
|
for (const [dir, type] of Object.entries(ctx.args.has('duo-only') ? {} : displaySets(config.apple, platform))) {
|
||||||
const d = join(src, lang.id, dir);
|
const d = join(src, lang.id, dir);
|
||||||
const files = numberedImages(d).filter(f => f.endsWith('.png')).slice(0, 10);
|
const files = numberedImages(d).filter(f => f.endsWith('.png')).slice(0, 10);
|
||||||
if (!existsSync(d) || !files.length) { warn('apple', `${locale}: nothing in ${d}, skipped`); continue; }
|
if (!existsSync(d) || !files.length) { warn('apple', `${locale}: nothing in ${d}, skipped`); continue; }
|
||||||
await syncSet(loc.id, sets, type, files, `${locale} ${type}`);
|
await syncSet(loc.id, sets, type, files, `${locale} ${type}`);
|
||||||
}
|
}
|
||||||
|
if (duo.length && duoGroupId) {
|
||||||
|
const files = duo.flatMap(dir => numberedImages(join(src, lang.id, dir)).filter(f => f.endsWith('.png')));
|
||||||
|
if (!files.length) warn('apple', `${locale}: nothing in ${duo.map(d => join(src, lang.id, d)).join(' or ')}, iPhone Duo skipped`);
|
||||||
|
else await syncDuo(c, { appId, group: duoGroupId.id, limit: duoGroupId.limit, loc, files, dry: ctx.args.has('dry') }).catch((e: Error) => { warn('apple', `${locale} iPhone Duo: ${e.message}`); process.exitCode = 1; });
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
log('apple', `${tasks.length} locales, ${jobs} in parallel`);
|
log('apple', `${tasks.length} locales, ${jobs} in parallel`);
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ import { BUILD_WAIT_EXIT, type BuildSeen, expireCandidates, planExpire, validHin
|
||||||
import { parseDuration } from '../lib/release';
|
import { parseDuration } from '../lib/release';
|
||||||
import {
|
import {
|
||||||
type ApiBuild, betaDescriptions, betaReadiness, betaReviewReq, buildsWithVersion, getsAllBuilds, type Group, groupFromApi, inviteReq, maskEmail,
|
type ApiBuild, betaDescriptions, betaReadiness, betaReviewReq, buildsWithVersion, getsAllBuilds, type Group, groupFromApi, inviteReq, maskEmail,
|
||||||
parseTesters, pickBuild, planBetaInfo, planBetaReviewDetail, planDistribute, planGroups, planTesters, planWhatToTest, unknownGroupMessage, whatToTestFromListing,
|
installableBuild, noInstallableBuildHint, noInstallableBuilds409, parseTesters, pickBuild, planBetaInfo, planBetaReviewDetail, planDistribute, planGroups, planTesters, planWhatToTest, unknownGroupMessage, whatToTestFromListing,
|
||||||
} from '../lib/testflight';
|
} from '../lib/testflight';
|
||||||
import { type Asc, ascClient, type J } from './asc';
|
import { type Asc, ascClient, type J } from './asc';
|
||||||
import { describeReq, execute, type Req } from './jsonapi';
|
import { describeReq, execute, type Req } from './jsonapi';
|
||||||
|
|
@ -37,8 +37,8 @@ const TAG = 'testflight';
|
||||||
const USAGE = 'usage: storebound apple testflight status | groups [sync] | testers | what-to-test --build N | info | distribute --build N --group <names> | wait --build N | expire --keep N | --older-than D';
|
const USAGE = 'usage: storebound apple testflight status | groups [sync] | testers | what-to-test --build N | info | distribute --build N --group <names> | wait --build N | expire --keep N | --older-than D';
|
||||||
|
|
||||||
/** The state of build `number` (of `marketing` version) right now; found: false while App Store Connect does not list it. */
|
/** The state of build `number` (of `marketing` version) right now; found: false while App Store Connect does not list it. */
|
||||||
async function seeBuild(c: Asc, appId: string, number: string, marketing?: string): Promise<BuildSeen & { version?: string }> {
|
async function seeBuild(c: Asc, appId: string, number: string, marketing?: string, platform = 'IOS'): Promise<BuildSeen & { version?: string }> {
|
||||||
const q = new URLSearchParams({ 'filter[app]': appId, 'filter[version]': number, 'filter[preReleaseVersion.platform]': 'IOS', include: 'preReleaseVersion,buildBetaDetail', limit: '50' });
|
const q = new URLSearchParams({ 'filter[app]': appId, 'filter[version]': number, 'filter[preReleaseVersion.platform]': platform, include: 'preReleaseVersion,buildBetaDetail', limit: '50' });
|
||||||
if (marketing) q.set('filter[preReleaseVersion.version]', marketing);
|
if (marketing) q.set('filter[preReleaseVersion.version]', marketing);
|
||||||
const resp = await c.asc('GET', `/v1/builds?${q}`);
|
const resp = await c.asc('GET', `/v1/builds?${q}`);
|
||||||
const hits = buildsWithVersion(resp).filter(b => b.attributes.version === number && (!marketing || b.marketing === marketing));
|
const hits = buildsWithVersion(resp).filter(b => b.attributes.version === number && (!marketing || b.marketing === marketing));
|
||||||
|
|
@ -54,13 +54,13 @@ export interface BuildWait { outcome: WaitOutcome; timedOut: boolean; seen: Buil
|
||||||
* Polls build `number` until processing ends (VALID, or FAILED / INVALID) or `timeoutMs` passes; logs each state change.
|
* Polls build `number` until processing ends (VALID, or FAILED / INVALID) or `timeoutMs` passes; logs each state change.
|
||||||
* `once` reads the state a single time. Shared by `testflight wait` and `apple upload` (which waits after the upload).
|
* `once` reads the state a single time. Shared by `testflight wait` and `apple upload` (which waits after the upload).
|
||||||
*/
|
*/
|
||||||
export async function waitForBuild(c: Asc, appId: string, number: string, o: { marketing?: string; timeoutMs: number; once?: boolean; tag?: string } & HeartbeatOptions): Promise<BuildWait> {
|
export async function waitForBuild(c: Asc, appId: string, number: string, o: { marketing?: string; platform?: 'IOS' | 'MAC_OS'; timeoutMs: number; once?: boolean; tag?: string } & HeartbeatOptions): Promise<BuildWait> {
|
||||||
const started = Date.now();
|
const started = Date.now();
|
||||||
let delay: number | null = null, last = '';
|
let delay: number | null = null, last = '';
|
||||||
// polls are up to 2 minutes apart: a heartbeat in between says the wait is alive
|
// polls are up to 2 minutes apart: a heartbeat in between says the wait is alive
|
||||||
const beat = o.once ? null : heartbeat(ms => log(o.tag ?? TAG, `still waiting for build ${number}: ${last || 'first check'}, ${elapsed(ms)} of ${elapsed(o.timeoutMs)}`), o);
|
const beat = o.once ? null : heartbeat(ms => log(o.tag ?? TAG, `still waiting for build ${number}: ${last || 'first check'}, ${elapsed(ms)} of ${elapsed(o.timeoutMs)}`), o);
|
||||||
try { for (;;) {
|
try { for (;;) {
|
||||||
const seen = await seeBuild(c, appId, number, o.marketing);
|
const seen = await seeBuild(c, appId, number, o.marketing, o.platform);
|
||||||
const outcome = waitOutcome(seen);
|
const outcome = waitOutcome(seen);
|
||||||
const line = outcome === 'missing' ? 'not listed yet (App Store Connect lists it once processing starts)' : `${seen.processingState}${seen.internal ? `, internal ${seen.internal}` : ''}`;
|
const line = outcome === 'missing' ? 'not listed yet (App Store Connect lists it once processing starts)' : `${seen.processingState}${seen.internal ? `, internal ${seen.internal}` : ''}`;
|
||||||
if (line !== last) { log(o.tag ?? TAG, `build ${number}${seen.version ? ` (${seen.version})` : ''}: ${line} [${Math.round((Date.now() - started) / 60_000)} min]`); last = line; }
|
if (line !== last) { log(o.tag ?? TAG, `build ${number}${seen.version ? ` (${seen.version})` : ''}: ${line} [${Math.round((Date.now() - started) / 60_000)} min]`); last = line; }
|
||||||
|
|
@ -113,6 +113,17 @@ async function findBuild(c: Asc, appId: string, number: string, marketing?: stri
|
||||||
return { ...b, detail };
|
return { ...b, detail };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Whether the group has a build its testers can install now (past Beta App Review for an external group). An internal
|
||||||
|
* all-builds group has every build of the app. */
|
||||||
|
async function groupHasInstallableBuild(c: Asc, appId: string, g: Group): Promise<boolean> {
|
||||||
|
const builds = getsAllBuilds(g) ? await c.all(`/v1/builds?filter[app]=${appId}&limit=200`) : await c.all(`/v1/betaGroups/${g.id}/builds?limit=200`);
|
||||||
|
for (const b of builds) {
|
||||||
|
const detail = (await c.maybe(`/v1/builds/${b.id}/buildBetaDetail`))?.data?.attributes ?? null;
|
||||||
|
if (installableBuild(b, detail, g.internal)) return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
export async function run(ctx: Ctx): Promise<void> {
|
export async function run(ctx: Ctx): Promise<void> {
|
||||||
const { config, root, resolve } = ctx.loaded;
|
const { config, root, resolve } = ctx.loaded;
|
||||||
const a = ctx.args;
|
const a = ctx.args;
|
||||||
|
|
@ -193,9 +204,35 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
await execute(c.asc, reqs, { dry, tag: TAG });
|
await execute(c.asc, reqs, { dry, tag: TAG });
|
||||||
if (a.has('invite')) {
|
if (a.has('invite')) {
|
||||||
const fresh = new Map((await c.all(`/v1/betaTesters?filter[apps]=${appId}&limit=200`)).map((t: J) => [String(t.attributes.email ?? '').toLowerCase(), t] as const));
|
const fresh = new Map((await c.all(`/v1/betaTesters?filter[apps]=${appId}&limit=200`)).map((t: J) => [String(t.attributes.email ?? '').toLowerCase(), t] as const));
|
||||||
const pending = want.map(t => fresh.get(t.email)).filter((t): t is J => !!t && ['NOT_INVITED', 'INVITED'].includes(t.attributes.state));
|
// an invitation needs a build the tester can install; without one Apple answers 409 NO_INSTALLABLE_BUILDS (seen live
|
||||||
if (pending.length && await confirm(ctx, `(Re)send the TestFlight invitation email to ${pending.length} tester(s)?`))
|
// on a new external group): add the tester, skip the invite, say when it can go out
|
||||||
await execute(c.asc, pending.map(t => inviteReq(appId, t.id, maskEmail(String(t.attributes.email)))), { dry: false, tag: TAG });
|
const installable = new Map<string, boolean>();
|
||||||
|
const ready: { t: J; groups: string[] }[] = [], waiting = new Set<string>();
|
||||||
|
let waitingTesters = 0;
|
||||||
|
for (const w of want) {
|
||||||
|
const t = fresh.get(w.email);
|
||||||
|
if (!t || !['NOT_INVITED', 'INVITED'].includes(t.attributes.state)) continue;
|
||||||
|
const own = gs.filter(g => w.groups.includes(g.name));
|
||||||
|
for (const g of own) if (!installable.has(g.id)) installable.set(g.id, await groupHasInstallableBuild(c, appId, g));
|
||||||
|
if (own.some(g => installable.get(g.id))) ready.push({ t, groups: own.map(g => g.name) });
|
||||||
|
else { waitingTesters++; for (const g of own) waiting.add(g.name); }
|
||||||
|
}
|
||||||
|
if (waitingTesters) {
|
||||||
|
const msg = `${waitingTesters} ${noInstallableBuildHint([...waiting])}`;
|
||||||
|
warn(TAG, msg);
|
||||||
|
|
||||||
|
}
|
||||||
|
if (ready.length && await confirm(ctx, `(Re)send the TestFlight invitation email to ${ready.length} tester(s)?`)) {
|
||||||
|
for (const { t, groups } of ready) {
|
||||||
|
try { await execute(c.asc, [inviteReq(appId, t.id, maskEmail(String(t.attributes.email)))], { dry: false, tag: TAG }); }
|
||||||
|
catch (e) {
|
||||||
|
if (!noInstallableBuilds409(e)) throw e;
|
||||||
|
const msg = `1 ${noInstallableBuildHint(groups)}`;
|
||||||
|
warn(TAG, msg);
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
done(TAG, 'testers done');
|
done(TAG, 'testers done');
|
||||||
return;
|
return;
|
||||||
|
|
@ -282,6 +319,16 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (a.has('submit-review') && review) log(TAG, `beta review: already submitted (${review.attributes?.betaReviewState ?? '?'})`);
|
if (a.has('submit-review') && review) log(TAG, `beta review: already submitted (${review.attributes?.betaReviewState ?? '?'})`);
|
||||||
if (external.length && !a.has('submit-review') && b.detail?.externalBuildState === 'READY_FOR_BETA_SUBMISSION')
|
if (external.length && !a.has('submit-review') && b.detail?.externalBuildState === 'READY_FOR_BETA_SUBMISSION')
|
||||||
warn(TAG, 'external testers only get the build after Beta App Review: add --submit-review (asks first) or submit it in App Store Connect');
|
warn(TAG, 'external testers only get the build after Beta App Review: add --submit-review (asks first) or submit it in App Store Connect');
|
||||||
|
// Beta App Review refuses a build whose app has no beta localization in its primary locale (422
|
||||||
|
// MISSING_BETA_APP_LOCALIZATION): said before the submit, in the dry run too
|
||||||
|
if (wantsReview) {
|
||||||
|
const primary = String((await c.maybe(`/v1/apps/${appId}?fields[apps]=primaryLocale`))?.data?.attributes?.primaryLocale ?? '');
|
||||||
|
const have = (await c.all(`/v1/apps/${appId}/betaAppLocalizations?limit=200`)).map((l: J) => String(l.attributes.locale));
|
||||||
|
if (primary && !have.includes(primary)) {
|
||||||
|
const msg = `Beta App Review needs test information in the app's primary locale ${primary} (has: ${have.join(', ') || 'none'}): add it to apple.testflight.description (key ${primary} or its language id), then storebound apple testflight info`;
|
||||||
|
if (dry) warn(TAG, msg); else throw new Error(msg);
|
||||||
|
}
|
||||||
|
}
|
||||||
if (dry) {
|
if (dry) {
|
||||||
await execute(c.asc, [...reqs, ...(wantsReview ? [betaReviewReq(b.id)] : [])], { dry, tag: TAG });
|
await execute(c.asc, [...reqs, ...(wantsReview ? [betaReviewReq(b.id)] : [])], { dry, tag: TAG });
|
||||||
done(TAG, 'distribute checked (dry run)');
|
done(TAG, 'distribute checked (dry run)');
|
||||||
|
|
@ -293,6 +340,12 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (await confirm(ctx, `Submit build ${number} to Beta App Review now? Apple reviews it for external testing (Test Information must be complete: storebound apple testflight info).`))
|
if (await confirm(ctx, `Submit build ${number} to Beta App Review now? Apple reviews it for external testing (Test Information must be complete: storebound apple testflight info).`))
|
||||||
await execute(c.asc, [betaReviewReq(b.id)], { dry: false, tag: TAG });
|
await execute(c.asc, [betaReviewReq(b.id)], { dry: false, tag: TAG });
|
||||||
}
|
}
|
||||||
|
// testers added to an external group but not invited yet: the invitation needs a build past Beta App Review
|
||||||
|
if (a.has('submit-review')) {
|
||||||
|
const waiting: string[] = [];
|
||||||
|
for (const g of external) if ((await c.all(`/v1/betaGroups/${g.id}/betaTesters?limit=200`)).some((t: J) => t.attributes.state === 'NOT_INVITED')) waiting.push(g.name);
|
||||||
|
if (waiting.length) { log(TAG, noInstallableBuildHint(waiting)); }
|
||||||
|
}
|
||||||
const added = target.filter(g => reqs.some(r => r.path.includes(`/betaGroups/${g.id}/`))).map(g => g.name);
|
const added = target.filter(g => reqs.some(r => r.path.includes(`/betaGroups/${g.id}/`))).map(g => g.name);
|
||||||
done(TAG, `build ${number}: ${added.length ? `added to ${added.join(', ')}` : `already available to ${target.map(g => g.name).join(', ')}`}`);
|
done(TAG, `build ${number}: ${added.length ? `added to ${added.join(', ')}` : `already available to ${target.map(g => g.name).join(', ')}`}`);
|
||||||
return;
|
return;
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
// Upload an IPA to App Store Connect and wait until Apple has processed the build.
|
// Upload an IPA to App Store Connect and wait until Apple has processed the build.
|
||||||
// storebound apple upload [<app.ipa>] [--build N] [--allow-existing] [--via api|altool] [--no-wait] [--timeout 60m] [--pre-check "<cmd with {file}>"] [--evidence <path.json>] [--dry] [--yes] [--json]
|
// storebound apple upload [<app.ipa>] [--out D] [--build N] [--allow-existing] [--via api|altool] [--no-wait] [--timeout 60m] [--pre-check "<cmd with {file}>"] [--evidence <path.json>] [--dry] [--yes] [--json]
|
||||||
// storebound apple upload <App.pkg> --platform macos [...] (Mac App Store .pkg from apple build --platform macos --tauri; platform MAC_OS, uti com.apple.pkg; altool gets --type macos; no SDK / privacy-manifest check)
|
// storebound apple upload <App.pkg> --platform macos [...] (Mac App Store .pkg from apple build --platform macos --tauri; platform MAC_OS, uti com.apple.pkg; altool gets --type macos; no SDK / privacy-manifest check)
|
||||||
// Default IPA: the newest in <apple.build.out or build/ios>/export (and its <version>-<build>/ folders), or with
|
// Default IPA: the newest in <--out>/export, else the last apple build's <out>/export (.storebound/last-apple-build.json,
|
||||||
|
// so a build with --out is found), then <apple.build.out or build/ios>/export (and its <version>-<build>/ folders), or with
|
||||||
// --build N the one with that build number. The bundle id, version and build number come from the IPA's Info.plist.
|
// --build N the one with that build number. The bundle id, version and build number come from the IPA's Info.plist.
|
||||||
// An IPA whose build number is already on App Store Connect fails with exit 1 (a stale IPA left by a failed
|
// An IPA whose build number is already on App Store Connect fails with exit 1 (a stale IPA left by a failed
|
||||||
// `apple build`, pitfall 53); only --allow-existing (flows that resume after a finished upload) re-checks it instead. Before any network call every PrivacyInfo.xcprivacy in the IPA
|
// `apple build`, pitfall 53); only --allow-existing (flows that resume after a finished upload) re-checks it instead. Before any network call every PrivacyInfo.xcprivacy in the IPA
|
||||||
|
|
@ -27,7 +28,7 @@ import type { Ctx } from '../lib/ctx';
|
||||||
import { confirm, need } from '../lib/ctx';
|
import { confirm, need } from '../lib/ctx';
|
||||||
import { done, log, printJson, warn } from '../lib/log';
|
import { done, log, printJson, warn } from '../lib/log';
|
||||||
import { compareBuild, nextBuildNumber, nextPollDelay, parseDuration, WAIT_EXIT } from '../lib/release';
|
import { compareBuild, nextBuildNumber, nextPollDelay, parseDuration, WAIT_EXIT } from '../lib/release';
|
||||||
import { altoolArgs, buildUploadReqs, exportedIpas, ipaInfo, ipaVersionProblem, showCmd, UPLOAD_DONE, uploadProblems } from '../lib/xcode';
|
import { altoolArgs, buildUploadReqs, exportedIpas, ipaInfo, ipaVersionProblem, readLastBuild, remoteBuildSession, showCmd, UPLOAD_DONE, uploadProblems, uploadSearchDirs } from '../lib/xcode';
|
||||||
import { bundleTrackingIssues, ipaManifests } from '../lib/privacy-files';
|
import { bundleTrackingIssues, ipaManifests } from '../lib/privacy-files';
|
||||||
import { BUILD_WAIT_EXIT } from '../lib/build-ops';
|
import { BUILD_WAIT_EXIT } from '../lib/build-ops';
|
||||||
import { type Asc, ascClient, type J } from './asc';
|
import { type Asc, ascClient, type J } from './asc';
|
||||||
|
|
@ -50,6 +51,9 @@ function stop(legacy: number, message: string): never {
|
||||||
|
|
||||||
const TAG = 'upload';
|
const TAG = 'upload';
|
||||||
|
|
||||||
|
/** Test hook: heartbeat options (short interval, manual ticker) for the reads, the upload and the processing wait. */
|
||||||
|
export const hooks: { heartbeat?: HeartbeatOptions } = {};
|
||||||
|
|
||||||
function md5File(path: string): string {
|
function md5File(path: string): string {
|
||||||
const h = rt.hasher('md5');
|
const h = rt.hasher('md5');
|
||||||
const fd = openSync(path, 'r');
|
const fd = openSync(path, 'r');
|
||||||
|
|
@ -238,18 +242,32 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const macos = parsePlatform(a.get('platform')) === 'MAC_OS';
|
const macos = parsePlatform(a.get('platform')) === 'MAC_OS';
|
||||||
let ipa = a._.find(x => x.endsWith('.ipa') || x.endsWith('.pkg'));
|
let ipa = a._.find(x => x.endsWith('.ipa') || x.endsWith('.pkg'));
|
||||||
if (!ipa) {
|
if (!ipa) {
|
||||||
const dir = join(resolve(config.apple?.build?.out ?? 'build/ios'), 'export');
|
const last = readLastBuild(root);
|
||||||
let found = exportedIpas(dir);
|
const flagOut = a.get('out');
|
||||||
if (want) found = found.filter(f => { try { return ipaInfo(f).build === want; } catch { return false; } });
|
const dirs = uploadSearchDirs({ flagOut: flagOut ? resolve(flagOut) : undefined, lastOut: last?.out, configOut: resolve(config.apple?.build?.out ?? 'build/ios') });
|
||||||
|
let found: string[] = [];
|
||||||
|
for (const dir of dirs) {
|
||||||
|
found = exportedIpas(dir);
|
||||||
|
if (want) found = found.filter(f => { try { return ipaInfo(f).build === want; } catch { return false; } });
|
||||||
|
if (found[0]) break;
|
||||||
|
}
|
||||||
if (!found[0] && macos) throw new Error('usage: storebound apple upload <app.pkg> --platform macos (storebound apple build --platform macos --tauri <src-tauri> makes one)');
|
if (!found[0] && macos) throw new Error('usage: storebound apple upload <app.pkg> --platform macos (storebound apple build --platform macos --tauri <src-tauri> makes one)');
|
||||||
if (!found[0]) throw new Error(`usage: storebound apple upload <app.ipa> (no ${want ? `build ${want} ` : ''}IPA in ${relative(root, dir)}; storebound apple build makes one)`);
|
if (!found[0]) {
|
||||||
|
const lastHint = last && !existsSync(last.ipa) ? `; the last apple build (${last.build}) wrote ${last.ipa}, which is gone` : last ? `; the last apple build (${last.build}) is ${last.ipa}` : '';
|
||||||
|
throw new Error(`usage: storebound apple upload <app.ipa> (no ${want ? `build ${want} ` : ''}IPA in ${dirs.map(d => relative(root, d) || '.').join(', ')}${lastHint}; pass the IPA, --out <the build's --out>, or run storebound apple build)`);
|
||||||
|
}
|
||||||
ipa = found[0];
|
ipa = found[0];
|
||||||
} else ipa = resolve(ipa);
|
} else ipa = resolve(ipa);
|
||||||
shipPhase('verify', `checking ${relative(root, ipa)}`);
|
shipPhase('verify', `checking ${relative(root, ipa)}`);
|
||||||
const isPkg = ipa.endsWith('.pkg');
|
const isPkg = ipa.endsWith('.pkg');
|
||||||
|
log(TAG, `${relative(root, ipa)}: reading ${isPkg ? 'the package (pkgutil)' : 'the IPA'} (${mb(statSync(ipa).size)})`);
|
||||||
|
// over SSH (no GUI session) anything that touches the login keychain can wait for a prompt nobody sees: say so up front
|
||||||
|
const remote = process.platform === 'darwin' ? remoteBuildSession(process.env, rt.spawnSync(['launchctl', 'managername'], { timeout: 5000 }).stdout.toString().trim()) : null;
|
||||||
|
if (remote) warn(TAG, `${remote}: the upload itself uses the App Store Connect API key (no keychain, no prompt), but pkgutil / altool can stall on a keychain or GUI prompt nobody sees here; every step has a timeout. If it stalls, run it in the Mac's logged-in GUI session (see storebound apple build --help, --allow-ssh)`);
|
||||||
const platform: 'IOS' | 'MAC_OS' = isPkg ? 'MAC_OS' : 'IOS';
|
const platform: 'IOS' | 'MAC_OS' = isPkg ? 'MAC_OS' : 'IOS';
|
||||||
if (macos && !isPkg) throw new Error('--platform macos uploads a signed .pkg (storebound apple build --platform macos --tauri <src-tauri>), not an .ipa');
|
if (macos && !isPkg) throw new Error('--platform macos uploads a signed .pkg (storebound apple build --platform macos --tauri <src-tauri>), not an .ipa');
|
||||||
const info: ReturnType<typeof ipaInfo> = isPkg ? pkgInfo(ipa, bundleId) : ipaInfo(ipa);
|
const info: ReturnType<typeof ipaInfo> = isPkg ? pkgInfo(ipa, bundleId, { say: m => log(TAG, m) }) : ipaInfo(ipa);
|
||||||
|
log(TAG, `${relative(root, ipa)}: ${info.bundleId} ${info.version} (${info.build})`);
|
||||||
shipReport({ version: info.version, build: info.build, url: consoleUrl('asc.testflight') });
|
shipReport({ version: info.version, build: info.build, url: consoleUrl('asc.testflight') });
|
||||||
if (want && info.build !== want) throw new Error(`${relative(root, ipa)} is build ${info.build}, not ${want} (--build): did the last apple build fail?`);
|
if (want && info.build !== want) throw new Error(`${relative(root, ipa)} is build ${info.build}, not ${want} (--build): did the last apple build fail?`);
|
||||||
if (info.bundleId !== bundleId) throw new Error(`${relative(root, ipa)} is ${info.bundleId}, the config says ${bundleId}`);
|
if (info.bundleId !== bundleId) throw new Error(`${relative(root, ipa)} is ${info.bundleId}, the config says ${bundleId}`);
|
||||||
|
|
@ -267,18 +285,21 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const wait = !a.has('no-wait');
|
const wait = !a.has('no-wait');
|
||||||
const timeout = parseDuration(a.str('timeout', '60m'));
|
const timeout = parseDuration(a.str('timeout', '60m'));
|
||||||
|
|
||||||
|
log(TAG, `asking App Store Connect about ${bundleId}: the app, the editable version, the builds, earlier uploads of build ${info.build}`);
|
||||||
const c = await ascClient(root, bundleId, config.apple?.appId);
|
const c = await ascClient(root, bundleId, config.apple?.appId);
|
||||||
const appId = await c.app();
|
// every read has its own timeout and retries; the heartbeat says the run is alive while one of them waits
|
||||||
// the IPA must belong to the version train being prepared (the editable App Store version): MARKETING_VERSION 1.0
|
const { appId, editable, builds, already } = await withHeartbeat(ms => log(TAG, `still reading App Store Connect, ${elapsed(ms)}`), async () => {
|
||||||
// from a project that ignored the intended version otherwise lands in the wrong train
|
const appId = await c.app();
|
||||||
const editable = await c.editableVersion(platform).catch(() => null);
|
// the IPA must belong to the version train being prepared (the editable App Store version): MARKETING_VERSION 1.0
|
||||||
const trainWhy = ipaVersionProblem(info.version, editable?.attributes?.versionString as string | undefined, 'the editable App Store version');
|
// from a project that ignored the intended version otherwise lands in the wrong train
|
||||||
if (trainWhy) { if (a.has('allow-version-mismatch')) warn(TAG, trainWhy); else throw new Error(`${relative(root, ipa)}: not uploaded, ${trainWhy}`); }
|
const editable = await c.editableVersion(platform).catch(() => null);
|
||||||
const builds = await c.all(`/v1/builds?filter[app]=${appId}${isPkg ? '&filter[preReleaseVersion.platform]=MAC_OS' : ''}&limit=200&fields[builds]=version,processingState`);
|
const builds = await c.all(`/v1/builds?filter[app]=${appId}&limit=200&fields[builds]=version,processingState`);
|
||||||
|
// the same IPA uploaded by an earlier run: nothing to send again, only the wait
|
||||||
|
const already = via === 'api' && !dry ? (await uploadsOf(c, appId, info, platform).catch(() => [])).find((u: J) => u.attributes?.state?.state === 'COMPLETE') : undefined;
|
||||||
|
return { appId, editable, builds, already };
|
||||||
|
}, hooks.heartbeat);
|
||||||
const numbers = builds.map(b => String(b.attributes.version));
|
const numbers = builds.map(b => String(b.attributes.version));
|
||||||
const next = nextBuildNumber(numbers);
|
const next = nextBuildNumber(numbers);
|
||||||
// the same IPA uploaded by an earlier run: nothing to send again, only the wait
|
|
||||||
const already = via === 'api' && !dry ? (await uploadsOf(c, appId, info, platform).catch(() => [])).find((u: J) => u.attributes?.state?.state === 'COMPLETE') : undefined;
|
|
||||||
const onAsc = builds.find(b => String(b.attributes.version) === info.build);
|
const onAsc = builds.find(b => String(b.attributes.version) === info.build);
|
||||||
const decision = existingBuild({ ipa: relative(root, ipa), build: info.build, onAsc: !!onAsc, state: onAsc?.attributes?.processingState, uploadComplete: !!already, allowExisting: a.has('allow-existing'), next });
|
const decision = existingBuild({ ipa: relative(root, ipa), build: info.build, onAsc: !!onAsc, state: onAsc?.attributes?.processingState, uploadComplete: !!already, allowExisting: a.has('allow-existing'), next });
|
||||||
// the ship-step contract: a build number App Store Connect has already is "nothing to do" (exit 7), never a second upload
|
// the ship-step contract: a build number App Store Connect has already is "nothing to do" (exit 7), never a second upload
|
||||||
|
|
@ -290,14 +311,18 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (decision instanceof Error) throw decision;
|
if (decision instanceof Error) throw decision;
|
||||||
|
log(TAG, `build ${info.build} is not on App Store Connect (next free: ${next})`);
|
||||||
if (decision === 'recheck') {
|
if (decision === 'recheck') {
|
||||||
log(TAG, `build ${info.version} (${info.build}) is on App Store Connect already${already ? ` (build upload ${already.id})` : ''}; --allow-existing: not sending it again`);
|
log(TAG, `build ${info.version} (${info.build}) is on App Store Connect already${already ? ` (build upload ${already.id})` : ''}; --allow-existing: not sending it again`);
|
||||||
if (!wait) { if (json) printJson({ ...{ ipa: relative(root, ipa), version: info.version, build: info.build }, uploaded: true, alreadyUploaded: true }); done(TAG, `build ${info.build} already uploaded`); return; }
|
if (!wait) { if (json) printJson({ ...{ ipa: relative(root, ipa), version: info.version, build: info.build }, uploaded: true, alreadyUploaded: true }); done(TAG, `build ${info.build} already uploaded`); return; }
|
||||||
const r = await waitForBuild(c, appId, info.build, { marketing: info.version, timeoutMs: timeout, tag: TAG });
|
const r = await waitForBuild(c, appId, info.build, { marketing: info.version, platform, timeoutMs: timeout, tag: TAG, ...hooks.heartbeat });
|
||||||
if (json) printJson({ ipa: relative(root, ipa), version: info.version, build: info.build, uploaded: true, alreadyUploaded: true, processingState: r.seen.processingState ?? null });
|
if (json) printJson({ ipa: relative(root, ipa), version: info.version, build: info.build, uploaded: true, alreadyUploaded: true, processingState: r.seen.processingState ?? null });
|
||||||
if (r.outcome === 'valid') { done(TAG, waitMessage(info.build, r)); return; }
|
if (r.outcome === 'valid') { done(TAG, waitMessage(info.build, r)); return; }
|
||||||
stop(r.outcome === 'failed' ? BUILD_WAIT_EXIT.failed : BUILD_WAIT_EXIT.timeout, waitMessage(info.build, r));
|
stop(r.outcome === 'failed' ? BUILD_WAIT_EXIT.failed : BUILD_WAIT_EXIT.timeout, waitMessage(info.build, r));
|
||||||
}
|
}
|
||||||
|
// (a build number App Store Connect has already ends above, before this: the clearer message)
|
||||||
|
const trainWhy = ipaVersionProblem(info.version, editable?.attributes?.versionString as string | undefined, 'the editable App Store version');
|
||||||
|
if (trainWhy) { if (a.has('allow-version-mismatch')) warn(TAG, trainWhy); else throw new Error(`${relative(root, ipa)}: not uploaded, ${trainWhy}`); }
|
||||||
if (numbers.length && compareBuild(info.build, next) < 0) warn(TAG, `build ${info.build} is lower than the highest uploaded one (next free: ${next}); Apple accepts it only if this version train has no higher build`);
|
if (numbers.length && compareBuild(info.build, next) < 0) warn(TAG, `build ${info.build} is lower than the highest uploaded one (next free: ${next}); Apple accepts it only if this version train has no higher build`);
|
||||||
const reqs = buildUploadReqs(appId, info, basename(ipa), size, platform);
|
const reqs = buildUploadReqs(appId, info, basename(ipa), size, platform);
|
||||||
const plan = via === 'api'
|
const plan = via === 'api'
|
||||||
|
|
@ -317,14 +342,14 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
shipPhase('upload', `uploading ${mb(size)} via ${via}`, 0);
|
shipPhase('upload', `uploading ${mb(size)} via ${via}`, 0);
|
||||||
log(TAG, `${relative(root, ipa)}: ${info.bundleId} ${info.version} (${info.build}), ${mb(size)}, via ${via}, timeout ${a.str('timeout', '60m')}`);
|
log(TAG, `${relative(root, ipa)}: ${info.bundleId} ${info.version} (${info.build}), ${mb(size)}, via ${via}, timeout ${a.str('timeout', '60m')}`);
|
||||||
if (via === 'api') {
|
if (via === 'api') {
|
||||||
try { await apiUpload(c, appId, ipa, info, deadline, {}, platform); } catch (e) { if ((e as { exit?: number }).exit) { warn(TAG, (e as Error).message); stop((e as { exit: number }).exit, (e as Error).message); } throw e; }
|
try { await apiUpload(c, appId, ipa, info, deadline, hooks.heartbeat ?? {}, platform); } catch (e) { if ((e as { exit?: number }).exit) { warn(TAG, (e as Error).message); stop((e as { exit: number }).exit, (e as Error).message); } throw e; }
|
||||||
} else {
|
} else {
|
||||||
try { await altoolUpload(root, ipa, deadline); } catch (e) { if ((e as { exit?: number }).exit) { warn(TAG, (e as Error).message); stop((e as { exit: number }).exit, (e as Error).message); } throw e; }
|
try { await altoolUpload(root, ipa, deadline, hooks.heartbeat); } catch (e) { if ((e as { exit?: number }).exit) { warn(TAG, (e as Error).message); stop((e as { exit: number }).exit, (e as Error).message); } throw e; }
|
||||||
}
|
}
|
||||||
if (!wait) { if (json) printJson({ ...summary, uploaded: true }); done(TAG, `build ${info.build} uploaded; storebound apple status shows when it is VALID`); return; }
|
if (!wait) { if (json) printJson({ ...summary, uploaded: true }); done(TAG, `build ${info.build} uploaded; storebound apple status shows when it is VALID`); return; }
|
||||||
// the same poll as `storebound apple testflight wait`, within what is left of --timeout
|
// the same poll as `storebound apple testflight wait`, within what is left of --timeout
|
||||||
shipPhase('processing', `waiting for App Store Connect to process build ${info.build}`);
|
shipPhase('processing', `waiting for App Store Connect to process build ${info.build}`);
|
||||||
const r = await waitForBuild(c, appId, info.build, { marketing: info.version, timeoutMs: Math.max(0, deadline - Date.now()), tag: TAG });
|
const r = await waitForBuild(c, appId, info.build, { marketing: info.version, platform, timeoutMs: Math.max(0, deadline - Date.now()), tag: TAG, ...hooks.heartbeat });
|
||||||
const state = r.timedOut || (r.outcome !== 'valid' && r.outcome !== 'failed') ? 'TIMEOUT' : r.seen.processingState ?? 'UNKNOWN';
|
const state = r.timedOut || (r.outcome !== 'valid' && r.outcome !== 'failed') ? 'TIMEOUT' : r.seen.processingState ?? 'UNKNOWN';
|
||||||
if (json) printJson({ ...summary, uploaded: true, processingState: state });
|
if (json) printJson({ ...summary, uploaded: true, processingState: state });
|
||||||
if (r.outcome === 'valid') { done(TAG, `${waitMessage(info.build, r)}. Then: apple testflight distribute --build ${info.build} --group <name> --dry`); return; }
|
if (r.outcome === 'valid') { done(TAG, `${waitMessage(info.build, r)}. Then: apple testflight distribute --build ${info.build} --group <name> --dry`); return; }
|
||||||
|
|
|
||||||
17
cli/check.ts
17
cli/check.ts
|
|
@ -16,7 +16,7 @@ import { type BundleManifest, bundleTrackingIssues, ipaManifests, projectSdkMani
|
||||||
import { trackingIssue } from './lib/privacy-manifest';
|
import { trackingIssue } from './lib/privacy-manifest';
|
||||||
import { type AsoFinding, auditAso } from './lib/aso';
|
import { type AsoFinding, auditAso } from './lib/aso';
|
||||||
import { draftLocales } from './lib/aso-intel';
|
import { draftLocales } from './lib/aso-intel';
|
||||||
import { appleName, playCodes } from './lib/config';
|
import { appleName, listingPathFor, playCodes } from './lib/config';
|
||||||
import { fieldsMentions } from './lib/cross-store';
|
import { fieldsMentions } from './lib/cross-store';
|
||||||
import { appBuildFile, pickGradle, versionSourceIssues, versionSourceMessage } from './lib/gradle';
|
import { appBuildFile, pickGradle, versionSourceIssues, versionSourceMessage } from './lib/gradle';
|
||||||
import { playConsoleReminders } from './lib/console-plan';
|
import { playConsoleReminders } from './lib/console-plan';
|
||||||
|
|
@ -38,6 +38,7 @@ import { iphoneDuoNote } from './shots/spec';
|
||||||
import { hitLine } from './lib/cross-store';
|
import { hitLine } from './lib/cross-store';
|
||||||
import { findFastlaneTraces, traceMessage } from './lib/fastlane-traces';
|
import { findFastlaneTraces, traceMessage } from './lib/fastlane-traces';
|
||||||
import { listingFileMentions } from './lib/listing-mentions';
|
import { listingFileMentions } from './lib/listing-mentions';
|
||||||
|
import { projectFamilies } from './lib/device-families';
|
||||||
|
|
||||||
/** The newest .ipa in a folder (apple build's export), or null. */
|
/** The newest .ipa in a folder (apple build's export), or null. */
|
||||||
function newestIpa(dir: string): string | null {
|
function newestIpa(dir: string): string | null {
|
||||||
|
|
@ -106,6 +107,12 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
try { const tr = findFastlaneTraces(dirname(path)); if (tr.length) for (const t of tr) note(traceMessage(t)); } catch (e) { warn('check', `fastlane traces: ${(e as Error).message}`); }
|
try { const tr = findFastlaneTraces(dirname(path)); if (tr.length) for (const t of tr) note(traceMessage(t)); } catch (e) { warn('check', `fastlane traces: ${(e as Error).message}`); }
|
||||||
// other platforms named in a store's text: App Store 2.3.10 / Play Metadata, a blocker (pitfall 77)
|
// other platforms named in a store's text: App Store 2.3.10 / Play Metadata, a blocker (pitfall 77)
|
||||||
try { for (const h of listingFileMentions(ctx.loaded)) problems.push(`other platform in ${hitLine(h)}`); } catch (e) { warn('check', `platform mentions: ${(e as Error).message}`); }
|
try { for (const h of listingFileMentions(ctx.loaded)) problems.push(`other platform in ${hitLine(h)}`); } catch (e) { warn('check', `platform mentions: ${(e as Error).message}`); }
|
||||||
|
if (config.apple?.macos?.listing) tryDo('appstore listing (macOS)', () => {
|
||||||
|
const copy = parseAppStoreListing(readFileSync(resolve(listingPathFor(config, 'macos')), 'utf8'));
|
||||||
|
const missing = config.languages.filter(l => l.apple && !copy[l.apple]).map(l => l.apple);
|
||||||
|
if (missing.length) note(`macOS appstore listing has no section for ${missing.join(', ')}`);
|
||||||
|
return `${Object.keys(copy).length} locales`;
|
||||||
|
});
|
||||||
// listing translation drafts (storebound listing translate): fine to keep working on, not to push unreviewed
|
// listing translation drafts (storebound listing translate): fine to keep working on, not to push unreviewed
|
||||||
for (const f of [config.apple ? resolve(config.apple.listing ?? 'store/appstore.md') : '', config.play ? resolve(config.play.listing ?? 'store/listing.md') : ''].filter(Boolean)) {
|
for (const f of [config.apple ? resolve(config.apple.listing ?? 'store/appstore.md') : '', config.play ? resolve(config.play.listing ?? 'store/listing.md') : ''].filter(Boolean)) {
|
||||||
if (!existsSync(f)) continue;
|
if (!existsSync(f)) continue;
|
||||||
|
|
@ -173,6 +180,14 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
note('shots.capture.auth signs in to a local stack with reviewDemoAccount, the account App Review gets from apple review-details: put the local demo sign-in in captureAuth in .storebound/credentials.json and use ${cred:<name>}'); }
|
note('shots.capture.auth signs in to a local stack with reviewDemoAccount, the account App Review gets from apple review-details: put the local demo sign-in in captureAuth in .storebound/credentials.json and use ${cred:<name>}'); }
|
||||||
const duo = iphoneDuoNote({ apple: !!config.apple, duo: !!config.apple?.iphoneDuo, play: !!config.play });
|
const duo = iphoneDuoNote({ apple: !!config.apple, duo: !!config.apple?.iphoneDuo, play: !!config.play });
|
||||||
if (duo?.level === 'info') { hints.push(duo.msg); log('check', `hint: ${duo.msg}`); } else if (duo) note(duo.msg);
|
if (duo?.level === 'info') { hints.push(duo.msg); log('check', `hint: ${duo.msg}`); } else if (duo) note(duo.msg);
|
||||||
|
// device families: offline only the project and the config can be compared; the live version's families need the store
|
||||||
|
if (config.apple) {
|
||||||
|
const proj = projectFamilies(ctx.loaded.root, config.apple.bundleId, config.apple.build?.project);
|
||||||
|
const iosOnly = !proj || !proj.families.ipad;
|
||||||
|
if (proj && proj.families.ipad && config.apple.ipad !== true) note(`${proj.file} builds for iPad (TARGETED_DEVICE_FAMILY ${proj.configurations.join(' / ')}) but apple.ipad is not true: iPad screenshots are not required or checked (set apple.ipad: true)`);
|
||||||
|
else if (proj && !proj.families.ipad && config.apple.ipad === true) note(`apple.ipad is true but ${proj.file} builds TARGETED_DEVICE_FAMILY ${proj.configurations.join(' / ')} (no iPad): set "1,2" or apple.ipad: false`);
|
||||||
|
else if (iosOnly && config.apple.ipad !== true) note(`device families: ${proj ? `iPhone only (apple.ipad not true, TARGETED_DEVICE_FAMILY ${proj.configurations.join(' / ')})` : 'no Xcode project found here'}, and the families of the live version are not known offline: if it supports iPad, Apple refuses an iPhone-only upload after the build (ITMS-90101). storebound validate and apple build compare with the store first`);
|
||||||
|
}
|
||||||
const creative = creativeNote(config, ctx.loaded.resolve(config.renders ?? config.shots?.out ?? 'store/renders'));
|
const creative = creativeNote(config, ctx.loaded.resolve(config.renders ?? config.shots?.out ?? 'store/renders'));
|
||||||
if (creative) { hints.push(creative); log('check', `hint: ${creative}`); }
|
if (creative) { hints.push(creative); log('check', `hint: ${creative}`); }
|
||||||
// the scaffolder's own placeholders would reach the stores as the app's copyright, contact and legal pages
|
// the scaffolder's own placeholders would reach the stores as the app's copyright, contact and legal pages
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ export const PLAIN: Record<string, [() => Promise<Plain>, string]> = {
|
||||||
'init': [() => import('./init'), 'copy the templates (config, listing, copy, declarations, privacy policy) into this project; --profile app|game|subscription-app (default app)'],
|
'init': [() => import('./init'), 'copy the templates (config, listing, copy, declarations, privacy policy) into this project; --profile app|game|subscription-app (default app)'],
|
||||||
'import': [() => import('./import'), 'fastlane [--dir fastlane] [--profile app|game|subscription-app] [--dry]: Appfile, deliver + supply metadata and screenshots -> config, store/*.md, shots frames (read-only on fastlane, never overwrites)'],
|
'import': [() => import('./import'), 'fastlane [--dir fastlane] [--profile app|game|subscription-app] [--dry]: Appfile, deliver + supply metadata and screenshots -> config, store/*.md, shots frames (read-only on fastlane, never overwrites)'],
|
||||||
'install': [() => import('./install'), 'skills + MCP server for --agent claude|codex|cursor|copilot|windsurf|gemini|opencode'],
|
'install': [() => import('./install'), 'skills + MCP server for --agent claude|codex|cursor|copilot|windsurf|gemini|opencode'],
|
||||||
'mcp': [async () => ({ run: async () => (await import('./mcp')).serve() }), 'stdio MCP server wrapping these commands (for any MCP-capable AI tool)'],
|
'mcp': [() => import('./mcp-cmd'), 'MCP server wrapping these commands (for any MCP-capable AI tool): stdio, or --http [--port 7787] [--roots <dirs>] [--auth token|introspect] for one server every session shares'],
|
||||||
'watch': [() => import('./watch'), 'store events for every app on this machine: rejected, approved, live, rollout halted, crash threshold, low reviews; loops every --every 15m or --once; sinks --notify os|ntfy|telegram|webhook|ingest; test sends a test event; --dry, --dir <folder>, --json (read-only on the stores)'],
|
'watch': [() => import('./watch'), 'store events for every app on this machine: rejected, approved, live, rollout halted, crash threshold, low reviews; loops every --every 15m or --once; sinks --notify os|ntfy|telegram|webhook|ingest; test sends a test event; --dry, --dir <folder>, --json (read-only on the stores)'],
|
||||||
'status': [() => import('./status'), '[--app <name|store id|folder>] [--json]: per platform the live and next version, build, track, review state and rollout %, without uploading (read-only; read by ship pipelines, docs/ship-step.md)'],
|
'status': [() => import('./status'), '[--app <name|store id|folder>] [--json]: per platform the live and next version, build, track, review state and rollout %, without uploading (read-only; read by ship pipelines, docs/ship-step.md)'],
|
||||||
'events': [() => import('./events'), '[--since 24h] [--app <name>] [--kind rejected] [--json]: the events watch recorded in ~/.storebound/events.jsonl (read-only)'],
|
'events': [() => import('./events'), '[--since 24h] [--app <name>] [--kind rejected] [--json]: the events watch recorded in ~/.storebound/events.jsonl (read-only)'],
|
||||||
|
|
@ -85,11 +85,11 @@ export const COMMANDS: Record<string, [() => Promise<Mod>, string]> = {
|
||||||
'apple listing': [() => import('./apple/listing'), 'version, build, name / subtitle / description / keywords per locale; pull [--write]: live texts back into the listing file (diff first); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
'apple listing': [() => import('./apple/listing'), 'version, build, name / subtitle / description / keywords per locale; pull [--write]: live texts back into the listing file (diff first); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
||||||
'apple screenshots': [() => import('./apple/screenshots'), '6.9" + 6.5" (+ 13" iPad) screenshots per locale; --variant <id>; --repair-stuck [--dry] (replace only screenshots not COMPLETE, at their positions); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
'apple screenshots': [() => import('./apple/screenshots'), '6.9" + 6.5" (+ 13" iPad) screenshots per locale; --variant <id>; --repair-stuck [--dry] (replace only screenshots not COMPLETE, at their positions); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
||||||
'apple appinfo': [() => import('./apple/appinfo'), 'categories, age rating, content rights, Free price, territories'],
|
'apple appinfo': [() => import('./apple/appinfo'), 'categories, age rating, content rights, Free price, territories'],
|
||||||
'apple review-details': [() => import('./apple/review-details'), 'App Review contact, demo account (from .storebound/, masked) + notes'],
|
'apple review-details': [() => import('./apple/review-details'), 'App Review contact, demo account (from .storebound/, masked) + notes; --platform ios|macos|tvos|visionos (macos: apple.macos.reviewNotes when set)'],
|
||||||
'apple status': [() => import('./apple/status'), 'versions, builds, IAPs, review submissions (--wait-review, --cancel-submission <id>); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
'apple status': [() => import('./apple/status'), 'versions, builds, IAPs, review submissions (--wait-review, --cancel-submission <id>); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
||||||
'apple creative-assets': [() => import('./apple/creative-assets'), 'Header and Search Results: product page header (21:9) and search results asset (3:2) per locale, or one universal 5244x2950 PNG; uploads to the Asset Library and places it once Apple approved it, reporting waiting ones per locale (MD5 upsert, safe to re-run); --add-for-review, --verify (read-only), --dry'],
|
'apple creative-assets': [() => import('./apple/creative-assets'), 'Header and Search Results: product page header (21:9) and search results asset (3:2) per locale, or one universal 5244x2950 PNG; uploads to the Asset Library and places it once Apple approved it, reporting waiting ones per locale (MD5 upsert, safe to re-run); --add-for-review, --verify (read-only), --dry'],
|
||||||
'apple previews': [() => import('./apple/previews'), 'app preview videos per locale (MD5-idempotent, poster frame time code); --dry'],
|
'apple previews': [() => import('./apple/previews'), 'app preview videos per locale (MD5-idempotent, poster frame time code); --dry'],
|
||||||
'apple release': [() => import('./apple/release'), 'phased release on|pause|resume|complete, --manual-release (asks first; --yes for an update of an app on sale, exit 7 when already released; the first-ever release is exit 3 OWNER_STEP unless --first-release); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
'apple release': [() => import('./apple/release'), 'phased release on|pause|resume|complete, --after-approval | --manual | --scheduled <date> (how an unapproved version goes live; exit 7 when already that type), --manual-release (asks first; --yes for an update of an app on sale, exit 7 when already released; the first-ever release is exit 3 OWNER_STEP unless --first-release); --platform ios|macos|tvos|visionos (default: the platform that has the version this needs; asks when several do)'],
|
||||||
'apple signing': [() => import('./apple/signing'), 'status | ensure: bundle id capabilities, distribution certificate (key kept in .storebound/signing), App Store profiles installed for Xcode; --dry, asks first'],
|
'apple signing': [() => import('./apple/signing'), 'status | ensure: bundle id capabilities, distribution certificate (key kept in .storebound/signing), App Store profiles installed for Xcode; --dry, asks first'],
|
||||||
'apple build': [() => import('./apple/build'), 'xcodebuild archive + exportArchive (ExportOptions.plist generated, next build number, API key signing); Capacitor, React Native, Flutter, Unity; --platform macos --tauri <src-tauri> [--path-free] builds a Tauri app for the Mac App Store (signed .app, sandbox entitlements, profile, productbuild .pkg); --dry'],
|
'apple build': [() => import('./apple/build'), 'xcodebuild archive + exportArchive (ExportOptions.plist generated, next build number, API key signing); Capacitor, React Native, Flutter, Unity; --platform macos --tauri <src-tauri> [--path-free] builds a Tauri app for the Mac App Store (signed .app, sandbox entitlements, profile, productbuild .pkg); --dry'],
|
||||||
'apple upload': [() => import('./apple/upload'), 'upload an IPA, or with --platform macos a signed .pkg (App Store Connect API build upload, or --via altool), build number checked, waits for processing; --dry, asks first'],
|
'apple upload': [() => import('./apple/upload'), 'upload an IPA, or with --platform macos a signed .pkg (App Store Connect API build upload, or --via altool), build number checked, waits for processing; --dry, asks first'],
|
||||||
|
|
|
||||||
|
|
@ -68,12 +68,17 @@
|
||||||
],
|
],
|
||||||
"apple build": [
|
"apple build": [
|
||||||
"allow-app-group-gap",
|
"allow-app-group-gap",
|
||||||
|
"allow-device-gap",
|
||||||
|
"allow-entitlements",
|
||||||
"allow-ssh",
|
"allow-ssh",
|
||||||
"allow-stale-web",
|
"allow-stale-web",
|
||||||
"allow-version-mismatch",
|
"allow-version-mismatch",
|
||||||
"build-number",
|
"build-number",
|
||||||
"configuration",
|
"configuration",
|
||||||
|
"derived-data",
|
||||||
|
"entitlements",
|
||||||
"env-file",
|
"env-file",
|
||||||
|
"evidence",
|
||||||
"keychain",
|
"keychain",
|
||||||
"keychain-unlock",
|
"keychain-unlock",
|
||||||
"locale-map",
|
"locale-map",
|
||||||
|
|
@ -82,6 +87,7 @@
|
||||||
"out",
|
"out",
|
||||||
"path-free",
|
"path-free",
|
||||||
"platform",
|
"platform",
|
||||||
|
"pre-check",
|
||||||
"profile",
|
"profile",
|
||||||
"progress",
|
"progress",
|
||||||
"project",
|
"project",
|
||||||
|
|
@ -100,6 +106,7 @@
|
||||||
"name"
|
"name"
|
||||||
],
|
],
|
||||||
"apple cpp": [
|
"apple cpp": [
|
||||||
|
"duo-only",
|
||||||
"include-drafts",
|
"include-drafts",
|
||||||
"jobs",
|
"jobs",
|
||||||
"name",
|
"name",
|
||||||
|
|
@ -198,6 +205,7 @@
|
||||||
"write"
|
"write"
|
||||||
],
|
],
|
||||||
"apple ppo": [
|
"apple ppo": [
|
||||||
|
"duo-only",
|
||||||
"experiment",
|
"experiment",
|
||||||
"include-drafts",
|
"include-drafts",
|
||||||
"jobs",
|
"jobs",
|
||||||
|
|
@ -228,13 +236,16 @@
|
||||||
"enable"
|
"enable"
|
||||||
],
|
],
|
||||||
"apple release": [
|
"apple release": [
|
||||||
|
"after-approval",
|
||||||
"env-file",
|
"env-file",
|
||||||
"first-release",
|
"first-release",
|
||||||
|
"manual",
|
||||||
"manual-release",
|
"manual-release",
|
||||||
"phased",
|
"phased",
|
||||||
"platform",
|
"platform",
|
||||||
"progress",
|
"progress",
|
||||||
"result-file",
|
"result-file",
|
||||||
|
"scheduled",
|
||||||
"version",
|
"version",
|
||||||
"version-from"
|
"version-from"
|
||||||
],
|
],
|
||||||
|
|
@ -257,9 +268,11 @@
|
||||||
"with-version"
|
"with-version"
|
||||||
],
|
],
|
||||||
"apple review-details": [
|
"apple review-details": [
|
||||||
"contact-from"
|
"contact-from",
|
||||||
|
"platform"
|
||||||
],
|
],
|
||||||
"apple screenshots": [
|
"apple screenshots": [
|
||||||
|
"duo-only",
|
||||||
"include-drafts",
|
"include-drafts",
|
||||||
"jobs",
|
"jobs",
|
||||||
"not-sent-for-review",
|
"not-sent-for-review",
|
||||||
|
|
@ -361,6 +374,7 @@
|
||||||
"locale",
|
"locale",
|
||||||
"no-wait",
|
"no-wait",
|
||||||
"older-than",
|
"older-than",
|
||||||
|
"out",
|
||||||
"platform",
|
"platform",
|
||||||
"pre-check",
|
"pre-check",
|
||||||
"progress",
|
"progress",
|
||||||
|
|
@ -584,6 +598,7 @@
|
||||||
"since"
|
"since"
|
||||||
],
|
],
|
||||||
"flow": [
|
"flow": [
|
||||||
|
"apple",
|
||||||
"apply",
|
"apply",
|
||||||
"from",
|
"from",
|
||||||
"resume"
|
"resume"
|
||||||
|
|
@ -639,7 +654,26 @@
|
||||||
"to",
|
"to",
|
||||||
"translate"
|
"translate"
|
||||||
],
|
],
|
||||||
"mcp": [],
|
"mcp": [
|
||||||
|
"allow-origin",
|
||||||
|
"allow-remote-token",
|
||||||
|
"auth",
|
||||||
|
"broker-profiles",
|
||||||
|
"host",
|
||||||
|
"http",
|
||||||
|
"introspect-key-file",
|
||||||
|
"introspect-url",
|
||||||
|
"issuer",
|
||||||
|
"port",
|
||||||
|
"project",
|
||||||
|
"public",
|
||||||
|
"rate",
|
||||||
|
"read-only",
|
||||||
|
"resource",
|
||||||
|
"roots",
|
||||||
|
"token-file",
|
||||||
|
"trust-proxy"
|
||||||
|
],
|
||||||
"onboard": [
|
"onboard": [
|
||||||
"accounts",
|
"accounts",
|
||||||
"all",
|
"all",
|
||||||
|
|
@ -1082,6 +1116,7 @@
|
||||||
"cordova-android",
|
"cordova-android",
|
||||||
"cordova-ios",
|
"cordova-ios",
|
||||||
"days",
|
"days",
|
||||||
|
"duo-only",
|
||||||
"expo",
|
"expo",
|
||||||
"flutter",
|
"flutter",
|
||||||
"godot",
|
"godot",
|
||||||
|
|
@ -1144,14 +1179,19 @@
|
||||||
"accounts",
|
"accounts",
|
||||||
"add-for-review",
|
"add-for-review",
|
||||||
"adgroup",
|
"adgroup",
|
||||||
|
"after-approval",
|
||||||
"against",
|
"against",
|
||||||
"agent",
|
"agent",
|
||||||
"all",
|
"all",
|
||||||
"all-pages",
|
"all-pages",
|
||||||
"allow-app-group-gap",
|
"allow-app-group-gap",
|
||||||
"allow-availability-changes",
|
"allow-availability-changes",
|
||||||
|
"allow-device-gap",
|
||||||
|
"allow-entitlements",
|
||||||
"allow-existing",
|
"allow-existing",
|
||||||
|
"allow-origin",
|
||||||
"allow-price-changes",
|
"allow-price-changes",
|
||||||
|
"allow-remote-token",
|
||||||
"allow-ssh",
|
"allow-ssh",
|
||||||
"allow-stale-web",
|
"allow-stale-web",
|
||||||
"allow-version-mismatch",
|
"allow-version-mismatch",
|
||||||
|
|
@ -1164,11 +1204,13 @@
|
||||||
"apps",
|
"apps",
|
||||||
"archive",
|
"archive",
|
||||||
"aso",
|
"aso",
|
||||||
|
"auth",
|
||||||
"base",
|
"base",
|
||||||
"base-url",
|
"base-url",
|
||||||
"beta",
|
"beta",
|
||||||
"bid",
|
"bid",
|
||||||
"body",
|
"body",
|
||||||
|
"broker-profiles",
|
||||||
"build",
|
"build",
|
||||||
"build-number",
|
"build-number",
|
||||||
"bundle-id",
|
"bundle-id",
|
||||||
|
|
@ -1201,12 +1243,15 @@
|
||||||
"debug-dump",
|
"debug-dump",
|
||||||
"declarations",
|
"declarations",
|
||||||
"delay",
|
"delay",
|
||||||
|
"derived-data",
|
||||||
"detail",
|
"detail",
|
||||||
"device",
|
"device",
|
||||||
"dir",
|
"dir",
|
||||||
"download",
|
"download",
|
||||||
|
"duo-only",
|
||||||
"enable",
|
"enable",
|
||||||
"end",
|
"end",
|
||||||
|
"entitlements",
|
||||||
"env-file",
|
"env-file",
|
||||||
"every",
|
"every",
|
||||||
"evidence",
|
"evidence",
|
||||||
|
|
@ -1234,6 +1279,8 @@
|
||||||
"headless",
|
"headless",
|
||||||
"home",
|
"home",
|
||||||
"hook",
|
"hook",
|
||||||
|
"host",
|
||||||
|
"http",
|
||||||
"icon",
|
"icon",
|
||||||
"icons",
|
"icons",
|
||||||
"identity",
|
"identity",
|
||||||
|
|
@ -1242,9 +1289,12 @@
|
||||||
"install",
|
"install",
|
||||||
"internal",
|
"internal",
|
||||||
"internal-only",
|
"internal-only",
|
||||||
|
"introspect-key-file",
|
||||||
|
"introspect-url",
|
||||||
"invite",
|
"invite",
|
||||||
"ios",
|
"ios",
|
||||||
"issue",
|
"issue",
|
||||||
|
"issuer",
|
||||||
"issues",
|
"issues",
|
||||||
"jobs",
|
"jobs",
|
||||||
"keep",
|
"keep",
|
||||||
|
|
@ -1263,6 +1313,7 @@
|
||||||
"locale",
|
"locale",
|
||||||
"locale-map",
|
"locale-map",
|
||||||
"lookup",
|
"lookup",
|
||||||
|
"manual",
|
||||||
"manual-release",
|
"manual-release",
|
||||||
"max-level",
|
"max-level",
|
||||||
"max-ratio",
|
"max-ratio",
|
||||||
|
|
@ -1328,9 +1379,12 @@
|
||||||
"propose",
|
"propose",
|
||||||
"prune",
|
"prune",
|
||||||
"prune-languages",
|
"prune-languages",
|
||||||
|
"public",
|
||||||
"q",
|
"q",
|
||||||
|
"rate",
|
||||||
"rating",
|
"rating",
|
||||||
"react-native",
|
"react-native",
|
||||||
|
"read-only",
|
||||||
"reconvert",
|
"reconvert",
|
||||||
"refresh-profile",
|
"refresh-profile",
|
||||||
"region",
|
"region",
|
||||||
|
|
@ -1340,12 +1394,15 @@
|
||||||
"render",
|
"render",
|
||||||
"repair-stuck",
|
"repair-stuck",
|
||||||
"resolve-iaps",
|
"resolve-iaps",
|
||||||
|
"resource",
|
||||||
"result-file",
|
"result-file",
|
||||||
"resume",
|
"resume",
|
||||||
"review-sent",
|
"review-sent",
|
||||||
"root",
|
"root",
|
||||||
|
"roots",
|
||||||
"scan-paths",
|
"scan-paths",
|
||||||
"scenes",
|
"scenes",
|
||||||
|
"scheduled",
|
||||||
"scheme",
|
"scheme",
|
||||||
"sdk-dirs",
|
"sdk-dirs",
|
||||||
"search",
|
"search",
|
||||||
|
|
@ -1376,11 +1433,13 @@
|
||||||
"threshold",
|
"threshold",
|
||||||
"timeout",
|
"timeout",
|
||||||
"to",
|
"to",
|
||||||
|
"token-file",
|
||||||
"top",
|
"top",
|
||||||
"track",
|
"track",
|
||||||
"tracking-domains",
|
"tracking-domains",
|
||||||
"traffic",
|
"traffic",
|
||||||
"translate",
|
"translate",
|
||||||
|
"trust-proxy",
|
||||||
"type",
|
"type",
|
||||||
"udid",
|
"udid",
|
||||||
"unanswered",
|
"unanswered",
|
||||||
|
|
@ -1456,7 +1515,7 @@
|
||||||
"storebound apple appinfo [--dry] [--json] [--allow-price-changes] [--allow-availability-changes]"
|
"storebound apple appinfo [--dry] [--json] [--allow-price-changes] [--allow-availability-changes]"
|
||||||
],
|
],
|
||||||
"apple build": [
|
"apple build": [
|
||||||
"storebound apple build --platform macos --tauri <src-tauri> [--path-free] [--unsigned] [--target T] [--profile F] [--version x.y.z] [--build-number N] [--out D]",
|
"storebound apple build --platform macos --tauri <src-tauri> [--path-free] [--unsigned] [--target T] [--profile F] [--entitlements <plist>] [--allow-entitlements] [--version x.y.z] [--build-number N] [--out D]",
|
||||||
"storebound apple build [--version 1.2.0] [--build-number N] [--scheme S] [--workspace W | --project P]"
|
"storebound apple build [--version 1.2.0] [--build-number N] [--scheme S] [--workspace W | --project P]"
|
||||||
],
|
],
|
||||||
"apple bundle": [
|
"apple bundle": [
|
||||||
|
|
@ -1524,16 +1583,17 @@
|
||||||
],
|
],
|
||||||
"apple release": [
|
"apple release": [
|
||||||
"storebound apple release --phased on|pause|resume|complete [--version 1.2.0] [--dry] [--yes]",
|
"storebound apple release --phased on|pause|resume|complete [--version 1.2.0] [--dry] [--yes]",
|
||||||
"storebound apple release --manual-release [--version 1.2.0] [--first-release] [--yes] [--json]"
|
"storebound apple release --manual-release [--version 1.2.0] [--first-release] [--yes] [--json]",
|
||||||
|
"storebound apple release --after-approval | --manual | --scheduled <ISO date> [--version 1.2.0] [--first-release] [--yes] [--json]"
|
||||||
],
|
],
|
||||||
"apple resubmit": [
|
"apple resubmit": [
|
||||||
"storebound apple resubmit --build <n> [--version 1.0.0] [--platform ios|macos|tvos|visionos] [--resolve-iaps] [--first-release] [--dry] [--yes] [--json]"
|
"storebound apple resubmit --build <n> [--version 1.0.0] [--platform ios|macos|tvos|visionos] [--resolve-iaps] [--first-release] [--dry] [--yes] [--json]"
|
||||||
],
|
],
|
||||||
"apple review-details": [
|
"apple review-details": [
|
||||||
"storebound apple review-details [--contact-from <Apple ID of another app>] [--dry]"
|
"storebound apple review-details [--platform ios|macos|tvos|visionos] [--contact-from <Apple ID of another app>] [--dry]"
|
||||||
],
|
],
|
||||||
"apple screenshots": [
|
"apple screenshots": [
|
||||||
"storebound apple screenshots [--src store/renders] [--only en-US,tr] [--jobs 4] [--variant b] [--dry]",
|
"storebound apple screenshots [--src store/renders] [--only en-US,tr] [--jobs 4] [--variant b] [--duo-only] [--dry]",
|
||||||
"storebound apple screenshots --repair-stuck [--dry] (only the screenshots stuck outside COMPLETE, in place)"
|
"storebound apple screenshots --repair-stuck [--dry] (only the screenshots stuck outside COMPLETE, in place)"
|
||||||
],
|
],
|
||||||
"apple signing": [
|
"apple signing": [
|
||||||
|
|
@ -1563,7 +1623,7 @@
|
||||||
"storebound apple testflight expire (--keep N | --older-than D) [--version x.y.z] [--dry] [--yes] [--json]"
|
"storebound apple testflight expire (--keep N | --older-than D) [--version x.y.z] [--dry] [--yes] [--json]"
|
||||||
],
|
],
|
||||||
"apple upload": [
|
"apple upload": [
|
||||||
"storebound apple upload [<app.ipa>] [--build N] [--allow-existing] [--via api|altool] [--no-wait] [--timeout 60m] [--pre-check \"<cmd with {file}>\"] [--evidence <path.json>] [--dry] [--yes] [--json]",
|
"storebound apple upload [<app.ipa>] [--out D] [--build N] [--allow-existing] [--via api|altool] [--no-wait] [--timeout 60m] [--pre-check \"<cmd with {file}>\"] [--evidence <path.json>] [--dry] [--yes] [--json]",
|
||||||
"storebound apple upload <App.pkg> --platform macos [...] (Mac App Store .pkg from apple build --platform macos --tauri; platform MAC_OS, uti com.apple.pkg; altool gets --type macos; no SDK / privacy-manifest check)"
|
"storebound apple upload <App.pkg> --platform macos [...] (Mac App Store .pkg from apple build --platform macos --tauri; platform MAC_OS, uti com.apple.pkg; altool gets --type macos; no SDK / privacy-manifest check)"
|
||||||
],
|
],
|
||||||
"apple win-back": [
|
"apple win-back": [
|
||||||
|
|
@ -1760,7 +1820,7 @@
|
||||||
"storebound settings bypass on | off | status owner opt-in: the agent also presses the owner-only buttons"
|
"storebound settings bypass on | off | status owner opt-in: the agent also presses the owner-only buttons"
|
||||||
],
|
],
|
||||||
"shots capture": [
|
"shots capture": [
|
||||||
"storebound shots capture [--lang en,tr] [--only hero,shop] [--device phone|tablet] [--source web|ios-sim|android-emu|folder]"
|
"storebound shots capture [--lang en,tr] [--only hero,shop] [--device phone|tablet|landscape] [--source web|ios-sim|android-emu|folder]"
|
||||||
],
|
],
|
||||||
"shots check": [
|
"shots check": [
|
||||||
"storebound shots check [--lang en,tr] [--variants] [--json]"
|
"storebound shots check [--lang en,tr] [--variants] [--json]"
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,8 @@
|
||||||
// storebound doctor [--dir .] [--json]
|
// storebound doctor [--dir .] [--json]
|
||||||
// storebound doctor --install <tool> [--yes] runs this OS's install command for one tool (winget / brew / apt);
|
// storebound doctor --install <tool> [--yes] runs this OS's install command for one tool (winget / brew / apt);
|
||||||
// without --yes only prints it. Never sudo, never an admin prompt.
|
// without --yes only prints it. Never sudo, never an admin prompt.
|
||||||
import { existsSync } from 'node:fs';
|
import { existsSync, realpathSync } from 'node:fs';
|
||||||
|
import { homedir } from 'node:os';
|
||||||
import { join, resolve } from 'node:path';
|
import { join, resolve } from 'node:path';
|
||||||
import pkg from '../package.json' with { type: 'json' };
|
import pkg from '../package.json' with { type: 'json' };
|
||||||
import type { Args } from './lib/args';
|
import type { Args } from './lib/args';
|
||||||
|
|
@ -114,6 +115,8 @@ export async function run(args: Args): Promise<void> {
|
||||||
const set = r.credentials.filter(c => c.status === 'set').map(c => c.key), ph = r.credentials.filter(c => c.status === 'placeholder').map(c => c.key);
|
const set = r.credentials.filter(c => c.status === 'set').map(c => c.key), ph = r.credentials.filter(c => c.status === 'placeholder').map(c => c.key);
|
||||||
log('doctor', `credentials: ${set.length ? set.join(', ') : 'none set'}${ph.length ? ` · placeholders (treated as missing): ${ph.join(', ')}` : ''}`);
|
log('doctor', `credentials: ${set.length ? set.join(', ') : 'none set'}${ph.length ? ` · placeholders (treated as missing): ${ph.join(', ')}` : ''}`);
|
||||||
log('doctor', playLine(r.play));
|
log('doctor', playLine(r.play));
|
||||||
|
const tcc = protectedInstall(realScript(), homedir());
|
||||||
|
if (tcc) log('doctor', `WARN this storebound runs from ${tcc}: macOS guards that folder, so a launchd job, CI agent or anything started outside a terminal with access blocks forever when it opens the file (no output, no error). Install it from npm instead: bun add -g storebound@latest (or npm i -g storebound)`);
|
||||||
if (r.foreignRsync) log('doctor', `rsync: ${r.foreignRsync} is first on PATH and breaks Xcode exportArchive ("Copy failed") outside storebound; storebound apple build puts /usr/bin first. Fix for everything else: brew unlink rsync, or put /usr/bin before it`);
|
if (r.foreignRsync) log('doctor', `rsync: ${r.foreignRsync} is first on PATH and breaks Xcode exportArchive ("Copy failed") outside storebound; storebound apple build puts /usr/bin first. Fix for everything else: brew unlink rsync, or put /usr/bin before it`);
|
||||||
const missing = r.tools.filter(t => !t.found || t.status === 'outdated');
|
const missing = r.tools.filter(t => !t.found || t.status === 'outdated');
|
||||||
if (!missing.length) { log('doctor', 'everything storebound can use is here'); return; }
|
if (!missing.length) { log('doctor', 'everything storebound can use is here'); return; }
|
||||||
|
|
@ -125,3 +128,17 @@ export async function run(args: Args): Promise<void> {
|
||||||
}
|
}
|
||||||
log('doctor', `${missing.length} missing. Store work needs none of them; screenshots, previews, icons and captures do.`);
|
log('doctor', `${missing.length} missing. Store work needs none of them; screenshots, previews, icons and captures do.`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** The real path of the running storebound (a bun link / npm link resolves into the checkout). */
|
||||||
|
function realScript(): string { try { return realpathSync(process.argv[1] ?? ''); } catch { return process.argv[1] ?? ''; } }
|
||||||
|
|
||||||
|
/** macOS only: the guarded home folder (Desktop, Documents, Downloads, iCloud Drive) a path lies in, or null. A process
|
||||||
|
* without access to it (a launchd job, a CI agent) hangs in open() while macOS waits for a consent nobody can give. */
|
||||||
|
export function protectedInstall(path: string, home: string, platform: string = process.platform): string | null {
|
||||||
|
if (platform !== 'darwin' || !path || !home) return null;
|
||||||
|
for (const d of ['Desktop', 'Documents', 'Downloads', 'Library/Mobile Documents']) {
|
||||||
|
const dir = `${home.endsWith('/') ? home.slice(0, -1) : home}/${d}`; // posix paths: the check is macOS-only
|
||||||
|
if (path === dir || path.startsWith(dir + '/')) return `~/${d}`;
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
|
||||||
16
cli/flow.ts
16
cli/flow.ts
|
|
@ -20,7 +20,7 @@ import { dirname, join, relative } from 'node:path';
|
||||||
import type { Args } from './lib/args';
|
import type { Args } from './lib/args';
|
||||||
import { CONFIG_NAMES, loadConfig, type ShipConfig } from './lib/config';
|
import { CONFIG_NAMES, loadConfig, type ShipConfig } from './lib/config';
|
||||||
import {
|
import {
|
||||||
type CondCtx, expand, type Flow, flowsOfFile, kindOf, type Mode, parseParams, planStep, type PlannedStep, resumePoint, type RunState, startIndex,
|
type CondCtx, type DryPending, expand, type Flow, flowsOfFile, kindOf, missingParams, type Mode, noteDry, parseParams, planStep, plannedForDryInput, type PlannedStep, resumePoint, type RunState, startIndex,
|
||||||
type StepResult, validateFlows,
|
type StepResult, validateFlows,
|
||||||
} from './lib/flow';
|
} from './lib/flow';
|
||||||
import { DECLINED_MARK } from './lib/ctx';
|
import { DECLINED_MARK } from './lib/ctx';
|
||||||
|
|
@ -170,6 +170,12 @@ async function runFlow(args: Args, root: string): Promise<void> {
|
||||||
const subParams = expand(flow, all, 'steps').params;
|
const subParams = expand(flow, all, 'steps').params;
|
||||||
const vars: Record<string, string> = { ...subParams, ...flow.params, ...(from ? last?.vars ?? {} : {}), ...params };
|
const vars: Record<string, string> = { ...subParams, ...flow.params, ...(from ? last?.vars ?? {} : {}), ...params };
|
||||||
const c = await condCtx(root);
|
const c = await condCtx(root);
|
||||||
|
vars['config.testflight.internal'] = (c.config?.apple?.testflight?.groups ?? []).filter(g => g.internal).map(g => g.name).join(',');
|
||||||
|
if (!args.has('resume')) {
|
||||||
|
const missing = missingParams(vars);
|
||||||
|
if (missing.length) throw new Error(`${name} needs ${missing.map(k => `${k}=<value>`).join(' ')} (storebound flow run ${name} ${missing.map(k => `${k}=...`).join(' ')})`);
|
||||||
|
}
|
||||||
|
const pending: DryPending = { built: new Set(), uploaded: new Set() };
|
||||||
const prebuilt = prebuildsDone();
|
const prebuilt = prebuildsDone();
|
||||||
const state: RunState = { flow: name, mode, startedAt: new Date().toISOString(), vars, results: [], ok: true };
|
const state: RunState = { flow: name, mode, startedAt: new Date().toISOString(), vars, results: [], ok: true };
|
||||||
const env = process.env as Record<string, string | undefined>;
|
const env = process.env as Record<string, string | undefined>;
|
||||||
|
|
@ -196,12 +202,20 @@ async function runFlow(args: Args, root: string): Promise<void> {
|
||||||
state.results.push(r); save();
|
state.results.push(r); save();
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
const planned = plannedForDryInput(p, mode, pending);
|
||||||
|
if (planned) {
|
||||||
|
r.status = 'planned'; r.detail = planned;
|
||||||
|
if (!json) log(TAG, `${label}: ${describe(p)} (${planned})`);
|
||||||
|
state.results.push(r); save();
|
||||||
|
continue;
|
||||||
|
}
|
||||||
if (!json) log(TAG, `${label}: ${describe(p)}${p.dryAdded ? ' (dry run)' : ''}`);
|
if (!json) log(TAG, `${label}: ${describe(p)}${p.dryAdded ? ' (dry run)' : ''}`);
|
||||||
const t = Date.now();
|
const t = Date.now();
|
||||||
const x = await exec(p, root, json, prebuilt.size ? { [PREBUILD_DONE_ENV]: [...prebuilt].join('\n') } : {});
|
const x = await exec(p, root, json, prebuilt.size ? { [PREBUILD_DONE_ENV]: [...prebuilt].join('\n') } : {});
|
||||||
r.exitCode = x.code; r.ms = Date.now() - t;
|
r.exitCode = x.code; r.ms = Date.now() - t;
|
||||||
if (x.code === 0) {
|
if (x.code === 0) {
|
||||||
r.status = 'ok';
|
r.status = 'ok';
|
||||||
|
noteDry(p, pending);
|
||||||
const pre = p.argv ? prebuildRan(p.argv, c.config) : null;
|
const pre = p.argv ? prebuildRan(p.argv, c.config) : null;
|
||||||
if (pre) prebuilt.add(pre);
|
if (pre) prebuilt.add(pre);
|
||||||
if (p.capture) {
|
if (p.capture) {
|
||||||
|
|
|
||||||
|
|
@ -325,3 +325,35 @@ export async function playPreflight(command: string, root: string, pkg: string |
|
||||||
if (o.dry) { for (const g of gaps) o.warn(`${g.message}. Fix: ${g.fix}`); return gaps; }
|
if (o.dry) { for (const g of gaps) o.warn(`${g.message}. Fix: ${g.fix}`); return gaps; }
|
||||||
throw new Error(`${command} stopped before any call to Google Play:\n${gapsText(gaps)}`);
|
throw new Error(`${command} stopped before any call to Google Play:\n${gapsText(gaps)}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export type StoreKind = 'asc-api-key' | 'play-service-account';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A store credential of one profile from the broker's vault (GET /api/store-credentials/<profile>/<kind>, a key with
|
||||||
|
* the store-credentials scope): { secret, metadata }. For a long-running server (`mcp --http --broker-profiles`) that
|
||||||
|
* keeps no key files; null when the broker has none for that profile. Never logged.
|
||||||
|
*/
|
||||||
|
export async function brokerStoreCredential(cfg: BrokerConfig, profile: string, kind: StoreKind): Promise<{ secret: string; metadata: Record<string, unknown> } | null> {
|
||||||
|
const a = await request(cfg, 'GET', `/api/store-credentials/${encodeURIComponent(profile)}/${kind}`);
|
||||||
|
if (a.status === 404) return null;
|
||||||
|
if (a.status === 401 || a.status === 403) throw new BrokerRefused(`credential broker ${host(cfg)} refused store credentials for ${profile} (${a.status} ${errOf(a)}): the key needs the store-credentials scope and the profile`, a.status);
|
||||||
|
const j = a.json as { secret?: unknown; metadata?: unknown } | null;
|
||||||
|
if (a.status !== 200 || !j || typeof j.secret !== 'string') throw new BrokerUnavailable(`credential broker ${host(cfg)} -> ${a.status} for ${profile}/${kind}`);
|
||||||
|
return { secret: j.secret, metadata: j.metadata && typeof j.metadata === 'object' ? (j.metadata as Record<string, unknown>) : {} };
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The env a child process needs to use these profiles from the broker (STOREBOUND_PROFILE_<NAME>_<KEY>, inline PEM /
|
||||||
|
* JSON; see credentials.ts). Profiles the broker has nothing for are left out. */
|
||||||
|
export async function brokerProfileEnv(cfg: BrokerConfig, profiles: string[]): Promise<Record<string, string>> {
|
||||||
|
const env: Record<string, string> = {};
|
||||||
|
const name = (p: string, k: string) => `STOREBOUND_PROFILE_${p.toUpperCase().replace(/[^A-Z0-9]/g, '_')}_${k}`;
|
||||||
|
await Promise.all(profiles.map(async p => {
|
||||||
|
const [asc, play] = await Promise.all([brokerStoreCredential(cfg, p, 'asc-api-key'), brokerStoreCredential(cfg, p, 'play-service-account')]);
|
||||||
|
if (asc) {
|
||||||
|
const { issuerId, keyId } = asc.metadata;
|
||||||
|
if (typeof issuerId === 'string' && typeof keyId === 'string') Object.assign(env, { [name(p, 'ASC_P8')]: asc.secret, [name(p, 'ASC_KEY_ID')]: keyId, [name(p, 'ASC_ISSUER_ID')]: issuerId });
|
||||||
|
}
|
||||||
|
if (play) env[name(p, 'PLAY_SERVICE_ACCOUNT')] = play.secret;
|
||||||
|
}));
|
||||||
|
return env;
|
||||||
|
}
|
||||||
|
|
|
||||||
81
cli/lib/cli-shim.ts
Normal file
81
cli/lib/cli-shim.ts
Normal file
|
|
@ -0,0 +1,81 @@
|
||||||
|
// The desktop app's own storebound on the terminal: the app ships the CLI as its sidecar, and on every start the sidecar
|
||||||
|
// puts a small launcher on the person's PATH, so `storebound` works in a terminal without an npm install.
|
||||||
|
// Windows %LOCALAPPDATA%\storebound\bin\storebound.cmd, that folder appended to the user PATH (once)
|
||||||
|
// macOS / Linux ~/.local/bin/storebound (a sh launcher), ~/.local/bin added to ~/.zprofile / ~/.profile when missing
|
||||||
|
// An npm / bun install stays first: the folder is appended, and a launcher is never written over a file that is not
|
||||||
|
// ours (the marker line). Rewritten on every start, so a moved or updated app fixes itself. Not from an AppImage (its
|
||||||
|
// mount path changes per run) or a dev run. STOREBOUND_NO_CLI_SHIM=1 turns it off.
|
||||||
|
import { existsSync, mkdirSync, readFileSync, writeFileSync, chmodSync, appendFileSync } from 'node:fs';
|
||||||
|
import { homedir } from 'node:os';
|
||||||
|
import { join } from 'node:path';
|
||||||
|
import * as rt from './rt';
|
||||||
|
|
||||||
|
export const SHIM_MARKER = 'storebound desktop launcher';
|
||||||
|
|
||||||
|
export interface ShimPlan {
|
||||||
|
/** Why nothing is written (null: write). */
|
||||||
|
skip: string | null;
|
||||||
|
file: string;
|
||||||
|
content: string;
|
||||||
|
/** The folder to add to PATH when it is not on it (Windows: the user PATH; else a shell profile line). */
|
||||||
|
pathDir: string;
|
||||||
|
/** macOS / Linux: the shell profile that gets the PATH line. */
|
||||||
|
profile?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** What to write for the sidecar at `exe`. Pure. */
|
||||||
|
export function shimPlan(o: { exe: string; platform: string; home: string; env: Record<string, string | undefined> }): ShimPlan {
|
||||||
|
const win = o.platform === 'win32';
|
||||||
|
const local = o.env.LOCALAPPDATA ?? join(o.home, 'AppData', 'Local');
|
||||||
|
const dir = win ? join(local, 'storebound', 'bin') : join(o.home, '.local', 'bin');
|
||||||
|
const file = join(dir, win ? 'storebound.cmd' : 'storebound');
|
||||||
|
const content = win
|
||||||
|
? `@echo off\r\nrem ${SHIM_MARKER}\r\n"${o.exe}" %*\r\n`
|
||||||
|
: `#!/bin/sh\n# ${SHIM_MARKER}\nexec '${o.exe.replace(/'/g, `'\\''`)}' "$@"\n`;
|
||||||
|
const skip = o.env.STOREBOUND_NO_CLI_SHIM ? 'STOREBOUND_NO_CLI_SHIM is set'
|
||||||
|
: o.env.APPIMAGE || /^\/tmp\/\.mount_/.test(o.exe) ? 'an AppImage (its path changes per run)'
|
||||||
|
: null;
|
||||||
|
return { skip, file, content, pathDir: dir, ...(win ? {} : { profile: join(o.home, o.platform === 'darwin' ? '.zprofile' : '.profile') }) };
|
||||||
|
}
|
||||||
|
|
||||||
|
/** True when `dir` is one of the PATH entries (case-insensitive on Windows). Pure. */
|
||||||
|
export function onPath(dir: string, path: string | undefined, platform: string): boolean {
|
||||||
|
const norm = (s: string) => { const t = s.replace(/[\\/]+$/, ''); return platform === 'win32' ? t.toLowerCase() : t; };
|
||||||
|
return (path ?? '').split(platform === 'win32' ? ';' : ':').some(p => p && norm(p) === norm(dir));
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Writes the launcher and the PATH entry; returns what it did, one line each. Never throws. */
|
||||||
|
export function ensureCliShim(exe: string = process.execPath, platform: string = process.platform, env: Record<string, string | undefined> = process.env, home: string = homedir()): string[] {
|
||||||
|
const done: string[] = [];
|
||||||
|
try {
|
||||||
|
const p = shimPlan({ exe, platform, home, env });
|
||||||
|
if (p.skip) return [`terminal launcher skipped: ${p.skip}`];
|
||||||
|
if (existsSync(p.file)) {
|
||||||
|
const cur = readFileSync(p.file, 'utf8');
|
||||||
|
if (!cur.includes(SHIM_MARKER)) return [`terminal launcher not written: ${p.file} exists and is not ours`];
|
||||||
|
if (cur === p.content) done.push(`terminal launcher up to date: ${p.file}`);
|
||||||
|
}
|
||||||
|
if (!done.length) {
|
||||||
|
mkdirSync(p.pathDir, { recursive: true });
|
||||||
|
writeFileSync(p.file, p.content);
|
||||||
|
if (platform !== 'win32') chmodSync(p.file, 0o755);
|
||||||
|
done.push(`terminal launcher written: ${p.file}`);
|
||||||
|
}
|
||||||
|
if (platform === 'win32') {
|
||||||
|
// the user PATH from the registry (not this process's, which a running app inherited before the change)
|
||||||
|
const q = rt.spawnSync(['reg', 'query', 'HKCU\\Environment', '/v', 'Path'], { stdout: 'pipe', stderr: 'pipe', timeout: 10_000 });
|
||||||
|
const userPath = /Path\s+REG_(?:EXPAND_)?SZ\s+(.*)/i.exec(new TextDecoder().decode(q.stdout ?? new Uint8Array()))?.[1]?.trim() ?? '';
|
||||||
|
if (!onPath(p.pathDir, userPath, platform)) {
|
||||||
|
// SetEnvironmentVariable keeps REG_EXPAND_SZ entries as typed and tells open Explorer windows (new terminals see it)
|
||||||
|
const ps = `$p=[Environment]::GetEnvironmentVariable('Path','User'); if(-not $p){$p=''}; if(($p -split ';') -notcontains '${p.pathDir}'){ [Environment]::SetEnvironmentVariable('Path', ($p.TrimEnd(';') + ';${p.pathDir}').TrimStart(';'), 'User') }`;
|
||||||
|
const r = rt.spawnSync(['powershell', '-NoProfile', '-NonInteractive', '-Command', ps], { stdout: 'pipe', stderr: 'pipe', timeout: 30_000 });
|
||||||
|
done.push(r.success ? `added to the user PATH: ${p.pathDir} (new terminals)` : `user PATH not changed (exit ${r.exitCode})`);
|
||||||
|
}
|
||||||
|
} else if (!onPath(p.pathDir, env.PATH, platform) && p.profile) {
|
||||||
|
const line = `export PATH="$PATH:$HOME/.local/bin" # ${SHIM_MARKER}`;
|
||||||
|
const cur = existsSync(p.profile) ? readFileSync(p.profile, 'utf8') : '';
|
||||||
|
if (!cur.includes(SHIM_MARKER)) { appendFileSync(p.profile, `${cur && !cur.endsWith('\n') ? '\n' : ''}${line}\n`); done.push(`added ~/.local/bin to PATH in ${p.profile} (new terminals)`); }
|
||||||
|
}
|
||||||
|
} catch (e) { done.push(`terminal launcher failed: ${(e as Error).message.split('\n')[0]}`); }
|
||||||
|
return done;
|
||||||
|
}
|
||||||
|
|
@ -18,6 +18,7 @@ import { type AppleSigning, validateSigning } from './signing';
|
||||||
import { type AppleBuildConfig, validateAppleBuild } from './xcode';
|
import { type AppleBuildConfig, validateAppleBuild } from './xcode';
|
||||||
import { type PlayBuildConfig, validatePlayBuild } from './gradle';
|
import { type PlayBuildConfig, validatePlayBuild } from './gradle';
|
||||||
import { type OriginalityConfig, validateOriginality } from './originality';
|
import { type OriginalityConfig, validateOriginality } from './originality';
|
||||||
|
import { validateReleaseType } from './release-type';
|
||||||
|
|
||||||
/** consumable / non_consumable: both stores. non_renewing: Apple NON_RENEWING_SUBSCRIPTION (access for a fixed time,
|
/** consumable / non_consumable: both stores. non_renewing: Apple NON_RENEWING_SUBSCRIPTION (access for a fixed time,
|
||||||
* you track the expiry); Google Play has no such type, so it becomes a one-time product your app consumes when the
|
* you track the expiry); Google Play has no such type, so it becomes a one-time product your app consumes when the
|
||||||
|
|
@ -201,7 +202,9 @@ export interface ShotsConfig {
|
||||||
/** Tablet frames: default 1032 x 1352 @2x (13" iPad minus its 24 px bar) with apple.ipad, else 800 x 1240 @2x. */
|
/** Tablet frames: default 1032 x 1352 @2x (13" iPad minus its 24 px bar) with apple.ipad, else 800 x 1240 @2x. */
|
||||||
tablet?: { w: number; h: number; dpr?: number; bar?: number };
|
tablet?: { w: number; h: number; dpr?: number; bar?: number };
|
||||||
/** Landscape layout (Mac, Chromebook, and the Play tablet slots with playTablets): copy on one side, the frame on the
|
/** Landscape layout (Mac, Chromebook, and the Play tablet slots with playTablets): copy on one side, the frame on the
|
||||||
* other. Frames: <frames>/<lang>/landscape/<name>.png at `size` CSS px (default 1440 x 900 @2x). frame: 'window' (a
|
* other. Frames: <frames>/<lang>/landscape/<name>.png at `size` CSS px (default 1440 x 900 @2x = 2880 x 1800), made by
|
||||||
|
* `shots capture --device landscape` (web source: a desktop viewport, no touch, no status bar crop; ios-sim / android-emu
|
||||||
|
* have no landscape device, use a web build or a folder). frame: 'window' (a
|
||||||
* Mac window around the game, the default for mac) or 'none' (the bare frame, the default for Play sizes). side:
|
* Mac window around the game, the default for mac) or 'none' (the bare frame, the default for Play sizes). side:
|
||||||
* where the copy goes (default 'left'). playTablets: render tab7 / tab10 landscape (1920 x 1080 / 2560 x 1440). */
|
* where the copy goes (default 'left'). playTablets: render tab7 / tab10 landscape (1920 x 1080 / 2560 x 1440). */
|
||||||
landscape?: { frame?: 'window' | 'none'; side?: 'left' | 'right'; playTablets?: boolean; size?: { w: number; h: number; dpr?: number } };
|
landscape?: { frame?: 'window' | 'none'; side?: 'left' | 'right'; playTablets?: boolean; size?: { w: number; h: number; dpr?: number } };
|
||||||
|
|
@ -216,7 +219,7 @@ export interface ShotsConfig {
|
||||||
/** One raw frame. Web: `path` (+ query). Simulator / emulator: `url` deep link and / or `args` / `extras`. */
|
/** One raw frame. Web: `path` (+ query). Simulator / emulator: `url` deep link and / or `args` / `extras`. */
|
||||||
/** Web capture: a selector, candidates tried in order, or per layout { phone, tablet, any } (own list first). Prefer data
|
/** Web capture: a selector, candidates tried in order, or per layout { phone, tablet, any } (own list first). Prefer data
|
||||||
* attributes (`[data-shot="shop-row"]`); `text=Shop` and `role=button[name="Shop"]` work as fallbacks. */
|
* attributes (`[data-shot="shop-row"]`); `text=Shop` and `role=button[name="Shop"]` work as fallbacks. */
|
||||||
export type ShotSelector = string | string[] | { phone?: string | string[]; tablet?: string | string[]; any?: string | string[] };
|
export type ShotSelector = string | string[] | { phone?: string | string[]; tablet?: string | string[]; landscape?: string | string[]; any?: string | string[] };
|
||||||
|
|
||||||
export interface ShotSpec {
|
export interface ShotSpec {
|
||||||
/** Web: wait (up to the waitFor timeout) until one of these matches, before waitFor; a miss names the selector and the size. */
|
/** Web: wait (up to the waitFor timeout) until one of these matches, before waitFor; a miss names the selector and the size. */
|
||||||
|
|
@ -234,7 +237,10 @@ export interface ShotSpec {
|
||||||
delayMs?: number;
|
delayMs?: number;
|
||||||
/** Web: JS run in the page before the screenshot. */
|
/** Web: JS run in the page before the screenshot. */
|
||||||
eval?: string[];
|
eval?: string[];
|
||||||
device?: 'phone' | 'tablet' | 'both';
|
/** Which frames this shot makes: phone (default), tablet, both (phone + tablet), landscape (<lang>/landscape/<name>.png at
|
||||||
|
* shots.landscape.size, web source only). When the project renders a landscape size (apple.mac, play.chromebook,
|
||||||
|
* shots.landscape.playTablets), shots without a device and 'both' shots also make a landscape frame. */
|
||||||
|
device?: 'phone' | 'tablet' | 'both' | 'landscape';
|
||||||
/** Web, capture.session "per-language": how this shot is reached in the already booted page. "spa" (default):
|
/** Web, capture.session "per-language": how this shot is reached in the already booted page. "spa" (default):
|
||||||
* history.pushState to its path + a popstate event, then waitFor / eval (switch scenes from those); "reload":
|
* history.pushState to its path + a popstate event, then waitFor / eval (switch scenes from those); "reload":
|
||||||
* page.goto in the same page. A failing waitFor there falls back to a fresh page. */
|
* page.goto in the same page. A failing waitFor there falls back to a fresh page. */
|
||||||
|
|
@ -678,6 +684,14 @@ export interface ShipConfig {
|
||||||
screenshotTypes?: string[];
|
screenshotTypes?: string[];
|
||||||
/** The app runs on iPad: renders, checks and uploads 13" iPad screenshots (2064 x 2752) and iPad app previews. */
|
/** The app runs on iPad: renders, checks and uploads 13" iPad screenshots (2064 x 2752) and iPad app previews. */
|
||||||
ipad?: boolean;
|
ipad?: boolean;
|
||||||
|
/** How an approved version goes live: "afterApproval" (released as soon as App Review approves it), "manual" (waits in
|
||||||
|
* Pending Developer Release for `apple release --manual-release`) or "scheduled" (not before earliestReleaseDate).
|
||||||
|
* Applied by `apple listing` when it creates a version and by `apple submit` before submitting (old -> new in the dry
|
||||||
|
* run); `apple release --after-approval | --manual` changes it on an editable version. Unset: new versions are MANUAL
|
||||||
|
* and existing ones are left as they are. */
|
||||||
|
releaseType?: 'afterApproval' | 'manual' | 'scheduled';
|
||||||
|
/** releaseType "scheduled": the earliest release, ISO 8601 date and time (2027-03-01T09:00:00Z). */
|
||||||
|
earliestReleaseDate?: string;
|
||||||
/**
|
/**
|
||||||
* Also render, check and upload a 6.3" iPhone set (Dynamic Island, medium display, 1206 x 2622 -> APP_IPHONE_61).
|
* Also render, check and upload a 6.3" iPhone set (Dynamic Island, medium display, 1206 x 2622 -> APP_IPHONE_61).
|
||||||
* Off by default: App Store Connect lists a medium-display screenshot as required for iPhone but fills it by
|
* Off by default: App Store Connect lists a medium-display screenshot as required for iPhone but fills it by
|
||||||
|
|
@ -686,13 +700,26 @@ export interface ShipConfig {
|
||||||
*/
|
*/
|
||||||
iphoneMedium?: boolean;
|
iphoneMedium?: boolean;
|
||||||
/** Also render and check iPhone Duo (foldable) screenshots: outer 1398 x 2034 and inner 2007 x 2853 (landscape too).
|
/** Also render and check iPhone Duo (foldable) screenshots: outer 1398 x 2034 and inner 2007 x 2853 (landscape too).
|
||||||
* Optional now, reportedly required from April 2027 for iOS 27.1 SDK builds. Not uploaded while the API has no
|
* Optional now, reportedly required from April 2027 for iOS 27.1 SDK builds. `apple screenshots` uploads them through
|
||||||
* display type for them (cli/shots/spec.ts IPHONE_DUO_DISPLAY). */
|
* the App Asset Library (display class IPHONE_DUO; there is no Duo ScreenshotDisplayType). */
|
||||||
iphoneDuo?: boolean;
|
iphoneDuo?: boolean;
|
||||||
/** Also render, check and upload Mac App Store screenshots (size key `mac`, 2880 x 1800, 16:10; Apple also takes
|
/** Also render, check and upload Mac App Store screenshots (size key `mac`, 2880 x 1800, 16:10; Apple also takes
|
||||||
* 2560 x 1600, 1440 x 900, 1280 x 800). Landscape layout from <frames>/<lang>/landscape/ (shots.landscape). Uploaded
|
* 2560 x 1600, 1440 x 900, 1280 x 800). Landscape layout from <frames>/<lang>/landscape/ (shots.landscape). Uploaded
|
||||||
* as APP_DESKTOP to the macOS version: `apple screenshots --platform macos`. */
|
* as APP_DESKTOP to the macOS version: `apple screenshots --platform macos`. */
|
||||||
mac?: boolean;
|
mac?: boolean;
|
||||||
|
/**
|
||||||
|
* macOS App Store overrides (not `mac`, which only switches Mac screenshots on). An app with an iOS and a macOS
|
||||||
|
* version often needs different version texts and review notes (the Mac app may have no Game Center, in-app
|
||||||
|
* purchases or ads). `listing`: an App Store listing file used instead of apple.listing for `apple listing
|
||||||
|
* --platform macos`; `reviewNotes`: used instead of apple.info.reviewNotes by `apple review-details --platform macos`.
|
||||||
|
* `gameCenter: true`: the Mac app has Game Center (silences the Game Center check of `validate --platform macos`).
|
||||||
|
* `noIap: true`: the Mac app sells nothing (validate then flags in-app purchase lines in the Mac texts).
|
||||||
|
* `entitlements`: the Mac App Store entitlements plist of `apple build --platform macos --tauri` (e.g. "src-tauri/Entitlements.appstore.plist"),
|
||||||
|
* used instead of the Tauri config's bundle.macOS.entitlements (a project with a Developer ID channel keeps that one there); `--entitlements <plist>` wins over it.
|
||||||
|
* `prebuild`: shell command `apple build --platform macos` runs first in the project root (build.prebuild /
|
||||||
|
* apple.prebuild are the iOS project's and are not run for the Mac build); `--no-prebuild` skips it.
|
||||||
|
*/
|
||||||
|
macos?: { listing?: string; reviewNotes?: string; gameCenter?: boolean; noIap?: boolean; entitlements?: string; prebuild?: string };
|
||||||
/** "Header and Search Results" creative assets (`storebound apple creative-assets`, iOS / iPadOS 27+). Files under
|
/** "Header and Search Results" creative assets (`storebound apple creative-assets`, iOS / iPadOS 27+). Files under
|
||||||
* <renders>/<lang>/creative/: header.{png,jpg,mov,m4v,mp4} (3840x1646, 21:9), search.{...} (3:2, 1920x1280 to
|
* <renders>/<lang>/creative/: header.{png,jpg,mov,m4v,mp4} (3840x1646, 21:9), search.{...} (3:2, 1920x1280 to
|
||||||
* 3840x2560) or universal.png (5244x2950) for both. `header` / `search` false skip that slot; `universal` is a
|
* 3840x2560) or universal.png (5244x2950) for both. `header` / `search` false skip that slot; `universal` is a
|
||||||
|
|
@ -707,6 +734,9 @@ export interface ShipConfig {
|
||||||
build?: AppleBuildConfig;
|
build?: AppleBuildConfig;
|
||||||
/** Shell command `apple build` runs first in the project root; overrides build.prebuild for the App Store. */
|
/** Shell command `apple build` runs first in the project root; overrides build.prebuild for the App Store. */
|
||||||
prebuild?: string;
|
prebuild?: string;
|
||||||
|
/** `apple build --platform macos`: shell command run on the built .app before productbuild ({file} = the .app path);
|
||||||
|
* a nonzero exit stops the build, nothing is packaged. E.g. a project's own check that a build-time value is in the binary. */
|
||||||
|
macAppCheck?: string;
|
||||||
/** Promoted in-app purchases on the product page, in order (`storebound apple promoted`; at most 20). */
|
/** Promoted in-app purchases on the product page, in order (`storebound apple promoted`; at most 20). */
|
||||||
promoted?: PromotedConfig;
|
promoted?: PromotedConfig;
|
||||||
/** Custom product pages (`storebound apple cpp`; at most 70). */
|
/** Custom product pages (`storebound apple cpp`; at most 70). */
|
||||||
|
|
@ -1010,6 +1040,7 @@ export function validateExtras(cfg: Partial<ShipConfig>): string[] {
|
||||||
if (cfg.build !== undefined && (typeof cfg.build !== 'object' || cfg.build === null)) e.push('build: { prebuild?: "<shell command>" }');
|
if (cfg.build !== undefined && (typeof cfg.build !== 'object' || cfg.build === null)) e.push('build: { prebuild?: "<shell command>" }');
|
||||||
if (badCmd(cfg.build?.prebuild)) e.push('build.prebuild: a shell command run in the project root before apple build / play build, e.g. "npm run build && npx cap sync"');
|
if (badCmd(cfg.build?.prebuild)) e.push('build.prebuild: a shell command run in the project root before apple build / play build, e.g. "npm run build && npx cap sync"');
|
||||||
if (badCmd(cfg.apple?.prebuild)) e.push('apple.prebuild: a shell command (overrides build.prebuild for apple build)');
|
if (badCmd(cfg.apple?.prebuild)) e.push('apple.prebuild: a shell command (overrides build.prebuild for apple build)');
|
||||||
|
if (badCmd(cfg.apple?.macAppCheck)) e.push('apple.macAppCheck: a shell command run on the built Mac .app ({file} = its path), e.g. "node tools/check-app.mjs {file}"');
|
||||||
if (badCmd(cfg.play?.prebuild)) e.push('play.prebuild: a shell command (overrides build.prebuild for play build)');
|
if (badCmd(cfg.play?.prebuild)) e.push('play.prebuild: a shell command (overrides build.prebuild for play build)');
|
||||||
if (cfg.apple?.teamId !== undefined &&!/^[A-Z0-9]{10}$/.test(cfg.apple.teamId)) e.push('apple.teamId: the 10-character Team ID (Membership details)');
|
if (cfg.apple?.teamId !== undefined &&!/^[A-Z0-9]{10}$/.test(cfg.apple.teamId)) e.push('apple.teamId: the 10-character Team ID (Membership details)');
|
||||||
if (cfg.play?.developerId !== undefined && !/^\d{1,25}$/.test(cfg.play.developerId)) e.push('play.developerId: the digits of play.google.com/console/u/0/developers/<id>');
|
if (cfg.play?.developerId !== undefined && !/^\d{1,25}$/.test(cfg.play.developerId)) e.push('play.developerId: the digits of play.google.com/console/u/0/developers/<id>');
|
||||||
|
|
@ -1018,6 +1049,14 @@ export function validateExtras(cfg: Partial<ShipConfig>): string[] {
|
||||||
e.push('play.developerAccount: the developer account name as Play Console shows it (1-100 characters)');
|
e.push('play.developerAccount: the developer account name as Play Console shows it (1-100 characters)');
|
||||||
if (cfg.play?.name !== undefined && !(typeof cfg.play.name === 'string' && cfg.play.name.trim() && [...cfg.play.name].length <= 30)) e.push('play.name: 1-30 characters (Play app name)');
|
if (cfg.play?.name !== undefined && !(typeof cfg.play.name === 'string' && cfg.play.name.trim() && [...cfg.play.name].length <= 30)) e.push('play.name: 1-30 characters (Play app name)');
|
||||||
if (cfg.play?.free !== undefined && typeof cfg.play.free !== 'boolean') e.push('play.free: true (free) | false (paid)');
|
if (cfg.play?.free !== undefined && typeof cfg.play.free !== 'boolean') e.push('play.free: true (free) | false (paid)');
|
||||||
|
const mo = cfg.apple?.macos;
|
||||||
|
if (mo !== undefined) {
|
||||||
|
if (typeof mo !== 'object' || mo === null || Array.isArray(mo)) e.push('apple.macos: { listing?: "store/appstore-macos.md", reviewNotes?: "...", gameCenter?: true, noIap?: true, entitlements?: "src-tauri/Entitlements.appstore.plist", prebuild?: "<shell command>" }');
|
||||||
|
else {
|
||||||
|
for (const k of ['listing', 'reviewNotes', 'entitlements', 'prebuild'] as const) if (mo[k] !== undefined && (typeof mo[k] !== 'string' || !mo[k]!.trim())) e.push(`apple.macos.${k}: a non-empty string${k === 'listing' ? ' (path of the macOS App Store listing file)' : k === 'entitlements' ? ' (path of the Mac App Store entitlements plist)' : ''}`);
|
||||||
|
for (const k of ['gameCenter', 'noIap'] as const) if (mo[k] !== undefined && typeof mo[k] !== 'boolean') e.push(`apple.macos.${k}: true | false`);
|
||||||
|
}
|
||||||
|
}
|
||||||
const ad = cfg.apple?.adhoc;
|
const ad = cfg.apple?.adhoc;
|
||||||
if (ad?.method !== undefined && ad.method !== 'release-testing' && ad.method !== 'ad-hoc') e.push('apple.adhoc.method: release-testing | ad-hoc');
|
if (ad?.method !== undefined && ad.method !== 'release-testing' && ad.method !== 'ad-hoc') e.push('apple.adhoc.method: release-testing | ad-hoc');
|
||||||
const ppp = cfg.prices?.ppp;
|
const ppp = cfg.prices?.ppp;
|
||||||
|
|
@ -1096,6 +1135,23 @@ function validateIarcDetails(d: IarcDetails | undefined): string[] {
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Platforms of the app (app identity): app.platforms, else from the store sections. */
|
/** Platforms of the app (app identity): app.platforms, else from the store sections. */
|
||||||
|
/** True for the macOS platform in any spelling: "macos", "mac_os" (API name MAC_OS), "mac". Pure. */
|
||||||
|
export const isMacosPlatform = (p: string | undefined | null): boolean => !!p && /^mac(_?os)?$/i.test(p.replace(/[\s-]/g, ''));
|
||||||
|
|
||||||
|
/** The App Store listing file (as written in the config, relative) for a platform: apple.macos.listing for macOS when
|
||||||
|
* set, else apple.listing, else store/appstore.md. Pure. */
|
||||||
|
export function listingPathFor(config: Pick<ShipConfig, 'apple'>, platform?: string | null): string {
|
||||||
|
const mac = isMacosPlatform(platform) ? config.apple?.macos?.listing?.trim() : '';
|
||||||
|
return mac || config.apple?.listing || 'store/appstore.md';
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The App Review notes text of the config for a platform: apple.macos.reviewNotes for macOS when set, else
|
||||||
|
* apple.info.reviewNotes. Pure; reviewAccess and account deletion lines are added by reviewNotes() in lib/review-details. */
|
||||||
|
export function reviewNotesFor(config: Pick<ShipConfig, 'apple'>, platform?: string | null): string | undefined {
|
||||||
|
const mac = isMacosPlatform(platform) ? config.apple?.macos?.reviewNotes : undefined;
|
||||||
|
return mac?.trim() ? mac : config.apple?.info?.reviewNotes;
|
||||||
|
}
|
||||||
|
|
||||||
/** App Store name limit (characters). */
|
/** App Store name limit (characters). */
|
||||||
export const APPLE_NAME_MAX = 30;
|
export const APPLE_NAME_MAX = 30;
|
||||||
|
|
||||||
|
|
@ -1105,6 +1161,14 @@ export const appleName = (c: Pick<ShipConfig, 'app' | 'apple'>): string => c.app
|
||||||
export const platformsOf = (c: Pick<ShipConfig, 'app' | 'apple' | 'play'>): Platform[] =>
|
export const platformsOf = (c: Pick<ShipConfig, 'app' | 'apple' | 'play'>): Platform[] =>
|
||||||
c.app.platforms ?? [...(c.apple ? ['ios' as const] : []), ...(c.play ? ['android' as const] : [])];
|
c.app.platforms ?? [...(c.apple ? ['ios' as const] : []), ...(c.play ? ['android' as const] : [])];
|
||||||
|
|
||||||
|
/** What a macOS submission leaves out per apple.macos (noIap: the in-app purchases; no gameCenter: the version's Game
|
||||||
|
* Center switch), with why; nulls for every other platform. Pure. */
|
||||||
|
export function macosSubmitSkips(c: Pick<ShipConfig, 'apple'>, platform: string): { iaps: string | null; gameCenter: string | null } {
|
||||||
|
if (platform !== 'MAC_OS') return { iaps: null, gameCenter: null };
|
||||||
|
return { iaps: c.apple?.macos?.noIap ? 'apple.macos.noIap (the Mac app sells nothing)' : null,
|
||||||
|
gameCenter: c.apple?.macos?.gameCenter ? null : 'the Mac app has no Game Center (apple.macos.gameCenter is not true)' };
|
||||||
|
}
|
||||||
|
|
||||||
/** Is a catalog item (product / subscription) sold on this store? Pure. */
|
/** Is a catalog item (product / subscription) sold on this store? Pure. */
|
||||||
export const sellsOn = (c: Pick<ShipConfig, 'app' | 'apple' | 'play'>, item: { platforms?: Platform[] }, store: 'apple' | 'play'): boolean => {
|
export const sellsOn = (c: Pick<ShipConfig, 'app' | 'apple' | 'play'>, item: { platforms?: Platform[] }, store: 'apple' | 'play'): boolean => {
|
||||||
const p: Platform = store === 'apple' ? 'ios' : 'android';
|
const p: Platform = store === 'apple' ? 'ios' : 'android';
|
||||||
|
|
@ -1197,10 +1261,11 @@ export function validateConfig(c: unknown): string[] {
|
||||||
if (an !== undefined && (typeof an !== 'string' || !an.trim())) e.push('apple.name: the App Store name (text), or leave it out to use app.name');
|
if (an !== undefined && (typeof an !== 'string' || !an.trim())) e.push('apple.name: the App Store name (text), or leave it out to use app.name');
|
||||||
else if (an !== undefined && [...an].length > APPLE_NAME_MAX) e.push(`apple.name: ${[...an].length} characters > ${APPLE_NAME_MAX} (App Store limit)`);
|
else if (an !== undefined && [...an].length > APPLE_NAME_MAX) e.push(`apple.name: ${[...an].length} characters > ${APPLE_NAME_MAX} (App Store limit)`);
|
||||||
if (cfg.apple.appId && !/^\d+$/.test(cfg.apple.appId)) e.push(`apple.appId: numeric Apple ID of the app (${consoleLink('asc.app-info')})`);
|
if (cfg.apple.appId && !/^\d+$/.test(cfg.apple.appId)) e.push(`apple.appId: numeric Apple ID of the app (${consoleLink('asc.app-info')})`);
|
||||||
|
e.push(...validateReleaseType(cfg.apple));
|
||||||
const enc = cfg.apple.usesNonExemptEncryption;
|
const enc = cfg.apple.usesNonExemptEncryption;
|
||||||
if (enc !== undefined && typeof enc !== 'boolean') e.push('apple.usesNonExemptEncryption: true | false');
|
if (enc !== undefined && typeof enc !== 'boolean') e.push('apple.usesNonExemptEncryption: true | false');
|
||||||
if (cfg.apple.screenshotTypes && !cfg.apple.screenshotTypes.every(t => /^APP_[A-Z0-9_]+$/.test(t))) e.push('apple.screenshotTypes: display types like APP_IPHONE_67');
|
if (cfg.apple.screenshotTypes && !cfg.apple.screenshotTypes.every(t => /^APP_[A-Z0-9_]+$/.test(t))) e.push('apple.screenshotTypes: display types like APP_IPHONE_67');
|
||||||
e.push(...validateTestflight(cfg.apple.testflight));
|
e.push(...validateTestflight(cfg.apple.testflight, cfg.languages ?? []));
|
||||||
e.push(...validateSigning(cfg.apple.signing), ...validateAppleBuild(cfg.apple.build));
|
e.push(...validateSigning(cfg.apple.signing), ...validateAppleBuild(cfg.apple.build));
|
||||||
const catalogIds = new Set([...(cfg.products ?? []).map(p => p.id), ...(cfg.subscriptions ?? []).flatMap(g => (g.subscriptions ?? []).map(x => x.id))]);
|
const catalogIds = new Set([...(cfg.products ?? []).map(p => p.id), ...(cfg.subscriptions ?? []).flatMap(g => (g.subscriptions ?? []).map(x => x.id))]);
|
||||||
e.push(...validatePromoted(cfg.apple.promoted, catalogIds));
|
e.push(...validatePromoted(cfg.apple.promoted, catalogIds));
|
||||||
|
|
|
||||||
111
cli/lib/device-families.ts
Normal file
111
cli/lib/device-families.ts
Normal file
|
|
@ -0,0 +1,111 @@
|
||||||
|
// Device families of an iOS app: what the last live version of the app on the App Store supports, against what the
|
||||||
|
// project builds (TARGETED_DEVICE_FAMILY in the Xcode project) and what the config says (apple.ipad).
|
||||||
|
// Apple refuses an upload that drops a device family the previous version supported: ITMS-90101 "This bundle does not
|
||||||
|
// support one or more of the devices supported by the previous app version", after a full archive (seen live: an app
|
||||||
|
// whose live version ran on iPad, built with TARGETED_DEVICE_FAMILY = 1). So `validate` and `apple build` compare first.
|
||||||
|
// Pure helpers; the store reads are in cli/apple/device-families.ts.
|
||||||
|
import { existsSync, readdirSync, readFileSync } from 'node:fs';
|
||||||
|
import { join } from 'node:path';
|
||||||
|
|
||||||
|
export interface Families { iphone: boolean; ipad: boolean }
|
||||||
|
|
||||||
|
/** Families in TARGETED_DEVICE_FAMILY: 1 iPhone/iPod, 2 iPad (3 tvOS, 4 watchOS, 6 Mac Catalyst, 7 Vision). Pure. */
|
||||||
|
export function familiesOfList(list: number[]): Families { return { iphone: list.includes(1), ipad: list.includes(2) }; }
|
||||||
|
|
||||||
|
/** The families a store signal names: build bundle deviceProtocols, file-size device models, screenshot display types. Pure. */
|
||||||
|
export function familiesOfStrings(values: string[]): Families {
|
||||||
|
const t = values.join(' ');
|
||||||
|
return { iphone: /iphone|ipod/i.test(t), ipad: /ipad/i.test(t) };
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface LiveFamilies { version: string; state: string; families: Families; evidence: string[] }
|
||||||
|
|
||||||
|
/** Merges the signals of one live version: any signal naming iPad means the version supports iPad. null when no signal
|
||||||
|
* names any family (unknown, never "iPhone only"). Pure. */
|
||||||
|
export function liveFamilies(version: string, state: string, signals: { name: string; values: string[] }[]): LiveFamilies | null {
|
||||||
|
const evidence: string[] = [];
|
||||||
|
const families: Families = { iphone: false, ipad: false };
|
||||||
|
for (const s of signals) {
|
||||||
|
const f = familiesOfStrings(s.values);
|
||||||
|
if (!f.iphone && !f.ipad) continue;
|
||||||
|
families.iphone ||= f.iphone;
|
||||||
|
families.ipad ||= f.ipad;
|
||||||
|
evidence.push(`${s.name}: ${[f.iphone && 'iPhone', f.ipad && 'iPad'].filter(Boolean).join(' + ')}`);
|
||||||
|
}
|
||||||
|
return evidence.length ? { version, state, families, evidence } : null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ProjectFamilies { file: string; list: number[]; families: Families; configurations: string[] }
|
||||||
|
|
||||||
|
/** The Release build configurations of a pbxproj with their TARGETED_DEVICE_FAMILY: the ones of the app's bundle id,
|
||||||
|
* else every Release configuration that is not an extension (bundle id below the app's). Pure. */
|
||||||
|
export function pbxFamilies(text: string, bundleId: string, file = 'project.pbxproj'): ProjectFamilies | null {
|
||||||
|
const blocks: { name: string; bundle: string | null; family: string | null; ext: boolean }[] = [];
|
||||||
|
const re = /isa = XCBuildConfiguration;[^{]*?buildSettings = \{([\s\S]*?)\};\s*name = ("[^"]*"|[\w.-]+);/g;
|
||||||
|
for (let m: RegExpExecArray | null; (m = re.exec(text));) {
|
||||||
|
const body = m[1]!;
|
||||||
|
const fam = /TARGETED_DEVICE_FAMILY = ("?)([\d, ]+)\1;/.exec(body)?.[2] ?? null;
|
||||||
|
const bid = /PRODUCT_BUNDLE_IDENTIFIER = "?([^";\s]+)"?;/.exec(body)?.[1] ?? null;
|
||||||
|
blocks.push({ name: m[2]!.replace(/"/g, ''), bundle: bid, family: fam, ext: /WRAPPER_EXTENSION = appex|APPLICATION_EXTENSION_API_ONLY = YES/.test(body) || (bid !== null && bid.startsWith(`${bundleId}.`)) });
|
||||||
|
}
|
||||||
|
const release = blocks.filter(b => b.name === 'Release' && b.family !== null);
|
||||||
|
let pick = release.filter(b => b.bundle === bundleId);
|
||||||
|
if (!pick.length) pick = release.filter(b => !b.ext);
|
||||||
|
if (!pick.length) return null;
|
||||||
|
const list = [...new Set(pick.flatMap(b => b.family!.split(',').map(x => Number(x.trim())).filter(n => Number.isFinite(n) && n > 0)))].sort((a, b) => a - b);
|
||||||
|
return { file, list, families: familiesOfList(list), configurations: pick.map(b => b.family!.replace(/\s/g, '')) };
|
||||||
|
}
|
||||||
|
|
||||||
|
const SKIP = new Set(['node_modules', 'Pods', '.git', 'build', 'DerivedData', 'Carthage', '.build', 'dist', 'vendor']);
|
||||||
|
|
||||||
|
/** Every project.pbxproj under root (depth <= 5), root-relative with forward slashes. */
|
||||||
|
export function findPbxprojs(root: string, depth = 5): string[] {
|
||||||
|
const out: string[] = [];
|
||||||
|
const walk = (dir: string, rel: string, d: number): void => {
|
||||||
|
if (d > depth || !existsSync(dir)) return;
|
||||||
|
let names: import('node:fs').Dirent[];
|
||||||
|
try { names = readdirSync(dir, { withFileTypes: true }); } catch { return; }
|
||||||
|
for (const e of names) {
|
||||||
|
if (!e.isDirectory() || SKIP.has(e.name)) continue;
|
||||||
|
const r = rel ? `${rel}/${e.name}` : e.name;
|
||||||
|
if (e.name.endsWith('.xcodeproj')) { if (existsSync(join(dir, e.name, 'project.pbxproj'))) out.push(`${r}/project.pbxproj`); continue; }
|
||||||
|
walk(join(dir, e.name), r, d + 1);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
walk(root, '', 0);
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The project's device families, read from the Xcode project (apple.build.project when set, else the first project
|
||||||
|
* that has the app's configurations). null when the project is not on this machine or sets no families. */
|
||||||
|
export function projectFamilies(root: string, bundleId: string, project?: string): ProjectFamilies | null {
|
||||||
|
const files = project && project.endsWith('.xcodeproj') ? [`${project.replace(/\\/g, '/')}/project.pbxproj`] : findPbxprojs(root);
|
||||||
|
for (const f of files) {
|
||||||
|
try {
|
||||||
|
const r = pbxFamilies(readFileSync(join(root, f), 'utf8'), bundleId, f);
|
||||||
|
if (r) return r;
|
||||||
|
} catch { /* unreadable: next */ }
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface FamilyVerdict { level: 'ok' | 'blocker' | 'warn'; msg: string; fix?: string }
|
||||||
|
|
||||||
|
/** Compares the live version, the project and the config. Blocker: the live version supports iPad and the project does
|
||||||
|
* not (the upload is refused with ITMS-90101) or apple.ipad is not true (iPad screenshots and checks are off). Pure. */
|
||||||
|
export function familyVerdicts(i: { live: LiveFamilies | null; project: ProjectFamilies | null; ipad: boolean | undefined }): FamilyVerdict[] {
|
||||||
|
const out: FamilyVerdict[] = [];
|
||||||
|
const { live, project } = i;
|
||||||
|
const fixProject = 'set TARGETED_DEVICE_FAMILY to "1,2" (Xcode: target > General > Supported Destinations: add iPad)';
|
||||||
|
if (!live) {
|
||||||
|
out.push({ level: 'warn', msg: `device families of the live version not known${project ? '' : ' and no Xcode project found'}: if it supports iPad, an iPhone-only build is refused at upload (ITMS-90101)`, fix: 'storebound validate (reads the live version from App Store Connect)' });
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
const liveText = `${[live.families.iphone && 'iPhone', live.families.ipad && 'iPad'].filter(Boolean).join(' + ')} (version ${live.version} ${live.state}; ${live.evidence.join('; ')})`;
|
||||||
|
if (live.families.ipad) {
|
||||||
|
if (project && !project.families.ipad) out.push({ level: 'blocker', msg: `the live version supports ${liveText}, but ${project.file} builds TARGETED_DEVICE_FAMILY = ${project.configurations.join(' / ')} (no iPad): Apple refuses the upload after the archive with ITMS-90101`, fix: `${fixProject}; and apple.ipad: true in the config` });
|
||||||
|
if (i.ipad !== true) out.push({ level: 'blocker', msg: `the live version supports ${liveText}, but apple.ipad is not true in the config`, fix: 'set apple.ipad: true (iPad screenshots are then required) and TARGETED_DEVICE_FAMILY "1,2"' });
|
||||||
|
if (!out.length) out.push({ level: 'ok', msg: `device families: live ${liveText}; project ${project ? `TARGETED_DEVICE_FAMILY ${project.configurations.join(' / ')}` : 'not read'}; apple.ipad true` });
|
||||||
|
} else out.push({ level: 'ok', msg: `device families: live ${liveText}; nothing to keep` });
|
||||||
|
return out;
|
||||||
|
}
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -205,7 +205,7 @@ export function validateFlows(flows: Flow[], o: { commands?: Set<string> } = {})
|
||||||
if (ids.has(s.id)) e.push(`${at}: id used twice`);
|
if (ids.has(s.id)) e.push(`${at}: id used twice`);
|
||||||
ids.add(s.id);
|
ids.add(s.id);
|
||||||
for (const t of [s.run, s.sh, s.owner, s.if].filter((x): x is string => typeof x === 'string'))
|
for (const t of [s.run, s.sh, s.owner, s.if].filter((x): x is string => typeof x === 'string'))
|
||||||
for (const m of t.matchAll(/\$\{([^}]*)\}/g)) if (!vars.has(m[1]!) && !/^env\.[A-Z0-9_]+$/.test(m[1]!)) e.push(`${at}: \${${m[1]}} is not a param or an earlier capture`);
|
for (const m of t.matchAll(/\$\{([^}]*)\}/g)) if (!vars.has(m[1]!) && !/^env\.[A-Z0-9_]+$/.test(m[1]!) && !CONFIG_VARS.includes(m[1]!)) e.push(`${at}: \${${m[1]}} is not a param or an earlier capture`);
|
||||||
if (s.capture) vars.add(s.capture);
|
if (s.capture) vars.add(s.capture);
|
||||||
if (s.run !== undefined) {
|
if (s.run !== undefined) {
|
||||||
let argv: string[] = [];
|
let argv: string[] = [];
|
||||||
|
|
@ -230,6 +230,14 @@ export function validateFlows(flows: Flow[], o: { commands?: Set<string> } = {})
|
||||||
|
|
||||||
// ---- variables, conditions ----
|
// ---- variables, conditions ----
|
||||||
|
|
||||||
|
/** Variables the runner fills from the config (empty when the config has none), usable in `run` and `if`. */
|
||||||
|
export const CONFIG_VARS = ['config.testflight.internal'];
|
||||||
|
|
||||||
|
/** The required-param marker: `VERSION: "?"` in params means the run needs VERSION=... (no silent default). */
|
||||||
|
export const REQUIRED = '?';
|
||||||
|
/** Params still at the required marker (not given on the command line). Pure. */
|
||||||
|
export function missingParams(vars: Record<string, string>): string[] { return Object.keys(vars).filter(k => vars[k] === REQUIRED); }
|
||||||
|
|
||||||
/** ${VAR} and ${env.NAME} substituted; unknown ones stay as written (the plan shows them). */
|
/** ${VAR} and ${env.NAME} substituted; unknown ones stay as written (the plan shows them). */
|
||||||
export function substitute(text: string, vars: Record<string, string>, env: Record<string, string | undefined> = {}): string {
|
export function substitute(text: string, vars: Record<string, string>, env: Record<string, string | undefined> = {}): string {
|
||||||
return text.replace(/\$\{([^}]*)\}/g, (m, k: string) => (k.startsWith('env.') ? env[k.slice(4)] ?? m : vars[k] ?? m));
|
return text.replace(/\$\{([^}]*)\}/g, (m, k: string) => (k.startsWith('env.') ? env[k.slice(4)] ?? m : vars[k] ?? m));
|
||||||
|
|
@ -306,6 +314,39 @@ export function planStep(s: FlowStep, part: PlannedStep['part'], mode: Mode, var
|
||||||
return { ...base, kind, argv: addDry ? [...argv, '--dry'] : addYes ? [...argv, '--yes'] : argv, dryAdded: addDry, ...(addYes ? { yesAdded: true } : {}), ...(mode === 'plan' ? { skip: 'plan only' } : {}) };
|
return { ...base, kind, argv: addDry ? [...argv, '--dry'] : addYes ? [...argv, '--yes'] : argv, dryAdded: addDry, ...(addYes ? { yesAdded: true } : {}), ...(mode === 'plan' ? { skip: 'plan only' } : {}) };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const PRODUCERS = ['apple build', 'play build'];
|
||||||
|
const CONSUMERS = ['apple upload', 'play upload'];
|
||||||
|
const AFTER_UPLOAD = ['apple testflight wait', 'apple testflight distribute'];
|
||||||
|
|
||||||
|
/** Stores whose artifact (IPA / AAB / PKG) or uploaded build only exists after a real earlier step ("apple", "apple:mac", "play"). */
|
||||||
|
export interface DryPending { built: Set<string>; uploaded: Set<string> }
|
||||||
|
|
||||||
|
const storeKey = (argv: string[]): string => {
|
||||||
|
const i = argv.indexOf('--platform');
|
||||||
|
const mac = (i >= 0 && /^(macos|mac)$/i.test(argv[i + 1] ?? '')) || argv.includes('--tauri');
|
||||||
|
return `${argv[0]}${mac ? ':mac' : ''}`;
|
||||||
|
};
|
||||||
|
|
||||||
|
/** Records a step that ran as a dry run: a dry build leaves no IPA / AAB. Pure. */
|
||||||
|
export function noteDry(p: PlannedStep, pending: DryPending): void {
|
||||||
|
if (!p.argv || !p.dryAdded || p.skip) return;
|
||||||
|
if (PRODUCERS.includes(words(p.argv).slice(0, 2).join(' '))) pending.built.add(storeKey(p.argv));
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Why a step is only planned in a dry run: its input (the IPA / AAB, or the uploaded build) would come from an earlier
|
||||||
|
* step that did not really run. null = run it (always null with --apply: a real upload with no IPA still fails). Pure. */
|
||||||
|
export function plannedForDryInput(p: PlannedStep, mode: Mode, pending: DryPending): string | null {
|
||||||
|
if (mode === 'apply' || !p.argv || p.skip) return null;
|
||||||
|
const w = words(p.argv);
|
||||||
|
const k2 = w.slice(0, 2).join(' ');
|
||||||
|
if (CONSUMERS.includes(k2) && !p.argv.some(a => /\.(ipa|aab|pkg)$/.test(a)) && pending.built.has(storeKey(p.argv))) {
|
||||||
|
pending.uploaded.add(storeKey(p.argv));
|
||||||
|
return `planned: would upload the ${k2 === 'play upload' ? 'AAB' : storeKey(p.argv).endsWith(':mac') ? 'PKG' : 'IPA'} the ${w[0]} build step writes (dry run: nothing built)`;
|
||||||
|
}
|
||||||
|
if (AFTER_UPLOAD.includes(w.slice(0, 3).join(' ')) && pending.uploaded.has('apple')) return 'planned: the build is not on App Store Connect in a dry run';
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
/** Index of the step to start from: --from <id> (exact, or the first id under a sub-flow prefix). */
|
/** Index of the step to start from: --from <id> (exact, or the first id under a sub-flow prefix). */
|
||||||
export function startIndex(steps: FlowStep[], from: string | undefined): number {
|
export function startIndex(steps: FlowStep[], from: string | undefined): number {
|
||||||
if (!from) return 0;
|
if (!from) return 0;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
// properties through ORG_GRADLE_PROJECT_* variables, so passwords never appear on a command line), and read
|
// properties through ORG_GRADLE_PROJECT_* variables, so passwords never appear on a command line), and read
|
||||||
// package / versionCode / versionName back from the built AAB (its manifest is protocol buffers, aapt2 format).
|
// package / versionCode / versionName back from the built AAB (its manifest is protocol buffers, aapt2 format).
|
||||||
import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs';
|
import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs';
|
||||||
import { join, relative } from 'node:path';
|
import { join, relative, resolve } from 'node:path';
|
||||||
import type { AndroidSigning } from './credentials';
|
import type { AndroidSigning } from './credentials';
|
||||||
import * as rt from './rt';
|
import * as rt from './rt';
|
||||||
import { zipEntries, zipRead } from './zip';
|
import { zipEntries, zipRead } from './zip';
|
||||||
|
|
@ -38,7 +38,8 @@ export function pickGradle(root: string, cfg: PlayBuildConfig = {}): GradleTarge
|
||||||
: ['capacitor.config.ts', 'capacitor.config.json', 'capacitor.config.js'].some(f => existsSync(join(root, f))) ? 'capacitor'
|
: ['capacitor.config.ts', 'capacitor.config.json', 'capacitor.config.js'].some(f => existsSync(join(root, f))) ? 'capacitor'
|
||||||
: (() => { try { const p = JSON.parse(readFileSync(join(root, 'package.json'), 'utf8')); return !!(p.dependencies?.['react-native'] ?? p.devDependencies?.['react-native']); } catch { return false; } })() ? 'react-native'
|
: (() => { try { const p = JSON.parse(readFileSync(join(root, 'package.json'), 'utf8')); return !!(p.dependencies?.['react-native'] ?? p.devDependencies?.['react-native']); } catch { return false; } })() ? 'react-native'
|
||||||
: 'native';
|
: 'native';
|
||||||
const dirs = cfg.dir ? [join(root, cfg.dir)] : [join(root, 'android'), root];
|
// resolve, not join: an absolute play.build.dir / --dir stays absolute (join made an absolute path a folder under the root)
|
||||||
|
const dirs = cfg.dir ? [resolve(root, cfg.dir)] : [join(root, 'android'), root];
|
||||||
let dir = dirs.find(isGradleDir);
|
let dir = dirs.find(isGradleDir);
|
||||||
if (!dir) throw new Error(`no Gradle project (settings.gradle) in ${dirs.map(d => relative(root, d) || '.').join(' or ')}: set play.build.dir${framework === 'capacitor' ? ' (or npx cap add android)' : ''}`);
|
if (!dir) throw new Error(`no Gradle project (settings.gradle) in ${dirs.map(d => relative(root, d) || '.').join(' or ')}: set play.build.dir${framework === 'capacitor' ? ' (or npx cap add android)' : ''}`);
|
||||||
const unity = existsSync(join(dir, 'launcher')) && existsSync(join(dir, 'unityLibrary'));
|
const unity = existsSync(join(dir, 'launcher')) && existsSync(join(dir, 'unityLibrary'));
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
// report. Reads store/appstore.md and store/listing.md (or the config's listing paths).
|
// report. Reads store/appstore.md and store/listing.md (or the config's listing paths).
|
||||||
import { existsSync, readFileSync } from 'node:fs';
|
import { existsSync, readFileSync } from 'node:fs';
|
||||||
import { relative } from 'node:path';
|
import { relative } from 'node:path';
|
||||||
import type { Loaded } from './config';
|
import { listingPathFor, type Loaded } from './config';
|
||||||
import { fileMentions, type PlatformHit } from './cross-store';
|
import { fileMentions, type PlatformHit } from './cross-store';
|
||||||
|
|
||||||
export function listingFileMentions(loaded: Pick<Loaded, 'config' | 'resolve' | 'root'>, stores: { apple: boolean; play: boolean } = { apple: true, play: true }): PlatformHit[] {
|
export function listingFileMentions(loaded: Pick<Loaded, 'config' | 'resolve' | 'root'>, stores: { apple: boolean; play: boolean } = { apple: true, play: true }): PlatformHit[] {
|
||||||
|
|
@ -11,6 +11,7 @@ export function listingFileMentions(loaded: Pick<Loaded, 'config' | 'resolve' |
|
||||||
const out: PlatformHit[] = [];
|
const out: PlatformHit[] = [];
|
||||||
const files: ['apple' | 'play', string | null][] = [
|
const files: ['apple' | 'play', string | null][] = [
|
||||||
['apple', stores.apple && config.apple ? resolve(config.apple.listing ?? 'store/appstore.md') : null],
|
['apple', stores.apple && config.apple ? resolve(config.apple.listing ?? 'store/appstore.md') : null],
|
||||||
|
['apple', stores.apple && config.apple?.macos?.listing ? resolve(listingPathFor(config, 'macos')) : null],
|
||||||
['play', stores.play && config.play ? resolve(config.play.listing ?? 'store/listing.md') : null],
|
['play', stores.play && config.play ? resolve(config.play.listing ?? 'store/listing.md') : null],
|
||||||
];
|
];
|
||||||
for (const [store, f] of files) if (f && existsSync(f)) out.push(...fileMentions(store, relative(root, f) || f, readFileSync(f, 'utf8'), allow));
|
for (const [store, f] of files) if (f && existsSync(f)) out.push(...fileMentions(store, relative(root, f) || f, readFileSync(f, 'utf8'), allow));
|
||||||
|
|
|
||||||
|
|
@ -38,6 +38,8 @@ export interface VersionPlan {
|
||||||
/** The editable version that is kept or updated. */
|
/** The editable version that is kept or updated. */
|
||||||
id?: string;
|
id?: string;
|
||||||
reason: string;
|
reason: string;
|
||||||
|
/** Said in the dry run and the real run (e.g. a release type that differs from the previous version's). */
|
||||||
|
warning?: string;
|
||||||
existing: VersionInfo[];
|
existing: VersionInfo[];
|
||||||
changes: FieldDiff[];
|
changes: FieldDiff[];
|
||||||
attributes: Record<string, string>;
|
attributes: Record<string, string>;
|
||||||
|
|
@ -69,7 +71,7 @@ export const versionInfos = (rows: { id: string; attributes: Record<string, unkn
|
||||||
* string changes only while PREPARE_FOR_SUBMISSION), create a new one, or refuse (the number exists, is not higher than
|
* string changes only while PREPARE_FOR_SUBMISSION), create a new one, or refuse (the number exists, is not higher than
|
||||||
* a version that went through review, or another version is in review / pending release). Pure.
|
* a version that went through review, or another version is in review / pending release). Pure.
|
||||||
*/
|
*/
|
||||||
export function planVersion(rows: { id: string; attributes: Record<string, unknown> }[], want: string, attrs: { copyright: string; releaseType: string }, platform = 'IOS'): VersionPlan {
|
export function planVersion(rows: { id: string; attributes: Record<string, unknown> }[], want: string, attrs: { copyright: string; releaseType?: string; earliestReleaseDate?: string }, platform = 'IOS'): VersionPlan {
|
||||||
const existing = versionInfos(rows);
|
const existing = versionInfos(rows);
|
||||||
const editable = existing.find(v => EDITABLE_STATES.has(v.state));
|
const editable = existing.find(v => EDITABLE_STATES.has(v.state));
|
||||||
const others = existing.filter(v => v !== editable);
|
const others = existing.filter(v => v !== editable);
|
||||||
|
|
@ -87,7 +89,8 @@ export function planVersion(rows: { id: string; attributes: Record<string, unkno
|
||||||
return refuse(`version ${want} is not higher than ${higher.versionString} (${higher.state}); App Store versions only go up`);
|
return refuse(`version ${want} is not higher than ${higher.versionString} (${higher.state}); App Store versions only go up`);
|
||||||
if (editable) {
|
if (editable) {
|
||||||
const cur = rows.find(r => r.id === editable.id)!.attributes;
|
const cur = rows.find(r => r.id === editable.id)!.attributes;
|
||||||
const wantAttrs = { versionString: want, copyright: attrs.copyright, releaseType: attrs.releaseType };
|
// releaseType only when asked for (apple.releaseType): an existing version keeps the one it has
|
||||||
|
const wantAttrs: Record<string, string | undefined> = { versionString: want, copyright: attrs.copyright, releaseType: attrs.releaseType, earliestReleaseDate: attrs.releaseType === 'SCHEDULED' ? attrs.earliestReleaseDate : undefined };
|
||||||
const p = planItem(editable.id, { id: editable.id, attributes: cur }, wantAttrs);
|
const p = planItem(editable.id, { id: editable.id, attributes: cur }, wantAttrs);
|
||||||
if (editable.versionString !== want && editable.state !== 'PREPARE_FOR_SUBMISSION')
|
if (editable.versionString !== want && editable.state !== 'PREPARE_FOR_SUBMISSION')
|
||||||
return refuse(`the editable version ${editable.versionString} is ${editable.state}; its version string changes only while PREPARE_FOR_SUBMISSION (use --version ${editable.versionString}, or change it in App Store Connect)`);
|
return refuse(`the editable version ${editable.versionString} is ${editable.state}; its version string changes only while PREPARE_FOR_SUBMISSION (use --version ${editable.versionString}, or change it in App Store Connect)`);
|
||||||
|
|
@ -102,8 +105,17 @@ export function planVersion(rows: { id: string; attributes: Record<string, unkno
|
||||||
if (busy) return refuse(`version ${busy.versionString} is ${busy.state}; App Store Connect allows one version in progress (${busy.state === 'PENDING_DEVELOPER_RELEASE'
|
if (busy) return refuse(`version ${busy.versionString} is ${busy.state}; App Store Connect allows one version in progress (${busy.state === 'PENDING_DEVELOPER_RELEASE'
|
||||||
? `release it first: storebound apple release --manual-release --version ${busy.versionString} --dry, then without --dry`
|
? `release it first: storebound apple release --manual-release --version ${busy.versionString} --dry, then without --dry`
|
||||||
: busy.state === 'WAITING_FOR_REVIEW' || busy.state === 'IN_REVIEW' ? 'wait for the review, or remove it from review in App Store Connect' : 'wait for its release or remove it from review'})`);
|
: busy.state === 'WAITING_FOR_REVIEW' || busy.state === 'IN_REVIEW' ? 'wait for the review, or remove it from review in App Store Connect' : 'wait for its release or remove it from review'})`);
|
||||||
const attributes = { platform, versionString: want, copyright: attrs.copyright, releaseType: attrs.releaseType };
|
// without apple.releaseType a new version keeps the release type of the newest one before it (Acme 2026-10-29: an
|
||||||
return { ...base, action: 'create', reason: `create version ${want} (no editable ${PLATFORM_LABEL[platform] ?? platform} version)`, changes: Object.entries(attributes).map(([field, to]) => ({ field, from: null, to })), attributes };
|
// app the owner set to release after approval got a MANUAL 2.0.2 and would have sat unreleased); a first version is MANUAL
|
||||||
|
const prev = others.slice().sort((a, b) => compareVersions(b.versionString, a.versionString))[0];
|
||||||
|
const prevType = prev ? rows.find(r => r.id === prev.id)?.attributes.releaseType : undefined;
|
||||||
|
const inherited = !attrs.releaseType && typeof prevType === 'string' && ['MANUAL', 'AFTER_APPROVAL'].includes(prevType) ? prevType : undefined;
|
||||||
|
const attributes: Record<string, string> = { platform, versionString: want, copyright: attrs.copyright, releaseType: attrs.releaseType ?? inherited ?? 'MANUAL' };
|
||||||
|
if (attributes.releaseType === 'SCHEDULED' && attrs.earliestReleaseDate) attributes.earliestReleaseDate = attrs.earliestReleaseDate;
|
||||||
|
const why = attrs.releaseType ? 'apple.releaseType' : inherited ? `as version ${prev!.versionString}` : prev ? `version ${prev.versionString} has ${String(prevType ?? 'no readable type')}` : 'first version';
|
||||||
|
return { ...base, action: 'create', reason: `create version ${want} (no editable ${PLATFORM_LABEL[platform] ?? platform} version), release type ${attributes.releaseType} (${why})`,
|
||||||
|
changes: Object.entries(attributes).map(([field, to]) => ({ field, from: null, to })), attributes,
|
||||||
|
...(attrs.releaseType && typeof prevType === 'string' && prevType !== attrs.releaseType ? { warning: `release type ${attrs.releaseType} (apple.releaseType) differs from version ${prev!.versionString} (${prevType})` } : {}) };
|
||||||
}
|
}
|
||||||
|
|
||||||
// ---- translation drafts ----
|
// ---- translation drafts ----
|
||||||
|
|
|
||||||
151
cli/lib/mas.ts
151
cli/lib/mas.ts
|
|
@ -18,20 +18,52 @@ export interface TauriProject {
|
||||||
category?: string;
|
category?: string;
|
||||||
minOs?: string;
|
minOs?: string;
|
||||||
entitlements?: string;
|
entitlements?: string;
|
||||||
|
/** The overlay file merged over the base config (tauri.<name>.conf.json), absolute; passed to `tauri build --config` too. */
|
||||||
|
overlayPath?: string;
|
||||||
|
/** True when the overlay was found next to tauri.conf.json without being named (tauri.appstore.conf.json / tauri.mas.conf.json). */
|
||||||
|
overlayAuto?: boolean;
|
||||||
conf: Record<string, unknown>;
|
conf: Record<string, unknown>;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Overlay files that are picked up on their own for a Mac App Store build, in this order. */
|
||||||
|
export const MAS_OVERLAY_NAMES = ['tauri.appstore.conf.json', 'tauri.mas.conf.json'] as const;
|
||||||
|
|
||||||
|
/** JSON merge patch (RFC 7386, what Tauri's --config does): objects merge, null removes a key, anything else (arrays too) replaces. */
|
||||||
|
export function mergePatch(base: unknown, patch: unknown): unknown {
|
||||||
|
if (patch === null || typeof patch !== 'object' || Array.isArray(patch)) return patch;
|
||||||
|
const out: Record<string, unknown> = base !== null && typeof base === 'object' && !Array.isArray(base) ? { ...(base as Record<string, unknown>) } : {};
|
||||||
|
for (const [k, v] of Object.entries(patch as Record<string, unknown>)) {
|
||||||
|
if (v === null) delete out[k];
|
||||||
|
else out[k] = mergePatch(out[k], v);
|
||||||
|
}
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** tauri.<name>.conf.json (an overlay), not tauri.conf.json itself. */
|
||||||
|
export const isOverlayFile = (p: string): boolean => /(^|[\\/])tauri\.[^\\/]+\.conf\.json$/.test(p);
|
||||||
|
|
||||||
const SKIP = new Set(['node_modules', 'target', '.git', 'dist', 'build', '.storebound', 'Pods']);
|
const SKIP = new Set(['node_modules', 'target', '.git', 'dist', 'build', '.storebound', 'Pods']);
|
||||||
|
|
||||||
/** The Tauri project: `hint` (a folder with tauri.conf.json, or the file itself) or the only tauri.conf.json found. */
|
/** The Tauri project: `hint` (a folder with tauri.conf.json, or a tauri.conf.json / tauri.conf.json5 / tauri.<name>.conf.json
|
||||||
|
* file) or the only tauri.conf.json found. An overlay file (tauri.<name>.conf.json) is merged over the base
|
||||||
|
* tauri.conf.json of its folder; tauri.appstore.conf.json / tauri.mas.conf.json next to the base config is picked up on its own. */
|
||||||
export function findTauri(root: string, hint?: string): TauriProject {
|
export function findTauri(root: string, hint?: string): TauriProject {
|
||||||
const names = ['tauri.conf.json', 'tauri.conf.json5'];
|
const names = ['tauri.conf.json', 'tauri.conf.json5'];
|
||||||
let confPath: string | undefined;
|
let confPath: string | undefined, overlayPath: string | undefined, overlayAuto = false;
|
||||||
|
const autoOverlay = (): void => { const o = MAS_OVERLAY_NAMES.map(n => join(dirname(confPath!), n)).find(existsSync); if (o) { overlayPath = o; overlayAuto = true; } };
|
||||||
if (hint && hint !== 'true') {
|
if (hint && hint !== 'true') {
|
||||||
const p = join(root, hint);
|
const p = join(root, hint);
|
||||||
if (/tauri\.conf\.json5?$/.test(p) && existsSync(p)) confPath = p;
|
if (isOverlayFile(p)) {
|
||||||
else confPath = names.map(n => join(p, n)).find(existsSync);
|
if (!existsSync(p)) throw new Error(`--tauri ${hint}: no such file`);
|
||||||
if (!confPath) throw new Error(`--tauri ${hint}: no tauri.conf.json in it`);
|
overlayPath = p;
|
||||||
|
confPath = names.map(n => join(dirname(p), n)).find(existsSync);
|
||||||
|
if (!confPath) throw new Error(`--tauri ${hint}: no tauri.conf.json next to this overlay (the base config it is merged over)`);
|
||||||
|
} else {
|
||||||
|
if (/tauri\.conf\.json5?$/.test(p) && existsSync(p)) confPath = p;
|
||||||
|
else confPath = names.map(n => join(p, n)).find(existsSync);
|
||||||
|
if (!confPath) throw new Error(`--tauri ${hint}: no tauri.conf.json in it`);
|
||||||
|
autoOverlay();
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
const hits: string[] = [];
|
const hits: string[] = [];
|
||||||
const walk = (dir: string, d: number): void => {
|
const walk = (dir: string, d: number): void => {
|
||||||
|
|
@ -43,16 +75,22 @@ export function findTauri(root: string, hint?: string): TauriProject {
|
||||||
walk(root, 4);
|
walk(root, 4);
|
||||||
if (hits.length !== 1) throw new Error(hits.length ? `several Tauri projects (${hits.map(h => relative(root, h)).join(', ')}): pass --tauri <folder with tauri.conf.json>` : 'no tauri.conf.json found: pass --tauri <folder with tauri.conf.json>');
|
if (hits.length !== 1) throw new Error(hits.length ? `several Tauri projects (${hits.map(h => relative(root, h)).join(', ')}): pass --tauri <folder with tauri.conf.json>` : 'no tauri.conf.json found: pass --tauri <folder with tauri.conf.json>');
|
||||||
confPath = hits[0]!;
|
confPath = hits[0]!;
|
||||||
|
autoOverlay();
|
||||||
}
|
}
|
||||||
let conf: Record<string, any>;
|
let conf: Record<string, any>;
|
||||||
try { conf = JSON.parse(readFileSync(confPath, 'utf8')); } catch (e) { throw new Error(`${confPath}: not valid JSON (${(e as Error).message}); tauri.conf.json5 / Tauri.toml are not read, use tauri.conf.json`); }
|
try { conf = JSON.parse(readFileSync(confPath, 'utf8')); } catch (e) { throw new Error(`${confPath}: not valid JSON (${(e as Error).message}); tauri.conf.json5 / Tauri.toml are not read, use tauri.conf.json`); }
|
||||||
|
if (overlayPath) {
|
||||||
|
let patch: unknown;
|
||||||
|
try { patch = JSON.parse(readFileSync(overlayPath, 'utf8')); } catch (e) { throw new Error(`${overlayPath}: not valid JSON (${(e as Error).message})`); }
|
||||||
|
conf = mergePatch(conf, patch) as Record<string, any>;
|
||||||
|
}
|
||||||
const mac = conf.bundle?.macOS ?? {};
|
const mac = conf.bundle?.macOS ?? {};
|
||||||
const productName = String(conf.productName ?? '');
|
const productName = String(conf.productName ?? '');
|
||||||
if (!productName) throw new Error(`${confPath}: productName is missing`);
|
if (!productName) throw new Error(`${confPath}: productName is missing`);
|
||||||
const dir = dirname(confPath);
|
const dir = dirname(confPath);
|
||||||
return { dir, confPath, cwd: dirname(dir), productName, identifier: String(conf.identifier ?? ''), version: typeof conf.version === 'string' ? conf.version : undefined,
|
return { dir, confPath, cwd: dirname(dir), productName, identifier: String(conf.identifier ?? ''), version: typeof conf.version === 'string' ? conf.version : undefined,
|
||||||
category: typeof conf.bundle?.category === 'string' ? conf.bundle.category : undefined, minOs: typeof mac.minimumSystemVersion === 'string' ? mac.minimumSystemVersion : undefined,
|
category: typeof conf.bundle?.category === 'string' ? conf.bundle.category : undefined, minOs: typeof mac.minimumSystemVersion === 'string' ? mac.minimumSystemVersion : undefined,
|
||||||
entitlements: typeof mac.entitlements === 'string' ? join(dir, mac.entitlements) : undefined, conf };
|
entitlements: typeof mac.entitlements === 'string' ? join(dir, mac.entitlements) : undefined, ...(overlayPath ? { overlayPath, overlayAuto } : {}), conf };
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Tauri's category names (and Apple's public.app-category.* ids) -> the LSApplicationCategoryType Tauri writes; null when unknown. */
|
/** Tauri's category names (and Apple's public.app-category.* ids) -> the LSApplicationCategoryType Tauri writes; null when unknown. */
|
||||||
|
|
@ -79,6 +117,43 @@ export function masEntitlements(o: { teamId: string; bundleId: string; existing?
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Where the entitlements of a Mac App Store build come from, first hit wins: `--entitlements <plist>`, the config's
|
||||||
|
* `apple.macos.entitlements`, the merged Tauri config's `bundle.macOS.entitlements`. Paths are already absolute. Pure. */
|
||||||
|
export function entitlementsSource(o: { flag?: string; config?: string; tauri?: string }): { file: string; source: string } | null {
|
||||||
|
if (o.flag) return { file: o.flag, source: '--entitlements' };
|
||||||
|
if (o.config) return { file: o.config, source: 'apple.macos.entitlements' };
|
||||||
|
if (o.tauri) return { file: o.tauri, source: 'tauri config bundle.macOS.entitlements' };
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Entitlements that App Store Connect refuses in a Mac App Store build (a Developer ID / development leftover). */
|
||||||
|
export const MAS_REFUSED_KEYS: Record<string, string> = {
|
||||||
|
'com.apple.security.get-task-allow': 'a development entitlement, App Store Connect refuses it',
|
||||||
|
'com.apple.security.cs.disable-library-validation': 'a Developer ID hardened-runtime exception, App Store Connect refuses it',
|
||||||
|
};
|
||||||
|
|
||||||
|
/** Hardened-runtime exceptions and Developer ID habits that do not belong in a Mac App Store build. App Review may
|
||||||
|
* question them or the sandbox ignores them, but they are not an automatic upload refusal: a warning, not a stop. */
|
||||||
|
export const MAS_SUSPECT_KEYS: Record<string, string> = {
|
||||||
|
'com.apple.security.cs.allow-jit': 'hardened-runtime exception for Developer ID builds; App Review asks why a sandboxed app needs it',
|
||||||
|
'com.apple.security.cs.allow-unsigned-executable-memory': 'hardened-runtime exception for Developer ID builds; App Review asks why',
|
||||||
|
'com.apple.security.cs.disable-executable-page-protection': 'hardened-runtime exception for Developer ID builds',
|
||||||
|
'com.apple.security.cs.allow-dyld-environment-variables': 'hardened-runtime exception for Developer ID builds',
|
||||||
|
'com.apple.security.cs.debugger': 'hardened-runtime exception for Developer ID builds (a debugger cannot be sandboxed)',
|
||||||
|
'com.apple.security.automation.apple-events': 'needs NSAppleEventsUsageDescription in Info.plist and a reason in the review notes; usually a Developer ID leftover',
|
||||||
|
};
|
||||||
|
|
||||||
|
/** The entitlements of a Mac App Store build against the two lists above (a key set to false is fine). Pure. */
|
||||||
|
export function masEntitlementProblems(ent: Record<string, PlistValue> | null | undefined): { errors: string[]; warnings: string[] } {
|
||||||
|
const errors: string[] = [], warnings: string[] = [];
|
||||||
|
for (const [k, v] of Object.entries(ent ?? {})) {
|
||||||
|
if (v === false) continue;
|
||||||
|
if (MAS_REFUSED_KEYS[k]) errors.push(`${k} is set: ${MAS_REFUSED_KEYS[k]}`);
|
||||||
|
else if (MAS_SUSPECT_KEYS[k]) warnings.push(`${k} is set: ${MAS_SUSPECT_KEYS[k]}`);
|
||||||
|
}
|
||||||
|
return { errors, warnings };
|
||||||
|
}
|
||||||
|
|
||||||
export const entitlementsXml = (e: Record<string, PlistValue>): string => toXmlPlist(e);
|
export const entitlementsXml = (e: Record<string, PlistValue>): string => toXmlPlist(e);
|
||||||
|
|
||||||
/** Keys of an entitlements plist (XML or what `codesign -d --entitlements :-` prints). */
|
/** Keys of an entitlements plist (XML or what `codesign -d --entitlements :-` prints). */
|
||||||
|
|
@ -170,7 +245,7 @@ export const leakNeedles = (home: string, user: string, root: string): string[]
|
||||||
export interface AppFacts { info: Record<string, PlistValue>; entitlements: Record<string, PlistValue> | null; hasProfile: boolean; leaks: Leak[] }
|
export interface AppFacts { info: Record<string, PlistValue>; entitlements: Record<string, PlistValue> | null; hasProfile: boolean; leaks: Leak[] }
|
||||||
|
|
||||||
/** Problems (stop) and warnings of a built .app before it goes into a .pkg. Pure. */
|
/** Problems (stop) and warnings of a built .app before it goes into a .pkg. Pure. */
|
||||||
export function appProblems(f: AppFacts, o: { bundleId: string; version: string; build: string; signed: boolean; pathFree: boolean }): { errors: string[]; warnings: string[] } {
|
export function appProblems(f: AppFacts, o: { bundleId: string; version: string; build: string; signed: boolean; pathFree: boolean; allowEntitlements?: boolean }): { errors: string[]; warnings: string[] } {
|
||||||
const errors: string[] = [], warnings: string[] = [];
|
const errors: string[] = [], warnings: string[] = [];
|
||||||
const s = (k: string): string | undefined => (typeof f.info[k] === 'string' ? f.info[k] as string : undefined);
|
const s = (k: string): string | undefined => (typeof f.info[k] === 'string' ? f.info[k] as string : undefined);
|
||||||
if (s('CFBundleIdentifier') !== o.bundleId) errors.push(`CFBundleIdentifier is ${s('CFBundleIdentifier') ?? 'missing'}, not ${o.bundleId}`);
|
if (s('CFBundleIdentifier') !== o.bundleId) errors.push(`CFBundleIdentifier is ${s('CFBundleIdentifier') ?? 'missing'}, not ${o.bundleId}`);
|
||||||
|
|
@ -184,7 +259,9 @@ export function appProblems(f: AppFacts, o: { bundleId: string; version: string;
|
||||||
else {
|
else {
|
||||||
for (const k of MAS_REQUIRED) if (f.entitlements[k] === undefined) errors.push(`entitlement ${k} is missing`);
|
for (const k of MAS_REQUIRED) if (f.entitlements[k] === undefined) errors.push(`entitlement ${k} is missing`);
|
||||||
if (f.entitlements['com.apple.security.app-sandbox'] !== true) errors.push('com.apple.security.app-sandbox is not true');
|
if (f.entitlements['com.apple.security.app-sandbox'] !== true) errors.push('com.apple.security.app-sandbox is not true');
|
||||||
if (f.entitlements['com.apple.security.get-task-allow'] === true) errors.push('com.apple.security.get-task-allow is true: a development entitlement, App Store Connect refuses it');
|
const ep = masEntitlementProblems(f.entitlements);
|
||||||
|
(o.allowEntitlements ? warnings : errors).push(...ep.errors);
|
||||||
|
warnings.push(...ep.warnings);
|
||||||
}
|
}
|
||||||
if (!f.hasProfile) errors.push('Contents/embedded.provisionprofile is missing: a Mac App Store app needs its provisioning profile inside (Tauri bundle.macOS.files)');
|
if (!f.hasProfile) errors.push('Contents/embedded.provisionprofile is missing: a Mac App Store app needs its provisioning profile inside (Tauri bundle.macOS.files)');
|
||||||
}
|
}
|
||||||
|
|
@ -230,7 +307,7 @@ export interface MasPlanInput {
|
||||||
export function masSteps(i: MasPlanInput): { tauri: string[]; productbuild: string[]; codesignVerify: string[]; pkgCheck: string[] } {
|
export function masSteps(i: MasPlanInput): { tauri: string[]; productbuild: string[]; codesignVerify: string[]; pkgCheck: string[] } {
|
||||||
const appPath = join(i.tauri.dir, 'target', i.target, 'release', 'bundle', 'macos', `${i.tauri.productName}.app`);
|
const appPath = join(i.tauri.dir, 'target', i.target, 'release', 'bundle', 'macos', `${i.tauri.productName}.app`);
|
||||||
return {
|
return {
|
||||||
tauri: [...i.tauriCmd, 'build', '--bundles', 'app', '--target', i.target, '--config', i.configFile],
|
tauri: [...i.tauriCmd, 'build', '--bundles', 'app', '--target', i.target, ...(i.tauri.overlayPath ? ['--config', i.tauri.overlayPath] : []), '--config', i.configFile],
|
||||||
codesignVerify: ['codesign', '--verify', '--deep', '--strict', '--verbose=2', appPath],
|
codesignVerify: ['codesign', '--verify', '--deep', '--strict', '--verbose=2', appPath],
|
||||||
productbuild: ['productbuild', '--component', appPath, '/Applications', ...(i.unsigned || !i.installerIdentity ? [] : ['--sign', i.installerIdentity]), i.pkg],
|
productbuild: ['productbuild', '--component', appPath, '/Applications', ...(i.unsigned || !i.installerIdentity ? [] : ['--sign', i.installerIdentity]), i.pkg],
|
||||||
pkgCheck: ['pkgutil', '--check-signature', i.pkg],
|
pkgCheck: ['pkgutil', '--check-signature', i.pkg],
|
||||||
|
|
@ -271,29 +348,51 @@ export function readAppInfo(appDir: string): Record<string, PlistValue> {
|
||||||
return parsePlist(readFileSync(p)) as Record<string, PlistValue>;
|
return parsePlist(readFileSync(p)) as Record<string, PlistValue>;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** What bounds and reports the .pkg reading (tests inject a fake spawnSync and short limits). */
|
||||||
|
export interface PkgInfoOptions { say?: (msg: string) => void; spawnSync?: typeof rt.spawnSync; checkMs?: number; expandMs?: number }
|
||||||
|
/** pkgutil --check-signature evaluates the certificate chain (revocation lookups over the network): never unbounded. */
|
||||||
|
export const PKG_CHECK_MS = 90_000;
|
||||||
|
/** pkgutil --expand copies the whole archive to a temp folder: minutes for a big app, never unbounded. */
|
||||||
|
export const PKG_EXPAND_MS = 5 * 60_000;
|
||||||
|
|
||||||
/** bundle id, version and build of a .pkg: pkgutil --expand on a Mac (PackageInfo), else the <pkg>.json next to it that
|
/** bundle id, version and build of a .pkg: pkgutil --expand on a Mac (PackageInfo), else the <pkg>.json next to it that
|
||||||
* `apple build --platform macos` wrote. Refuses an unsigned or wrongly signed .pkg when pkgutil is there. */
|
* `apple build --platform macos` wrote. Refuses an unsigned or wrongly signed .pkg when pkgutil is there. Both pkgutil
|
||||||
export function pkgInfo(pkg: string, expectBundleId?: string): { bundleId: string; version: string; build: string } {
|
* calls have a timeout (no stdin, so no prompt) and say what they do first; one that times out falls back to the
|
||||||
if (rt.which('pkgutil')) {
|
* .json file, else it fails with the reason (a silent hang over SSH, 10 min, was this read). */
|
||||||
const sig = parsePkgSignature(rt.spawnSync(['pkgutil', '--check-signature', pkg], { stdout: 'pipe', stderr: 'pipe' }).stdout.toString());
|
export function pkgInfo(pkg: string, expectBundleId?: string, o: PkgInfoOptions = {}): { bundleId: string; version: string; build: string } {
|
||||||
const bad = pkgProblems(sig);
|
const say = o.say ?? (() => {});
|
||||||
if (bad.length) throw new Error(`${basename(pkg)}: not uploaded:\n${bad.map(x => ` ${x}`).join('\n')}`);
|
const spawnSync = o.spawnSync ?? rt.spawnSync;
|
||||||
const tmp = join(process.env.TMPDIR ?? '/tmp', `sb-pkg-${process.pid}-${Date.now()}`);
|
|
||||||
try {
|
|
||||||
if (rt.spawnSync(['pkgutil', '--expand', pkg, tmp], { stdout: 'pipe', stderr: 'pipe' }).exitCode === 0) {
|
|
||||||
for (const d of readdirSync(tmp)) {
|
|
||||||
const p = join(tmp, d, 'PackageInfo');
|
|
||||||
const info = existsSync(p) ? parsePackageInfo(readFileSync(p, 'utf8')) : null;
|
|
||||||
if (info && (!expectBundleId || info.bundleId === expectBundleId)) return info;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} finally { try { rmSync(tmp, { recursive: true, force: true }); } catch { /* temp */ } }
|
|
||||||
}
|
|
||||||
const side = `${pkg}.json`;
|
const side = `${pkg}.json`;
|
||||||
|
let timedOut = '';
|
||||||
|
if (rt.which('pkgutil') || o.spawnSync) {
|
||||||
|
const checkMs = o.checkMs ?? PKG_CHECK_MS, expandMs = o.expandMs ?? PKG_EXPAND_MS;
|
||||||
|
say(`checking the signature of ${basename(pkg)} (pkgutil --check-signature, up to ${Math.round(checkMs / 1000)} s)`);
|
||||||
|
const chk = spawnSync(['pkgutil', '--check-signature', pkg], { stdout: 'pipe', stderr: 'pipe', timeout: checkMs });
|
||||||
|
if (chk.exitCode === null && chk.signalCode) timedOut = `pkgutil --check-signature gave no answer in ${Math.round(checkMs / 1000)} s (it checks the certificate chain over the network)`;
|
||||||
|
else {
|
||||||
|
const bad = pkgProblems(parsePkgSignature(chk.stdout.toString()));
|
||||||
|
if (bad.length) throw new Error(`${basename(pkg)}: not uploaded:\n${bad.map(x => ` ${x}`).join('\n')}`);
|
||||||
|
const tmp = join(process.env.TMPDIR ?? '/tmp', `sb-pkg-${process.pid}-${Date.now()}`);
|
||||||
|
say(`reading bundle id, version and build (pkgutil --expand, up to ${Math.round(expandMs / 1000)} s; a big package takes a while)`);
|
||||||
|
try {
|
||||||
|
const ex = spawnSync(['pkgutil', '--expand', pkg, tmp], { stdout: 'pipe', stderr: 'pipe', timeout: expandMs });
|
||||||
|
if (ex.exitCode === null && ex.signalCode) timedOut = `pkgutil --expand gave no answer in ${Math.round(expandMs / 1000)} s`;
|
||||||
|
else if (ex.exitCode === 0) {
|
||||||
|
for (const d of readdirSync(tmp)) {
|
||||||
|
const p = join(tmp, d, 'PackageInfo');
|
||||||
|
const info = existsSync(p) ? parsePackageInfo(readFileSync(p, 'utf8')) : null;
|
||||||
|
if (info && (!expectBundleId || info.bundleId === expectBundleId)) return info;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} finally { try { rmSync(tmp, { recursive: true, force: true }); } catch { /* temp */ } }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (timedOut) say(`${timedOut}: using ${basename(side)} (written by apple build) instead`);
|
||||||
if (existsSync(side)) {
|
if (existsSync(side)) {
|
||||||
const j = JSON.parse(readFileSync(side, 'utf8')) as { bundleId?: string; version?: string; build?: string; unsigned?: boolean };
|
const j = JSON.parse(readFileSync(side, 'utf8')) as { bundleId?: string; version?: string; build?: string; unsigned?: boolean };
|
||||||
if (j.unsigned) throw new Error(`${basename(pkg)} was built with --unsigned: the Mac App Store refuses it`);
|
if (j.unsigned) throw new Error(`${basename(pkg)} was built with --unsigned: the Mac App Store refuses it`);
|
||||||
if (j.bundleId && j.version && j.build) return { bundleId: j.bundleId, version: j.version, build: j.build };
|
if (j.bundleId && j.version && j.build) return { bundleId: j.bundleId, version: j.version, build: j.build };
|
||||||
}
|
}
|
||||||
|
if (timedOut) throw new Error(`${basename(pkg)}: ${timedOut}, and there is no ${basename(side)} file from apple build to read instead: run it in the Mac's logged-in GUI session, or check the Mac's network`);
|
||||||
throw new Error(`${basename(pkg)}: cannot read bundle id / version / build (needs pkgutil on a Mac, or the ${basename(side)} file apple build wrote)`);
|
throw new Error(`${basename(pkg)}: cannot read bundle id / version / build (needs pkgutil on a Mac, or the ${basename(side)} file apple build wrote)`);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,9 @@
|
||||||
// folders (package.json "workspaces", npm / yarn / pnpm-style array or { packages }, as Bun reads them) and local
|
// folders (package.json "workspaces", npm / yarn / pnpm-style array or { packages }, as Bun reads them) and local
|
||||||
// SwiftPM packages (`.package(path:)` in a Package.swift, e.g. Capacitor 8's CapApp-SPM). Used by `privacy-manifest`
|
// SwiftPM packages (`.package(path:)` in a Package.swift, e.g. Capacitor 8's CapApp-SPM). Used by `privacy-manifest`
|
||||||
// and `scan`. Read-only; never throws.
|
// and `scan`. Read-only; never throws.
|
||||||
import { existsSync, readdirSync, readFileSync, realpathSync, statSync } from 'node:fs';
|
import { type Dirent, existsSync, readdirSync, readFileSync, realpathSync, statSync } from 'node:fs';
|
||||||
import { dirname, join, resolve } from 'node:path';
|
import { dirname, join, resolve } from 'node:path';
|
||||||
|
import { skipDir } from './walk-skip';
|
||||||
|
|
||||||
interface PkgJson { name?: string; dependencies?: Record<string, string>; workspaces?: string[] | { packages?: string[] } }
|
interface PkgJson { name?: string; dependencies?: Record<string, string>; workspaces?: string[] | { packages?: string[] } }
|
||||||
const readJson = (p: string): PkgJson | null => { try { return JSON.parse(readFileSync(p, 'utf8')) as PkgJson; } catch { return null; } };
|
const readJson = (p: string): PkgJson | null => { try { return JSON.parse(readFileSync(p, 'utf8')) as PkgJson; } catch { return null; } };
|
||||||
|
|
@ -67,9 +68,10 @@ export function localSwiftPackages(dir: string): string[] {
|
||||||
const skip = new Set(['Pods', 'build', 'DerivedData', 'node_modules', '.build', 'SourcePackages', '.git', 'xcuserdata']);
|
const skip = new Set(['Pods', 'build', 'DerivedData', 'node_modules', '.build', 'SourcePackages', '.git', 'xcuserdata']);
|
||||||
const walk = (d: string, depth: number) => {
|
const walk = (d: string, depth: number) => {
|
||||||
if (depth > 4) return;
|
if (depth > 4) return;
|
||||||
let names: string[] = [];
|
let ents: Dirent[] = [];
|
||||||
try { names = readdirSync(d); } catch { return; }
|
try { ents = readdirSync(d, { withFileTypes: true }); } catch { return; }
|
||||||
for (const n of names) {
|
for (const e of ents) {
|
||||||
|
const n = e.name;
|
||||||
if (skip.has(n)) continue;
|
if (skip.has(n)) continue;
|
||||||
const p = join(d, n);
|
const p = join(d, n);
|
||||||
if (n === 'Package.swift') {
|
if (n === 'Package.swift') {
|
||||||
|
|
@ -79,7 +81,7 @@ export function localSwiftPackages(dir: string): string[] {
|
||||||
const target = resolve(d, m[1]!);
|
const target = resolve(d, m[1]!);
|
||||||
if (isDir(target)) out.push(target);
|
if (isDir(target)) out.push(target);
|
||||||
}
|
}
|
||||||
} else if (isDir(p) && !/\.(xc)?framework$|\.xcassets$/.test(n)) walk(p, depth + 1);
|
} else if ((e.isDirectory() || (e.isSymbolicLink() && isDir(p))) && !/\.(xc)?framework$|\.xcassets$/.test(n) && !skipDir(dir, p, n)) walk(p, depth + 1);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
walk(dir, 0);
|
walk(dir, 0);
|
||||||
|
|
|
||||||
103
cli/lib/path-free.ts
Normal file
103
cli/lib/path-free.ts
Normal file
|
|
@ -0,0 +1,103 @@
|
||||||
|
// Path-free iOS builds: no home folder, user name or checkout path inside the app binary or the archive's debug
|
||||||
|
// symbols (a privacy gate over a shared release folder found hundreds of hits). Used by `apple build --path-free`.
|
||||||
|
// - derivedDataFor: DerivedData per output folder (hermetic), not ~/Library/Developer/Xcode/DerivedData
|
||||||
|
// - pathFreeSettings: xcodebuild build settings with Swift / clang prefix maps (dSYM and Symbols stay, paths are remapped)
|
||||||
|
// - scanArchiveLeaks / leakProblem: scan the archive's .app, dSYMs and Symbols for the home folder and the user name
|
||||||
|
// Pure except scanArchiveLeaks (bounded file reads).
|
||||||
|
import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs';
|
||||||
|
import { join, relative, sep } from 'node:path';
|
||||||
|
import { posix } from 'node:path';
|
||||||
|
|
||||||
|
const trim = (p: string): string => (p.length > 1 ? p.replace(/\/+$/, '') : p);
|
||||||
|
|
||||||
|
/** DerivedData folder of a build: --derived-data, else apple.build.derivedData, else <out>/DerivedData when the output
|
||||||
|
* folder was chosen (--out / apple.build.out), else null (Xcode's default under ~/Library). */
|
||||||
|
export function derivedDataFor(o: { flag?: string; config?: string; out: string; outChosen: boolean; resolve: (p: string) => string }): string | null {
|
||||||
|
const given = o.flag ?? o.config;
|
||||||
|
if (given) return o.resolve(given);
|
||||||
|
return o.outChosen ? posix.join(o.out, 'DerivedData') : null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** True when `dir` is not inside `home`. */
|
||||||
|
export const outsideHome = (dir: string, home: string): boolean => { const h = trim(home); return !!h && dir !== h && !dir.startsWith(`${h}/`); };
|
||||||
|
|
||||||
|
export interface PathFreeInput { home: string; root: string; out: string; derivedData?: string | null }
|
||||||
|
|
||||||
|
/** [from, to] prefix maps: the home folder, the checkout, the output folder and DerivedData, longest (most specific) first.
|
||||||
|
* swiftc applies the FIRST matching map, clang the LAST: pathFreeSettings reverses the list for clang. */
|
||||||
|
export function prefixMaps(i: PathFreeInput): [string, string][] {
|
||||||
|
const all: [string, string][] = [[trim(i.home), '/home'], [trim(i.root), '.'], [trim(i.out), '/out']];
|
||||||
|
if (i.derivedData) all.push([trim(i.derivedData), '/derived']);
|
||||||
|
const seen = new Set<string>();
|
||||||
|
return all.filter(([from]) => from.length > 1 && !seen.has(from) && seen.add(from)).sort((a, b) => b[0].length - a[0].length);
|
||||||
|
}
|
||||||
|
|
||||||
|
const q = (s: string): string => (/[\s"'$]/.test(s) ? `"${s.replace(/(["\$])/g, '\$1')}"` : s);
|
||||||
|
|
||||||
|
/** xcodebuild build settings that remap every local path in Swift, C, C++ and Objective-C output and in DWARF. The
|
||||||
|
* debug format is left alone (dwarf-with-dsym), so symbol upload keeps working. */
|
||||||
|
export function pathFreeSettings(i: PathFreeInput): string[] {
|
||||||
|
const maps = prefixMaps(i);
|
||||||
|
const swift = maps.flatMap(([f, t]) => ['-debug-prefix-map', q(`${f}=${t}`), '-file-prefix-map', q(`${f}=${t}`)]);
|
||||||
|
const clang = [...maps].reverse().flatMap(([f, t]) => [q(`-ffile-prefix-map=${f}=${t}`)]);
|
||||||
|
// SWIFT_SERIALIZE_DEBUGGING_OPTIONS=NO: Xcode embeds the compiler's include paths, module cache and -ffile-compilation-dir
|
||||||
|
// (the checkout) in the binary's __swift_ast section; no prefix map reaches it. Only lldb's Swift expression evaluation
|
||||||
|
// uses it; crash symbolication (the dSYM's functions and lines) does not.
|
||||||
|
return ['SWIFT_SERIALIZE_DEBUGGING_OPTIONS=NO', `OTHER_SWIFT_FLAGS=$(inherited) ${swift.join(' ')}`, `OTHER_CFLAGS=$(inherited) ${clang.join(' ')}`, `OTHER_CPLUSPLUSFLAGS=$(inherited) ${clang.join(' ')}`];
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface PathHit { file: string; kind: string; offset: number }
|
||||||
|
|
||||||
|
/** The needles of a leak scan, named by kind so a report never prints the value: the home folder, /Users/<user>/ and the
|
||||||
|
* checkout. DerivedData is no needle: outside the home folder it is not the user's (dsymutil and Xcode record it in the
|
||||||
|
* dSYM and the __swift_ast section and no prefix map reaches it); inside the home folder the home needle finds it. */
|
||||||
|
export function leakNeedles(i: { home: string; user: string; root: string }): { kind: string; value: string }[] {
|
||||||
|
// the checkout is a needle only when it says something about the person: inside the home folder or naming the user.
|
||||||
|
// A shared build folder (/Users/Shared/..., /opt/...) recorded by dsymutil and Xcode's module cache is not private
|
||||||
|
const root = trim(i.root) + '/';
|
||||||
|
const personal = root.startsWith(trim(i.home) + '/') || (i.user.length >= 3 && root.includes(`/${i.user}/`));
|
||||||
|
const list = [{ kind: 'home folder', value: trim(i.home) + '/' }, { kind: 'user folder', value: `/Users/${i.user}/` }, ...(personal ? [{ kind: 'checkout', value: root }] : [])];
|
||||||
|
const seen = new Set<string>();
|
||||||
|
return list.filter(n => n.value.length >= 6 && !seen.has(n.value) && seen.add(n.value));
|
||||||
|
}
|
||||||
|
|
||||||
|
const MAX_FILE = 600 * 1048576;
|
||||||
|
|
||||||
|
/** Every needle occurrence in the files under `dirs` (all of them are counted; the first `perFile` offsets per file kept). */
|
||||||
|
export function scanForPaths(dirs: string[], needles: { kind: string; value: string }[], perFile = 3): { hits: PathHit[]; total: number; files: number } {
|
||||||
|
const ns = needles.map(n => ({ kind: n.kind, b: Buffer.from(n.value) }));
|
||||||
|
const hits: PathHit[] = [];
|
||||||
|
const bad = new Set<string>();
|
||||||
|
let total = 0;
|
||||||
|
const walk = (base: string, d: string): void => {
|
||||||
|
let names: string[]; try { names = readdirSync(d); } catch { return; }
|
||||||
|
for (const name of names) {
|
||||||
|
const p = join(d, name);
|
||||||
|
let st; try { st = statSync(p); } catch { continue; }
|
||||||
|
if (st.isDirectory()) { walk(base, p); continue; }
|
||||||
|
if (!st.isFile() || st.size > MAX_FILE) continue;
|
||||||
|
const buf = readFileSync(p);
|
||||||
|
let kept = 0;
|
||||||
|
for (const { kind, b } of ns) {
|
||||||
|
for (let at = buf.indexOf(b); at >= 0; at = buf.indexOf(b, at + b.length)) {
|
||||||
|
total++; bad.add(p);
|
||||||
|
if (kept++ < perFile) hits.push({ file: relative(base, p).split(sep).join('/'), kind, offset: at });
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
for (const d of dirs) if (existsSync(d)) walk(d, d);
|
||||||
|
return { hits, total, files: bad.size };
|
||||||
|
}
|
||||||
|
|
||||||
|
/** What the archive holds that ships or symbolicates: Products (the .app, extensions, frameworks), dSYMs, Symbols. */
|
||||||
|
export const archiveScanDirs = (archive: string): string[] => ['Products', 'dSYMs', 'Symbols'].map(x => join(archive, x));
|
||||||
|
|
||||||
|
/** The refusal text of a path-free build that still has local paths, else null. Counts, kinds, file and offset only. */
|
||||||
|
export function leakProblem(r: { hits: PathHit[]; total: number; files: number }, archive: string): string | null {
|
||||||
|
if (!r.total) return null;
|
||||||
|
const lines = r.hits.slice(0, 8).map(h => ` ${h.file} @${h.offset}: ${h.kind}`);
|
||||||
|
return `${r.total} local path${r.total === 1 ? '' : 's'} left in ${r.files} file${r.files === 1 ? '' : 's'} of ${archive} (home folder, user name or checkout):\n${lines.join('\n')}${r.hits.length > 8 ? '\n ...' : ''}\n`
|
||||||
|
+ 'Stopped before the export. Causes: #file / #filePath in Swift sources (no prefix map reaches those literals: use #fileID), a prebuilt framework or Pod that carries its own paths '
|
||||||
|
+ '(rebuild it path-free), or DerivedData / --out inside the home folder (dsymutil and Xcode record that path: use --out or --derived-data outside it, e.g. a shared folder).';
|
||||||
|
}
|
||||||
|
|
@ -161,11 +161,15 @@ export function playReleases(data: unknown): StoreRelease[] {
|
||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** A completed Play production release the store page does not show yet. The API has no review state: it may be in
|
||||||
|
* review, or blocked before review (an old build on another track with a policy issue, pitfall 129). Never "In review". */
|
||||||
|
export const PLAY_NOT_LIVE = 'Not live yet: in review or blocked before review (the API cannot tell; see Publishing overview)';
|
||||||
|
|
||||||
/** Plain words for a Play release's phase, decided from the store page (CLI text; the desktop has the same words in
|
/** Plain words for a Play release's phase, decided from the store page (CLI text; the desktop has the same words in
|
||||||
* i18n, apps/desktop/src/ui/kit.tsx phaseLabel). */
|
* i18n, apps/desktop/src/ui/kit.tsx phaseLabel). */
|
||||||
export function playReleaseLabel(r: StoreRelease): string {
|
export function playReleaseLabel(r: StoreRelease): string {
|
||||||
const base = ((): string => {
|
const base = ((): string => {
|
||||||
if (r.phase === 'review' || r.phase === 'sent') return r.managed ? 'In review / ready to publish (managed publishing)' : r.liveVersion ? `In review (live: ${r.liveVersion})` : 'In review';
|
if (r.phase === 'review' || r.phase === 'sent') return r.managed ? 'In review / ready to publish (managed publishing)' : r.liveVersion ? `${PLAY_NOT_LIVE} (live: ${r.liveVersion})` : PLAY_NOT_LIVE;
|
||||||
if (r.phase === 'released') return "Couldn't check the store page";
|
if (r.phase === 'released') return "Couldn't check the store page";
|
||||||
if (r.phase === 'live') return 'Live';
|
if (r.phase === 'live') return 'Live';
|
||||||
if (r.phase === 'rollout') return `Rolling out ${Math.round((r.fraction ?? 0) * 1000) / 10}%`;
|
if (r.phase === 'rollout') return `Rolling out ${Math.round((r.fraction ?? 0) * 1000) / 10}%`;
|
||||||
|
|
|
||||||
|
|
@ -2,9 +2,10 @@
|
||||||
// .xcframework, SwiftPM checkouts, Capacitor / Cordova / React Native plugins in node_modules, a built .app's
|
// .xcframework, SwiftPM checkouts, Capacitor / Cordova / React Native plugins in node_modules, a built .app's
|
||||||
// Frameworks and bundles) and every PrivacyInfo.xcprivacy inside an .ipa or .app (XML or binary). Read-only; the
|
// Frameworks and bundles) and every PrivacyInfo.xcprivacy inside an .ipa or .app (XML or binary). Read-only; the
|
||||||
// directory walk is bounded.
|
// directory walk is bounded.
|
||||||
import { readdirSync, readFileSync, statSync } from 'node:fs';
|
import { type Dirent, readdirSync, readFileSync, statSync } from 'node:fs';
|
||||||
import { basename, join, relative, sep } from 'node:path';
|
import { basename, join, relative, sep } from 'node:path';
|
||||||
import { nativeIosPlugins } from './node-packages';
|
import { nativeIosPlugins } from './node-packages';
|
||||||
|
import { skipDir } from './walk-skip';
|
||||||
import { parseBinaryPlist } from './plist';
|
import { parseBinaryPlist } from './plist';
|
||||||
import { type Manifest, manifestFromPlist, parseManifest, trackingIssue } from './privacy-manifest';
|
import { type Manifest, manifestFromPlist, parseManifest, trackingIssue } from './privacy-manifest';
|
||||||
import { zipEntries, zipRead } from './zip';
|
import { zipEntries, zipRead } from './zip';
|
||||||
|
|
@ -63,15 +64,16 @@ export function bundleTrackingIssues(list: BundleManifest[]): string[] {
|
||||||
|
|
||||||
function walk(dir: string, visit: (p: string, isDir: boolean) => boolean | void, depth = 0, budget = { n: 60_000 }): void {
|
function walk(dir: string, visit: (p: string, isDir: boolean) => boolean | void, depth = 0, budget = { n: 60_000 }): void {
|
||||||
if (depth > 16 || budget.n <= 0) return;
|
if (depth > 16 || budget.n <= 0) return;
|
||||||
let names: string[] = [];
|
let ents: Dirent[] = [];
|
||||||
try { names = readdirSync(dir).sort(); } catch { return; }
|
try { ents = readdirSync(dir, { withFileTypes: true }).sort((a, b) => (a.name < b.name ? -1 : a.name > b.name ? 1 : 0)); } catch { return; }
|
||||||
for (const n of names) {
|
for (const e of ents) {
|
||||||
if (--budget.n <= 0) return;
|
if (--budget.n <= 0) return;
|
||||||
const p = join(dir, n);
|
const p = join(dir, e.name);
|
||||||
let st;
|
// the entry type comes with the listing (no stat per file: a stat each made a big tree take minutes on Windows)
|
||||||
try { st = statSync(p); } catch { continue; }
|
let isDir = e.isDirectory();
|
||||||
const descend = visit(p, st.isDirectory());
|
if (e.isSymbolicLink()) { try { isDir = statSync(p).isDirectory(); } catch { continue; } }
|
||||||
if (st.isDirectory() && descend !== false) walk(p, visit, depth + 1, budget);
|
const descend = visit(p, isDir);
|
||||||
|
if (isDir && descend !== false) walk(p, visit, depth + 1, budget);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -102,7 +104,7 @@ export function projectSdkManifests(root: string): SdkManifest[] {
|
||||||
try { out.push({ sdk, manifest: manifestFromBytes(relative(root, abs).split(sep).join('/'), readFileSync(abs)) }); } catch { /* unreadable */ }
|
try { out.push({ sdk, manifest: manifestFromBytes(relative(root, abs).split(sep).join('/'), readFileSync(abs)) }); } catch { /* unreadable */ }
|
||||||
};
|
};
|
||||||
walk(root, (p, isDir) => {
|
walk(root, (p, isDir) => {
|
||||||
if (isDir) return !SKIP.has(basename(p));
|
if (isDir) return !SKIP.has(basename(p)) && !skipDir(root, p, basename(p));
|
||||||
if (basename(p) !== 'PrivacyInfo.xcprivacy') return;
|
if (basename(p) !== 'PrivacyInfo.xcprivacy') return;
|
||||||
const sdk = sdkOfProjectPath(relative(root, p).split(sep).join('/'));
|
const sdk = sdkOfProjectPath(relative(root, p).split(sep).join('/'));
|
||||||
if (sdk) add(p, sdk);
|
if (sdk) add(p, sdk);
|
||||||
|
|
|
||||||
54
cli/lib/release-type.ts
Normal file
54
cli/lib/release-type.ts
Normal file
|
|
@ -0,0 +1,54 @@
|
||||||
|
// How an App Store version goes live after App Review: apple.releaseType in the config, appStoreVersions.releaseType
|
||||||
|
// on the store. MANUAL leaves an approved version in PENDING_DEVELOPER_RELEASE until someone releases it; AFTER_APPROVAL
|
||||||
|
// releases it as soon as it is approved; SCHEDULED releases it at earliestReleaseDate at the earliest (Apple:
|
||||||
|
// https://developer.apple.com/documentation/appstoreconnectapi/appstoreversion/attributes, releaseType, earliestReleaseDate).
|
||||||
|
// Pure: the commands (apple listing, apple submit, apple release) read the version and send the PATCH.
|
||||||
|
import type { FieldDiff } from './listing-plan';
|
||||||
|
|
||||||
|
export const RELEASE_TYPES = ['afterApproval', 'manual', 'scheduled'] as const;
|
||||||
|
export type ReleaseTypeName = (typeof RELEASE_TYPES)[number];
|
||||||
|
export type AscReleaseType = 'AFTER_APPROVAL' | 'MANUAL' | 'SCHEDULED';
|
||||||
|
|
||||||
|
export const ASC_RELEASE_TYPE: Record<ReleaseTypeName, AscReleaseType> = { afterApproval: 'AFTER_APPROVAL', manual: 'MANUAL', scheduled: 'SCHEDULED' };
|
||||||
|
|
||||||
|
/** Version states in which App Store Connect still takes a release type change: everything before approval.
|
||||||
|
* Once the version is approved (PENDING_DEVELOPER_RELEASE and later) it is released with `apple release --manual-release`. */
|
||||||
|
export const RELEASE_TYPE_EDITABLE = new Set(['PREPARE_FOR_SUBMISSION', 'DEVELOPER_REJECTED', 'REJECTED', 'METADATA_REJECTED', 'INVALID_BINARY',
|
||||||
|
'READY_FOR_REVIEW', 'WAITING_FOR_REVIEW', 'IN_REVIEW']);
|
||||||
|
|
||||||
|
export interface WantedRelease { releaseType: AscReleaseType; earliestReleaseDate?: string }
|
||||||
|
|
||||||
|
/** The release type apple.releaseType asks for, or null when the config does not say (then nothing is touched). */
|
||||||
|
export function wantedRelease(apple: { releaseType?: ReleaseTypeName; earliestReleaseDate?: string } | undefined): WantedRelease | null {
|
||||||
|
if (!apple?.releaseType) return null;
|
||||||
|
const releaseType = ASC_RELEASE_TYPE[apple.releaseType];
|
||||||
|
return releaseType === 'SCHEDULED' && apple.earliestReleaseDate ? { releaseType, earliestReleaseDate: apple.earliestReleaseDate } : { releaseType };
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Problems with apple.releaseType / apple.earliestReleaseDate. Pure. */
|
||||||
|
export function validateReleaseType(a: { releaseType?: unknown; earliestReleaseDate?: unknown } | undefined): string[] {
|
||||||
|
if (!a) return [];
|
||||||
|
const e: string[] = [];
|
||||||
|
if (a.releaseType !== undefined && !(RELEASE_TYPES as readonly unknown[]).includes(a.releaseType)) e.push(`apple.releaseType: ${RELEASE_TYPES.join(' | ')} (afterApproval releases an approved version at once; manual waits for \`apple release --manual-release\`)`);
|
||||||
|
if (a.earliestReleaseDate !== undefined) {
|
||||||
|
if (typeof a.earliestReleaseDate !== 'string' || Number.isNaN(Date.parse(a.earliestReleaseDate))) e.push('apple.earliestReleaseDate: an ISO 8601 date and time, e.g. 2027-03-01T09:00:00Z');
|
||||||
|
else if (a.releaseType !== 'scheduled') e.push('apple.earliestReleaseDate: only with apple.releaseType "scheduled"');
|
||||||
|
}
|
||||||
|
if (a.releaseType === 'scheduled' && a.earliestReleaseDate === undefined) e.push('apple.releaseType "scheduled": apple.earliestReleaseDate is required (ISO 8601 date and time)');
|
||||||
|
return e;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The attribute changes that bring a version to `want` (old -> new), [] when it is there already. A scheduled date is
|
||||||
|
* compared as an instant. Pure. */
|
||||||
|
export function releaseTypeChanges(cur: Record<string, unknown>, want: WantedRelease): FieldDiff[] {
|
||||||
|
const out: FieldDiff[] = [];
|
||||||
|
const have = cur.releaseType == null ? null : String(cur.releaseType);
|
||||||
|
if (have !== want.releaseType) out.push({ field: 'releaseType', from: have, to: want.releaseType });
|
||||||
|
if (want.releaseType === 'SCHEDULED' && want.earliestReleaseDate) {
|
||||||
|
const had = cur.earliestReleaseDate == null ? null : String(cur.earliestReleaseDate);
|
||||||
|
if (had === null || Date.parse(had) !== Date.parse(want.earliestReleaseDate)) out.push({ field: 'earliestReleaseDate', from: had, to: want.earliestReleaseDate });
|
||||||
|
}
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
|
export const changeText = (c: FieldDiff[]): string => c.map(x => `${x.field} ${x.from ?? '(none)'} -> ${x.to}`).join(', ');
|
||||||
|
|
@ -3,14 +3,15 @@
|
||||||
// field takes up to 4000 bytes; a demo account must keep working during the whole review (Guideline 2.1).
|
// field takes up to 4000 bytes; a demo account must keep working during the whole review (Guideline 2.1).
|
||||||
// https://developer.apple.com/help/app-store-connect/reference/app-information/platform-version-information
|
// https://developer.apple.com/help/app-store-connect/reference/app-information/platform-version-information
|
||||||
// https://developer.apple.com/documentation/appstoreconnectapi/appstorereviewdetail/attributes-data.dictionary
|
// https://developer.apple.com/documentation/appstoreconnectapi/appstorereviewdetail/attributes-data.dictionary
|
||||||
import type { ShipConfig } from './config';
|
import { reviewNotesFor, type ShipConfig } from './config';
|
||||||
import { type DemoAccount, maskSecret, maskUser } from './credentials';
|
import { type DemoAccount, maskSecret, maskUser } from './credentials';
|
||||||
|
|
||||||
export const NOTES_MAX_BYTES = 4000;
|
export const NOTES_MAX_BYTES = 4000;
|
||||||
|
|
||||||
/** Notes for the reviewer: apple.info.reviewNotes, then reviewAccess.instructions, then where account deletion is. */
|
/** Notes for the reviewer: apple.info.reviewNotes (macOS: apple.macos.reviewNotes when set), then reviewAccess.instructions,
|
||||||
export function reviewNotes(config: Pick<ShipConfig, 'apple' | 'reviewAccess' | 'accounts'>): string {
|
* then where account deletion is. */
|
||||||
const parts = [config.apple?.info?.reviewNotes?.trim() ?? ''];
|
export function reviewNotes(config: Pick<ShipConfig, 'apple' | 'reviewAccess' | 'accounts'>, platform?: string): string {
|
||||||
|
const parts = [reviewNotesFor(config, platform)?.trim() ?? ''];
|
||||||
const ins = config.reviewAccess?.instructions?.trim();
|
const ins = config.reviewAccess?.instructions?.trim();
|
||||||
if (ins && !parts[0]!.includes(ins)) parts.push(`Sign-in: ${ins}`);
|
if (ins && !parts[0]!.includes(ins)) parts.push(`Sign-in: ${ins}`);
|
||||||
const del = config.accounts?.enabled ? config.accounts.inApp?.trim() : '';
|
const del = config.accounts?.enabled ? config.accounts.inApp?.trim() : '';
|
||||||
|
|
@ -29,8 +30,8 @@ export interface ReviewDetailPlan {
|
||||||
* (throws when it is missing, so a submission never goes out with "sign-in required" and no account); without it the
|
* (throws when it is missing, so a submission never goes out with "sign-in required" and no account); without it the
|
||||||
* demo fields are cleared.
|
* demo fields are cleared.
|
||||||
*/
|
*/
|
||||||
export function reviewDetailPlan(config: Pick<ShipConfig, 'apple' | 'reviewAccess' | 'accounts'>, contact: Record<string, string>, demo: DemoAccount | null): ReviewDetailPlan {
|
export function reviewDetailPlan(config: Pick<ShipConfig, 'apple' | 'reviewAccess' | 'accounts'>, contact: Record<string, string>, demo: DemoAccount | null, platform?: string): ReviewDetailPlan {
|
||||||
const notes = reviewNotes(config);
|
const notes = reviewNotes(config, platform);
|
||||||
const bytes = new TextEncoder().encode(notes).length;
|
const bytes = new TextEncoder().encode(notes).length;
|
||||||
if (bytes > NOTES_MAX_BYTES) throw new Error(`review notes are ${bytes} bytes; App Store Connect takes ${NOTES_MAX_BYTES}`);
|
if (bytes > NOTES_MAX_BYTES) throw new Error(`review notes are ${bytes} bytes; App Store Connect takes ${NOTES_MAX_BYTES}`);
|
||||||
const required = !!config.reviewAccess?.signInRequired;
|
const required = !!config.reviewAccess?.signInRequired;
|
||||||
|
|
|
||||||
|
|
@ -3,9 +3,10 @@
|
||||||
// Xcode INFOPLIST_KEY_* build settings, Expo app.json, Unity ProjectSettings and Godot export presets), entitlements,
|
// Xcode INFOPLIST_KEY_* build settings, Expo app.json, Unity ProjectSettings and Godot export presets), entitlements,
|
||||||
// privacy manifests, the Android manifest (permissions, services, target SDK) and the app's own source files.
|
// privacy manifests, the Android manifest (permissions, services, target SDK) and the app's own source files.
|
||||||
// Tolerant on purpose: an unreadable or odd file is skipped, never an exception.
|
// Tolerant on purpose: an unreadable or odd file is skipped, never an exception.
|
||||||
import { readdirSync, readFileSync, statSync } from 'node:fs';
|
import { type Dirent, readdirSync, readFileSync, statSync } from 'node:fs';
|
||||||
import { basename, dirname, extname, join, relative, sep } from 'node:path';
|
import { basename, dirname, extname, join, relative, sep } from 'node:path';
|
||||||
import { resolvePackage } from '../node-packages';
|
import { resolvePackage } from '../node-packages';
|
||||||
|
import { skipDir } from '../walk-skip';
|
||||||
import { isBuildCopyPath, type Manifest, parseManifest } from '../privacy-manifest';
|
import { isBuildCopyPath, type Manifest, parseManifest } from '../privacy-manifest';
|
||||||
import { type DepRef, type Eco, matchesSdk, SDKS, type SdkDef } from './sdks';
|
import { type DepRef, type Eco, matchesSdk, SDKS, type SdkDef } from './sdks';
|
||||||
import { exportedIpas, ipaInfo } from '../xcode';
|
import { exportedIpas, ipaInfo } from '../xcode';
|
||||||
|
|
@ -104,33 +105,32 @@ const SRC_EXT = new Set(['.swift', '.m', '.mm', '.h', '.kt', '.java', '.dart', '
|
||||||
const MAX_FILES = 25_000;
|
const MAX_FILES = 25_000;
|
||||||
const MAX_TEXT = 1_500_000;
|
const MAX_TEXT = 1_500_000;
|
||||||
|
|
||||||
/** A linked git worktree: its .git is a file pointing into <repo>/.git/worktrees/ (a submodule's points into modules/). */
|
|
||||||
function isWorktree(dir: string): boolean {
|
|
||||||
try { return /^gitdir:.*[\\/]worktrees[\\/]/m.test(readFileSync(join(dir, '.git'), 'utf8')); } catch { return false; }
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Every file under root (relative paths), skipping build output, dependency folders and VCS data. Native libraries
|
/** Every file under root (relative paths), skipping build output, dependency folders and VCS data. Native libraries
|
||||||
* (.so) of any size also go into `bins` when given (they are not read, only listed). */
|
* (.so) of any size also go into `bins` when given (they are not read, only listed). */
|
||||||
export function listFiles(root: string, bins?: string[]): string[] {
|
export function listFiles(root: string, bins?: string[]): string[] {
|
||||||
const out: string[] = [];
|
const out: string[] = [];
|
||||||
const walk = (dir: string, depth: number) => {
|
const walk = (dir: string, depth: number) => {
|
||||||
if (depth > 14 || out.length >= MAX_FILES) return;
|
if (depth > 14 || out.length >= MAX_FILES) return;
|
||||||
let names: string[];
|
let ents: Dirent[];
|
||||||
try { names = readdirSync(dir); } catch { return; }
|
try { ents = readdirSync(dir, { withFileTypes: true }); } catch { return; }
|
||||||
for (const n of names.sort()) {
|
for (const e of ents.sort((a, b) => (a.name < b.name ? -1 : a.name > b.name ? 1 : 0))) {
|
||||||
|
const n = e.name;
|
||||||
if (SKIP_DIRS.has(n) || n === '.DS_Store') continue;
|
if (SKIP_DIRS.has(n) || n === '.DS_Store') continue;
|
||||||
const p = join(dir, n);
|
const p = join(dir, n);
|
||||||
let st;
|
// the entry type comes with the listing; only files (for their size) and links get a stat
|
||||||
try { st = statSync(p); } catch { continue; }
|
let isDir = e.isDirectory();
|
||||||
if (st.isDirectory()) {
|
if (e.isSymbolicLink()) { try { isDir = statSync(p).isDirectory(); } catch { continue; } }
|
||||||
|
if (isDir) {
|
||||||
// compiled frameworks are SDK binaries, not app code
|
// compiled frameworks are SDK binaries, not app code
|
||||||
if (/\.(xc)?framework$|\.xcassets$|\.bundle$|\.app$|\.dSYM$/.test(n)) continue;
|
if (/\.(xc)?framework$|\.xcassets$|\.bundle$|\.app$|\.dSYM$/.test(n)) continue;
|
||||||
// a git worktree inside the project (another checkout of the same repo; submodules stay in)
|
// dot folders, git worktrees (other checkouts of the same repo; submodules stay in), git-ignored output
|
||||||
if (isWorktree(p)) continue;
|
if (skipDir(root, p, n)) continue;
|
||||||
walk(p, depth + 1);
|
walk(p, depth + 1);
|
||||||
} else {
|
} else {
|
||||||
if (bins && n.endsWith('.so')) bins.push(relative(root, p).split(sep).join('/'));
|
if (bins && n.endsWith('.so')) bins.push(relative(root, p).split(sep).join('/'));
|
||||||
if (st.size <= MAX_TEXT) out.push(relative(root, p).split(sep).join('/'));
|
let size = 0;
|
||||||
|
try { size = statSync(p).size; } catch { continue; }
|
||||||
|
if (size <= MAX_TEXT) out.push(relative(root, p).split(sep).join('/'));
|
||||||
}
|
}
|
||||||
if (out.length >= MAX_FILES) return;
|
if (out.length >= MAX_FILES) return;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -113,7 +113,7 @@ export interface CertChoice { cert: ApiCert | null; why: string; usable: ApiCert
|
||||||
|
|
||||||
/** A certificate is usable when it is of the wanted type, active, valid for 30 more days and this machine holds its
|
/** A certificate is usable when it is of the wanted type, active, valid for 30 more days and this machine holds its
|
||||||
* private key (a key file in .storebound/signing or a code signing identity in the keychain). Newest first. */
|
* private key (a key file in .storebound/signing or a code signing identity in the keychain). Newest first. */
|
||||||
export function pickCertificate(certs: ApiCert[], type: CertType, hasKey: (c: ApiCert) => boolean, now = Date.now()): CertChoice {
|
export function pickCertificate(certs: ApiCert[], type: CertType, hasKey: (c: ApiCert) => boolean, now = Date.now(), platform: string = process.platform): CertChoice {
|
||||||
const ofType = certs.filter(c => c.attributes.certificateType === type && c.attributes.activated !== false);
|
const ofType = certs.filter(c => c.attributes.certificateType === type && c.attributes.activated !== false);
|
||||||
const valid = ofType.filter(c => Date.parse(c.attributes.expirationDate ?? '') > now);
|
const valid = ofType.filter(c => Date.parse(c.attributes.expirationDate ?? '') > now);
|
||||||
const expiring = valid.filter(c => Date.parse(c.attributes.expirationDate!) - now < 30 * 86_400_000);
|
const expiring = valid.filter(c => Date.parse(c.attributes.expirationDate!) - now < 30 * 86_400_000);
|
||||||
|
|
@ -121,7 +121,9 @@ export function pickCertificate(certs: ApiCert[], type: CertType, hasKey: (c: Ap
|
||||||
const withoutKey = valid.filter(c => !hasKey(c));
|
const withoutKey = valid.filter(c => !hasKey(c));
|
||||||
const cert = usable[0] ?? null;
|
const cert = usable[0] ?? null;
|
||||||
const why = cert ? `using ${cert.attributes.name ?? cert.attributes.displayName ?? type} (expires ${cert.attributes.expirationDate?.slice(0, 10)})`
|
const why = cert ? `using ${cert.attributes.name ?? cert.attributes.displayName ?? type} (expires ${cert.attributes.expirationDate?.slice(0, 10)})`
|
||||||
: withoutKey.length ? `${withoutKey.length} ${type} certificate(s) on the team, but this machine has none of their private keys: a new one is needed (or import the .p12 from the Mac that made it)`
|
: withoutKey.length ? `${withoutKey.length} ${type} certificate(s) on the team, but this machine has none of their private keys: ${platform === 'darwin'
|
||||||
|
? 'a new one is needed (or import the .p12 from the Mac that made it)'
|
||||||
|
: 'this machine cannot build or sign for Apple. The keys live on the Mac that made the certificates: build there (e.g. over ssh to that Mac). Do not create another certificate, Apple caps them per team'}`
|
||||||
: `no valid ${type} certificate`;
|
: `no valid ${type} certificate`;
|
||||||
return { cert, why, usable, withoutKey, expiring };
|
return { cert, why, usable, withoutKey, expiring };
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -54,9 +54,14 @@ export const groupFromApi = (g: { id: string; attributes: Record<string, unknown
|
||||||
});
|
});
|
||||||
|
|
||||||
/** Problems with the testflight config. Pure. */
|
/** Problems with the testflight config. Pure. */
|
||||||
export function validateTestflight(t: TfConfig | undefined): string[] {
|
export function validateTestflight(t: TfConfig | undefined, langs: { id: string; apple?: string }[] = []): string[] {
|
||||||
if (!t) return [];
|
if (!t) return [];
|
||||||
const e: string[] = [];
|
const e: string[] = [];
|
||||||
|
if (t.description && typeof t.description === 'object' && langs.length) {
|
||||||
|
const known = new Set(langs.flatMap(l => [l.id, ...(l.apple ? [l.apple] : [])]));
|
||||||
|
const bad = Object.keys(t.description).filter(k => !known.has(k));
|
||||||
|
if (bad.length) e.push(`apple.testflight.description: ${bad.map(k => `'${k}'`).join(', ')} is not a language of the config (use a language id or its App Store locale: ${langs.filter(l => l.apple).map(l => `${l.id} / ${l.apple}`).join(', ')})`);
|
||||||
|
}
|
||||||
const names = new Set<string>();
|
const names = new Set<string>();
|
||||||
for (const [i, g] of (t.groups ?? []).entries()) {
|
for (const [i, g] of (t.groups ?? []).entries()) {
|
||||||
const at = `apple.testflight.groups[${i}]`;
|
const at = `apple.testflight.groups[${i}]`;
|
||||||
|
|
@ -315,8 +320,28 @@ export function betaDescriptions(t: TfConfig | undefined, langs: { id: string; a
|
||||||
const out: Record<string, string> = {};
|
const out: Record<string, string> = {};
|
||||||
for (const l of langs) {
|
for (const l of langs) {
|
||||||
if (!l.apple) continue;
|
if (!l.apple) continue;
|
||||||
const d = typeof t.description === 'string' ? t.description : t.description[l.id];
|
// a language id ('en') or its App Store locale ('en-US'): an 'en-US' key was silently skipped (Acme 2026-10-29)
|
||||||
|
const d = typeof t.description === 'string' ? t.description : (t.description[l.id] ?? t.description[l.apple]);
|
||||||
if (d) out[l.apple] = d;
|
if (d) out[l.apple] = d;
|
||||||
}
|
}
|
||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ---- invitations need an installable build ----
|
||||||
|
|
||||||
|
/** Whether a build can be installed by the testers of a group: valid, not expired, and past Beta App Review for an
|
||||||
|
* external group (externalBuildState BETA_APPROVED / IN_BETA_TESTING), ready for internal testing for an internal one
|
||||||
|
* (internalBuildState READY_FOR_BETA_TESTING / IN_BETA_TESTING). `detail`: the build's buildBetaDetails attributes. Pure. */
|
||||||
|
export function installableBuild(build: { attributes: Record<string, unknown> }, detail: Record<string, unknown> | null | undefined, internal: boolean): boolean {
|
||||||
|
if (build.attributes.expired === true) return false;
|
||||||
|
if (build.attributes.processingState !== undefined && build.attributes.processingState !== 'VALID') return false;
|
||||||
|
const state = String((internal ? detail?.internalBuildState : detail?.externalBuildState) ?? '');
|
||||||
|
return internal ? ['READY_FOR_BETA_TESTING', 'IN_BETA_TESTING'].includes(state) : ['BETA_APPROVED', 'IN_BETA_TESTING'].includes(state);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The line for testers that are added but cannot be invited yet. Pure. */
|
||||||
|
export const noInstallableBuildHint = (groups: string[]): string =>
|
||||||
|
`tester added; the invite goes out when a build in ${groups.join(', ')} passes Beta App Review (re-run with --invite then)`;
|
||||||
|
|
||||||
|
/** Apple's 409 STATE_ERROR.TESTER_INVITE.NO_INSTALLABLE_BUILDS on POST /v1/betaTesterInvitations (seen live). Pure. */
|
||||||
|
export const noInstallableBuilds409 = (e: unknown): boolean => /NO_INSTALLABLE_BUILDS/.test(String((e as Error)?.message ?? e));
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
// Store readiness rules for `storebound validate`. Pure: the command collects a snapshot from both APIs (read-only),
|
// Store readiness rules for `storebound validate`. Pure: the command collects a snapshot from both APIs (read-only),
|
||||||
// these functions turn it into an ordered list of findings. Order = the order you would fix things in.
|
// these functions turn it into an ordered list of findings. Order = the order you would fix things in.
|
||||||
|
|
||||||
|
import { oldTrackBuilds } from '../play/old-builds';
|
||||||
import { consoleLink, consoleUrl } from './console-links';
|
import { consoleLink, consoleUrl } from './console-links';
|
||||||
import { describePending, type Pending, repairable } from '../apple/screenshot-health';
|
import { describePending, type Pending, repairable } from '../apple/screenshot-health';
|
||||||
import { type FixAction, fixAppleListing, fixPlayListing, fixReviewDetails } from './fix-actions';
|
import { type FixAction, fixAppleListing, fixPlayListing, fixReviewDetails } from './fix-actions';
|
||||||
|
|
@ -63,6 +64,8 @@ export interface AppleSnapshot {
|
||||||
/** Screenshots of the version that are not COMPLETE (cli/apple/screenshot-health.ts): a submit answers 409
|
/** Screenshots of the version that are not COMPLETE (cli/apple/screenshot-health.ts): a submit answers 409
|
||||||
* ASSET_IN_POST_PROCESSING while any is left. */
|
* ASSET_IN_POST_PROCESSING while any is left. */
|
||||||
screenshotsPending?: Pending[];
|
screenshotsPending?: Pending[];
|
||||||
|
/** Live version's device families vs the Xcode project and apple.ipad (cli/lib/device-families.ts familyVerdicts); undefined: not iOS. */
|
||||||
|
deviceFamilies?: { level: 'ok' | 'blocker' | 'warn'; msg: string; fix?: string }[];
|
||||||
/** Editable or rejected versions of the app's other platforms (an app's macOS version has its own state). */
|
/** Editable or rejected versions of the app's other platforms (an app's macOS version has its own state). */
|
||||||
otherPlatformVersions?: { versionString: string; state: string; platform: string }[];
|
otherPlatformVersions?: { versionString: string; state: string; platform: string }[];
|
||||||
/** app.copyright from the config (undefined: not set). */
|
/** app.copyright from the config (undefined: not set). */
|
||||||
|
|
@ -70,7 +73,10 @@ export interface AppleSnapshot {
|
||||||
build: { number: string; processingState: string; usesNonExemptEncryption: boolean | null; declarationState: string | null } | null;
|
build: { number: string; processingState: string; usesNonExemptEncryption: boolean | null; declarationState: string | null } | null;
|
||||||
/** Locales the config expects (apple: entries of `languages`). */
|
/** Locales the config expects (apple: entries of `languages`). */
|
||||||
expectedLocales: string[];
|
expectedLocales: string[];
|
||||||
locales: { locale: string; name?: string; subtitle?: string; description?: string; keywords?: string; screenshots: Record<string, number> }[];
|
locales: { locale: string; name?: string; subtitle?: string; description?: string; keywords?: string; promotionalText?: string; whatsNew?: string; screenshots: Record<string, number> }[];
|
||||||
|
/** apple.macos facts for the macOS claim check (validate fills it): the config's macOS review notes (what `apple review-details
|
||||||
|
* --platform macos` would send) and the gameCenter / noIap switches. */
|
||||||
|
macos?: { notes?: string; gameCenter?: boolean; noIap?: boolean };
|
||||||
requiredDisplayTypes: string[];
|
requiredDisplayTypes: string[];
|
||||||
/** apple.iphoneDuo (iPhone Duo renders on) and whether the project has a play section, for the Duo note. */
|
/** apple.iphoneDuo (iPhone Duo renders on) and whether the project has a play section, for the Duo note. */
|
||||||
iphoneDuo?: boolean;
|
iphoneDuo?: boolean;
|
||||||
|
|
@ -161,6 +167,7 @@ export interface PlaySnapshot {
|
||||||
const EDITABLE = ['PREPARE_FOR_SUBMISSION', 'DEVELOPER_REJECTED', 'REJECTED', 'METADATA_REJECTED', 'INVALID_BINARY'];
|
const EDITABLE = ['PREPARE_FOR_SUBMISSION', 'DEVELOPER_REJECTED', 'REJECTED', 'METADATA_REJECTED', 'INVALID_BINARY'];
|
||||||
const IN_FLIGHT = ['WAITING_FOR_REVIEW', 'IN_REVIEW', 'PENDING_DEVELOPER_RELEASE', 'PROCESSING_FOR_DISTRIBUTION', 'READY_FOR_DISTRIBUTION', 'READY_FOR_SALE', 'ACCEPTED'];
|
const IN_FLIGHT = ['WAITING_FOR_REVIEW', 'IN_REVIEW', 'PENDING_DEVELOPER_RELEASE', 'PROCESSING_FOR_DISTRIBUTION', 'READY_FOR_DISTRIBUTION', 'READY_FOR_SALE', 'ACCEPTED'];
|
||||||
const IAP_OK = ['READY_TO_SUBMIT', 'WAITING_FOR_REVIEW', 'IN_REVIEW', 'APPROVED'];
|
const IAP_OK = ['READY_TO_SUBMIT', 'WAITING_FOR_REVIEW', 'IN_REVIEW', 'APPROVED'];
|
||||||
|
const IAP_OFF_SALE = ['DEVELOPER_REMOVED_FROM_SALE', 'REMOVED_FROM_SALE'];
|
||||||
/** Age rating questions whose null means "not answered" (kidsAgeBand null = not a kids app). */
|
/** Age rating questions whose null means "not answered" (kidsAgeBand null = not a kids app). */
|
||||||
// Left null on apps App Review accepted: gracRatingClassificationNumber (a Korean GRAC rating number, for apps GRAC
|
// Left null on apps App Review accepted: gracRatingClassificationNumber (a Korean GRAC rating number, for apps GRAC
|
||||||
// rated), socialMediaAgeRestricted (asked only when socialMedia is true). socialMedia itself is a newer question that
|
// rated), socialMediaAgeRestricted (asked only when socialMedia is true). socialMedia itself is a newer question that
|
||||||
|
|
@ -205,6 +212,35 @@ export function copyrightRules(s: Pick<AppleSnapshot, 'version' | 'configCopyrig
|
||||||
|
|
||||||
const PLATFORM_NAMES: Record<string, string> = { IOS: 'iOS', MAC_OS: 'macOS', TV_OS: 'tvOS', VISION_OS: 'visionOS' };
|
const PLATFORM_NAMES: Record<string, string> = { IOS: 'iOS', MAC_OS: 'macOS', TV_OS: 'tvOS', VISION_OS: 'visionOS' };
|
||||||
|
|
||||||
|
const MACOS_CLAIMS: { kind: string; re: RegExp; needs?: 'noGameCenter' | 'noIap'; what: string }[] = [
|
||||||
|
{ kind: 'game-center', re: /game\s*center/i, needs: 'noGameCenter', what: 'Game Center (set apple.macos.gameCenter: true when the Mac app has it)' },
|
||||||
|
{ kind: 'touch', re: /\b(tap|taps|tapping|swipe|swipes|swiping|pinch|pinches)\b|touch[\s-]?screen/i, what: 'touch words (tap, swipe, pinch, touch screen)' },
|
||||||
|
{ kind: 'ios-device', re: /\b(iphone|ipad)s?\b/i, what: 'an iPhone / iPad mention' },
|
||||||
|
{ kind: 'iap', re: /in[\s-]app[\s-]purchases?|\biaps?\b|restore purchases/i, needs: 'noIap', what: 'an in-app purchase line (apple.macos.noIap is set)' },
|
||||||
|
];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A macOS version's texts (description, promotional text, what's new, keywords, subtitle) and review notes (live, and
|
||||||
|
* the config's apple.macos.reviewNotes / apple.info.reviewNotes) that carry iOS-only claims. Warnings only. Game Center
|
||||||
|
* is flagged unless apple.macos.gameCenter is true; in-app purchase lines only when apple.macos.noIap is set. Pure.
|
||||||
|
*/
|
||||||
|
export function macosClaimRules(s: Pick<AppleSnapshot, 'version' | 'locales' | 'reviewDetail' | 'macos'>): Finding[] {
|
||||||
|
if (s.version?.platform !== 'MAC_OS') return [];
|
||||||
|
const texts: { where: string; text: string }[] = [];
|
||||||
|
for (const l of s.locales) for (const k of ['subtitle', 'description', 'promotionalText', 'whatsNew', 'keywords'] as const) if (l[k]) texts.push({ where: `${l.locale} ${k}`, text: l[k]! });
|
||||||
|
if (s.reviewDetail?.notes) texts.push({ where: 'review notes (on the store)', text: s.reviewDetail.notes });
|
||||||
|
if (s.macos?.notes) texts.push({ where: 'review notes (config)', text: s.macos.notes });
|
||||||
|
const out: Finding[] = [];
|
||||||
|
for (const c of MACOS_CLAIMS) {
|
||||||
|
if (c.needs === 'noGameCenter' && s.macos?.gameCenter) continue;
|
||||||
|
if (c.needs === 'noIap' && !s.macos?.noIap) continue;
|
||||||
|
const hits = [...new Set(texts.filter(t => c.re.test(t.text)).map(t => t.where))];
|
||||||
|
if (hits.length) out.push({ store: 'apple', level: 'warn', code: 'macos-claims', msg: `macOS version ${s.version.versionString}: ${c.what} in ${hits.slice(0, 6).join(', ')}${hits.length > 6 ? ` (+${hits.length - 6} more)` : ''}`,
|
||||||
|
fix: 'a separate macOS listing file (apple.macos.listing, then storebound apple listing --platform macos) and apple.macos.reviewNotes (storebound apple review-details --platform macos)' });
|
||||||
|
}
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
export function appleRules(s: AppleSnapshot): Finding[] {
|
export function appleRules(s: AppleSnapshot): Finding[] {
|
||||||
const f: Finding[] = [];
|
const f: Finding[] = [];
|
||||||
const add = (level: Level, code: string, msg: string, fix?: string, action?: FixAction, url?: string) => f.push({ store: 'apple', level, code, msg, fix, ...(action ? { action } : {}), ...(url ? { url } : {}) });
|
const add = (level: Level, code: string, msg: string, fix?: string, action?: FixAction, url?: string) => f.push({ store: 'apple', level, code, msg, fix, ...(action ? { action } : {}), ...(url ? { url } : {}) });
|
||||||
|
|
@ -215,6 +251,7 @@ export function appleRules(s: AppleSnapshot): Finding[] {
|
||||||
else if (EDITABLE.includes(s.version.state)) add('ok', 'version', `version ${vl}: ${s.version.state}`);
|
else if (EDITABLE.includes(s.version.state)) add('ok', 'version', `version ${vl}: ${s.version.state}`);
|
||||||
else if (IN_FLIGHT.includes(s.version.state)) add('warn', 'version', `version ${vl} is ${s.version.state} (nothing to prepare)`);
|
else if (IN_FLIGHT.includes(s.version.state)) add('warn', 'version', `version ${vl} is ${s.version.state} (nothing to prepare)`);
|
||||||
else add('warn', 'version', `version ${vl}: ${s.version.state}`);
|
else add('warn', 'version', `version ${vl}: ${s.version.state}`);
|
||||||
|
for (const d of s.deviceFamilies ?? []) add(d.level, 'device-families', d.msg, d.fix);
|
||||||
{
|
{
|
||||||
const pend = s.screenshotsPending ?? [];
|
const pend = s.screenshotsPending ?? [];
|
||||||
const lines = describePending(pend);
|
const lines = describePending(pend);
|
||||||
|
|
@ -228,6 +265,7 @@ export function appleRules(s: AppleSnapshot): Finding[] {
|
||||||
add('warn', 'version-platform', `version ${o.versionString} (${name}) is ${o.state} too: this report covers ${vl || 'iOS'} only`, `storebound validate --platform ${name.toLowerCase()}; storebound apple status lists every platform`);
|
add('warn', 'version-platform', `version ${o.versionString} (${name}) is ${o.state} too: this report covers ${vl || 'iOS'} only`, `storebound validate --platform ${name.toLowerCase()}; storebound apple status lists every platform`);
|
||||||
}
|
}
|
||||||
f.push(...copyrightRules(s));
|
f.push(...copyrightRules(s));
|
||||||
|
f.push(...macosClaimRules(s));
|
||||||
|
|
||||||
if (!s.build) add('blocker', 'build', 'no build attached to the version', 'storebound apple listing --version x.y.z --build N (pick the build number you just uploaded)');
|
if (!s.build) add('blocker', 'build', 'no build attached to the version', 'storebound apple listing --version x.y.z --build N (pick the build number you just uploaded)');
|
||||||
else {
|
else {
|
||||||
|
|
@ -278,12 +316,17 @@ export function appleRules(s: AppleSnapshot): Finding[] {
|
||||||
|
|
||||||
const iaps = new Map(s.iaps.map(i => [i.productId, i] as const));
|
const iaps = new Map(s.iaps.map(i => [i.productId, i] as const));
|
||||||
for (const id of s.expectedProducts) if (!iaps.has(id)) add('blocker', 'iap', `${id}: not on App Store Connect`, 'storebound apple iap');
|
for (const id of s.expectedProducts) if (!iaps.has(id)) add('blocker', 'iap', `${id}: not on App Store Connect`, 'storebound apple iap');
|
||||||
|
const expected = new Set(s.expectedProducts);
|
||||||
for (const i of s.iaps) {
|
for (const i of s.iaps) {
|
||||||
|
// a product the developer took off sale (old consumables, a retired unlock) does not block a submission; it matters
|
||||||
|
// only when the config still sells it
|
||||||
|
if (IAP_OFF_SALE.includes(i.state)) { if (expected.has(i.productId)) add('warn', 'iap', `${i.productId}: ${i.state}, but the config still sells it`, 'put it back on sale in App Store Connect, or drop it from products'); continue; }
|
||||||
if (!IAP_OK.includes(i.state)) add('blocker', 'iap', `${i.productId}: ${i.state}`, i.state === 'MISSING_METADATA' ? 'storebound apple iap + apple iap-review' : 'see the review-rejections skill');
|
if (!IAP_OK.includes(i.state)) add('blocker', 'iap', `${i.productId}: ${i.state}`, i.state === 'MISSING_METADATA' ? 'storebound apple iap + apple iap-review' : 'see the review-rejections skill');
|
||||||
else if (!i.reviewScreenshot && i.state !== 'APPROVED') add('blocker', 'iap', `${i.productId}: no review screenshot`, 'storebound apple iap-review');
|
else if (!i.reviewScreenshot && i.state !== 'APPROVED') add('blocker', 'iap', `${i.productId}: no review screenshot`, 'storebound apple iap-review');
|
||||||
}
|
}
|
||||||
for (const g of s.firstProductGaps ?? []) add(g.level === 'error' ? 'blocker' : 'warn', 'iap-first', g.msg, g.fix);
|
for (const g of s.firstProductGaps ?? []) add(g.level === 'error' ? 'blocker' : 'warn', 'iap-first', g.msg, g.fix);
|
||||||
if (s.iaps.length && !f.some(x => x.code === 'iap')) add('ok', 'iap', `${s.iaps.length} in-app purchases ready`);
|
const onSale = s.iaps.filter(i => !IAP_OFF_SALE.includes(i.state)).length, offSale = s.iaps.length - onSale;
|
||||||
|
if (s.iaps.length && !f.some(x => x.code === 'iap')) add('ok', 'iap', `${onSale} in-app purchases ready${offSale ? ` (${offSale} removed from sale, not checked)` : ''}`);
|
||||||
|
|
||||||
f.push(...appleSubscriptionRules(s));
|
f.push(...appleSubscriptionRules(s));
|
||||||
for (const m of s.capabilityMismatches ?? []) add('warn', 'capabilities', m.msg, m.fix);
|
for (const m of s.capabilityMismatches ?? []) add('warn', 'capabilities', m.msg, m.fix);
|
||||||
|
|
@ -367,6 +410,7 @@ export function playRules(s: PlaySnapshot): Finding[] {
|
||||||
if (r.status === 'halted') add('warn', 'tracks', `${t.track}: release ${r.versionCodes.join(',')} is halted`, 'storebound play rollout --resume (owner)');
|
if (r.status === 'halted') add('warn', 'tracks', `${t.track}: release ${r.versionCodes.join(',')} is halted`, 'storebound play rollout --resume (owner)');
|
||||||
if (r.status === 'inProgress') add('ok', 'tracks', `${t.track}: rollout ${Math.round((r.userFraction ?? 0) * 100)}% of ${r.versionCodes.join(',')}`);
|
if (r.status === 'inProgress') add('ok', 'tracks', `${t.track}: rollout ${Math.round((r.userFraction ?? 0) * 100)}% of ${r.versionCodes.join(',')}`);
|
||||||
}
|
}
|
||||||
|
for (const o of oldTrackBuilds(s.tracks)) add('warn', 'old-builds', `${o.track}: old build ${o.versionCodes.join(',')} (${o.status}) is still active below production ${o.productionCode}; Play reviews it with every submission and a policy issue in it (e.g. READ_MEDIA_IMAGES / READ_MEDIA_VIDEO) blocks Send changes for review (pitfall 129)`, `storebound play release --version-code ${o.productionCode} ${['internal','alpha','beta'].includes(o.track) ? '--' + o.track : '--track ' + o.track} completed`);
|
||||||
if (anyRelease && !f.some(x => x.code === 'tracks')) add('ok', 'tracks', s.tracks.filter(t => t.releases.length).map(t => `${t.track}: ${t.releases.map(r => r.status).join('/')}`).join(', '));
|
if (anyRelease && !f.some(x => x.code === 'tracks')) add('ok', 'tracks', s.tracks.filter(t => t.releases.length).map(t => `${t.track}: ${t.releases.map(r => r.status).join('/')}`).join(', '));
|
||||||
|
|
||||||
const prods = new Map(s.products.map(p => [p.productId, p] as const));
|
const prods = new Map(s.products.map(p => [p.productId, p] as const));
|
||||||
|
|
|
||||||
42
cli/lib/walk-skip.ts
Normal file
42
cli/lib/walk-skip.ts
Normal file
|
|
@ -0,0 +1,42 @@
|
||||||
|
// Which folders a project walk (scan, check's privacy manifests) leaves out, beyond each walker's own name list:
|
||||||
|
// - dot folders below the root (.harness-worktrees, .wt-head, .ota-out, .native-build, ...): tool state, caches and
|
||||||
|
// whole copies of the repo, never app sources;
|
||||||
|
// - linked git worktrees (another checkout of the same repo);
|
||||||
|
// - folders git ignores at the root (release-out/, artifacts/, ...), asked once per root with
|
||||||
|
// `git ls-files --others --ignored --exclude-standard --directory`; SDK folders the privacy checks read (Pods,
|
||||||
|
// Carthage, SourcePackages) and generated native projects (ios, android) stay in even when ignored.
|
||||||
|
// Seen live: a game repo with several worktrees and release folders made `check` walk ~60 000 files for 2.5 minutes.
|
||||||
|
import { readFileSync } from 'node:fs';
|
||||||
|
import { join, relative, resolve, sep } from 'node:path';
|
||||||
|
import * as rt from './rt';
|
||||||
|
|
||||||
|
// kept even when git ignores them: SDK folders the privacy checks read, and generated native projects (Expo prebuild)
|
||||||
|
const KEEP = new Set(['Pods', 'Carthage', 'SourcePackages', 'ios', 'android', 'macos']);
|
||||||
|
const cache = new Map<string, Set<string>>();
|
||||||
|
|
||||||
|
/** A linked git worktree: its .git is a file pointing into <repo>/.git/worktrees/ (a submodule's points into modules/). */
|
||||||
|
export function isWorktree(dir: string): boolean {
|
||||||
|
try { return /^gitdir:.*[\\/]worktrees[\\/]/m.test(readFileSync(join(dir, '.git'), 'utf8')); } catch { return false; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Root-relative folders (with "/" separators, no trailing slash) git ignores in this repo; empty outside git. */
|
||||||
|
export function gitIgnoredDirs(root: string): Set<string> {
|
||||||
|
const key = resolve(root);
|
||||||
|
const hit = cache.get(key);
|
||||||
|
if (hit) return hit;
|
||||||
|
const out = new Set<string>();
|
||||||
|
try {
|
||||||
|
const r = rt.spawnSync(['git', 'ls-files', '--others', '--ignored', '--exclude-standard', '--directory', '-z'], { cwd: key, timeout: 15_000 });
|
||||||
|
if (r.success) for (const p of r.stdout.toString('utf8').split('\0')) if (p.endsWith('/')) out.add(p.slice(0, -1));
|
||||||
|
} catch { /* no git */ }
|
||||||
|
cache.set(key, out);
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Leave this folder out of a walk that started at root? */
|
||||||
|
export function skipDir(root: string, abs: string, name: string): boolean {
|
||||||
|
if (KEEP.has(name)) return false;
|
||||||
|
if (name.startsWith('.') && resolve(abs) !== resolve(root)) return true;
|
||||||
|
if (gitIgnoredDirs(root).has(relative(root, abs).split(sep).join('/'))) return true;
|
||||||
|
return isWorktree(abs);
|
||||||
|
}
|
||||||
|
|
@ -14,7 +14,7 @@
|
||||||
// The comparison (webStaleness) and the capacitor config reading (webDirOf) are pure.
|
// The comparison (webStaleness) and the capacitor config reading (webDirOf) are pure.
|
||||||
import { createHash } from 'node:crypto';
|
import { createHash } from 'node:crypto';
|
||||||
import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs';
|
import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs';
|
||||||
import { dirname, join, relative, sep } from 'node:path';
|
import { dirname, join, relative, resolve, sep } from 'node:path';
|
||||||
import type { ShipConfig } from './config';
|
import type { ShipConfig } from './config';
|
||||||
import { log, warn } from './log';
|
import { log, warn } from './log';
|
||||||
import { pump } from './runner';
|
import { pump } from './runner';
|
||||||
|
|
@ -89,7 +89,7 @@ export function capacitorCandidates(root: string): string[] {
|
||||||
*/
|
*/
|
||||||
export function capacitorProject(root: string, hint?: string): CapProject | null {
|
export function capacitorProject(root: string, hint?: string): CapProject | null {
|
||||||
if (hint) {
|
if (hint) {
|
||||||
for (let d = join(root, hint); ; d = dirname(d)) {
|
for (let d = resolve(root, hint); ; d = dirname(d)) {
|
||||||
const rel = relative(root, d);
|
const rel = relative(root, d);
|
||||||
if (rel.startsWith('..')) break;
|
if (rel.startsWith('..')) break;
|
||||||
const c = capAt(root, rel.split(sep).join('/'));
|
const c = capAt(root, rel.split(sep).join('/'));
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
// Xcode builds without Xcode's UI: find the workspace / project and scheme (native, Capacitor, React Native, Flutter,
|
// Xcode builds without Xcode's UI: find the workspace / project and scheme (native, Capacitor, React Native, Flutter,
|
||||||
// Unity-exported projects), build the xcodebuild archive and export command lines, read an IPA's Info.plist.
|
// Unity-exported projects), build the xcodebuild archive and export command lines, read an IPA's Info.plist.
|
||||||
// Pure except scanXcode (a bounded directory walk) and ipaInfo (reads the IPA).
|
// Pure except scanXcode (a bounded directory walk) and ipaInfo (reads the IPA).
|
||||||
import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs';
|
import { existsSync, mkdirSync, readdirSync, readFileSync, statSync, writeFileSync } from 'node:fs';
|
||||||
import { basename, dirname, join, relative } from 'node:path';
|
import { basename, dirname, join, relative } from 'node:path';
|
||||||
import { parsePlist, type PlistValue } from './plist';
|
import { parsePlist, type PlistValue } from './plist';
|
||||||
import { zipEntries, zipRead } from './zip';
|
import { zipEntries, zipRead } from './zip';
|
||||||
|
|
@ -18,6 +18,10 @@ export interface AppleBuildConfig {
|
||||||
configuration?: string;
|
configuration?: string;
|
||||||
/** Output folder for the archive, ExportOptions.plist, the IPA and logs. Default build/ios. */
|
/** Output folder for the archive, ExportOptions.plist, the IPA and logs. Default build/ios. */
|
||||||
out?: string;
|
out?: string;
|
||||||
|
/** xcodebuild -derivedDataPath. Default <out>/DerivedData when the output folder is chosen (--out / out), else Xcode's own folder under ~/Library. */
|
||||||
|
derivedData?: string;
|
||||||
|
/** Remap the home folder, checkout, output folder and DerivedData out of the binary and the debug symbols, then scan the archive (same as --path-free). */
|
||||||
|
pathFree?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function validateAppleBuild(b: AppleBuildConfig | undefined): string[] {
|
export function validateAppleBuild(b: AppleBuildConfig | undefined): string[] {
|
||||||
|
|
@ -26,6 +30,8 @@ export function validateAppleBuild(b: AppleBuildConfig | undefined): string[] {
|
||||||
if (b.workspace && !b.workspace.endsWith('.xcworkspace')) e.push('apple.build.workspace: a path ending in .xcworkspace');
|
if (b.workspace && !b.workspace.endsWith('.xcworkspace')) e.push('apple.build.workspace: a path ending in .xcworkspace');
|
||||||
if (b.project && !b.project.endsWith('.xcodeproj')) e.push('apple.build.project: a path ending in .xcodeproj');
|
if (b.project && !b.project.endsWith('.xcodeproj')) e.push('apple.build.project: a path ending in .xcodeproj');
|
||||||
if (b.scheme !== undefined && !b.scheme.trim()) e.push('apple.build.scheme: empty');
|
if (b.scheme !== undefined && !b.scheme.trim()) e.push('apple.build.scheme: empty');
|
||||||
|
if (b.derivedData !== undefined && (typeof b.derivedData !== 'string' || !b.derivedData.trim())) e.push('apple.build.derivedData: a folder path');
|
||||||
|
if (b.pathFree !== undefined && typeof b.pathFree !== 'boolean') e.push('apple.build.pathFree: true or false');
|
||||||
return e;
|
return e;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -125,13 +131,13 @@ export interface AscAuth { keyPath: string; keyId: string; issuerId: string }
|
||||||
|
|
||||||
const authArgs = (a: AscAuth | null): string[] => (a ? ['-allowProvisioningUpdates', '-authenticationKeyPath', a.keyPath, '-authenticationKeyID', a.keyId, '-authenticationKeyIssuerID', a.issuerId] : []);
|
const authArgs = (a: AscAuth | null): string[] => (a ? ['-allowProvisioningUpdates', '-authenticationKeyPath', a.keyPath, '-authenticationKeyID', a.keyId, '-authenticationKeyIssuerID', a.issuerId] : []);
|
||||||
|
|
||||||
export interface ArchiveInput { target: XcodeTarget; root: string; configuration: string; archivePath: string; version?: string; build: string; teamId?: string; auth: AscAuth | null; /** extra build settings, e.g. OTHER_CODE_SIGN_FLAGS=--keychain <path> */ settings?: string[] }
|
export interface ArchiveInput { target: XcodeTarget; root: string; configuration: string; archivePath: string; version?: string; build: string; teamId?: string; auth: AscAuth | null; /** extra build settings, e.g. OTHER_CODE_SIGN_FLAGS=--keychain <path> */ settings?: string[]; /** xcodebuild -derivedDataPath */ derivedData?: string | null }
|
||||||
|
|
||||||
/** xcodebuild archive. Version / build go in as build settings (they beat the project's values). */
|
/** xcodebuild archive. Version / build go in as build settings (they beat the project's values). */
|
||||||
export function archiveArgs(i: ArchiveInput): string[] {
|
export function archiveArgs(i: ArchiveInput): string[] {
|
||||||
return ['xcodebuild', ...(i.target.workspace ? ['-workspace', join(i.root, i.target.workspace)] : ['-project', join(i.root, i.target.project!)]),
|
return ['xcodebuild', ...(i.target.workspace ? ['-workspace', join(i.root, i.target.workspace)] : ['-project', join(i.root, i.target.project!)]),
|
||||||
'-scheme', i.target.scheme, '-configuration', i.configuration, '-destination', 'generic/platform=iOS', '-archivePath', i.archivePath,
|
'-scheme', i.target.scheme, '-configuration', i.configuration, '-destination', 'generic/platform=iOS', '-archivePath', i.archivePath,
|
||||||
...authArgs(i.auth), 'archive', `CURRENT_PROJECT_VERSION=${i.build}`, ...(i.version ? [`MARKETING_VERSION=${i.version}`] : []),
|
...(i.derivedData ? ['-derivedDataPath', i.derivedData] : []), ...authArgs(i.auth), 'archive', `CURRENT_PROJECT_VERSION=${i.build}`, ...(i.version ? [`MARKETING_VERSION=${i.version}`] : []),
|
||||||
...(i.teamId ? [`DEVELOPMENT_TEAM=${i.teamId}`] : []), ...(i.settings ?? [])];
|
...(i.teamId ? [`DEVELOPMENT_TEAM=${i.teamId}`] : []), ...(i.settings ?? [])];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -260,3 +266,21 @@ export function remoteBuildSession(env: Record<string, string | undefined>, mana
|
||||||
if (managerName && managerName !== 'Aqua') return `this is not the logged-in GUI session (launchctl manager: ${managerName})`;
|
if (managerName && managerName !== 'Aqua') return `this is not the logged-in GUI session (launchctl manager: ${managerName})`;
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Where `apple build` notes its last IPA for `apple upload`: .storebound/last-apple-build.json (gitignored). */
|
||||||
|
export const lastBuildFile = (root: string): string => join(root, '.storebound', 'last-apple-build.json');
|
||||||
|
|
||||||
|
export function recordLastBuild(root: string, r: { ipa: string; out: string; version: string; build: string }): void {
|
||||||
|
try { mkdirSync(join(root, '.storebound'), { recursive: true }); writeFileSync(lastBuildFile(root), `${JSON.stringify(r, null, 2)}\n`); } catch { /* best effort */ }
|
||||||
|
}
|
||||||
|
|
||||||
|
export function readLastBuild(root: string): { ipa: string; out: string; version?: string; build?: string } | null {
|
||||||
|
try { const j = JSON.parse(readFileSync(lastBuildFile(root), 'utf8')); return typeof j?.ipa === 'string' && typeof j?.out === 'string' ? j : null; } catch { return null; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The export folders `apple upload` searches, in order: --out, else the last build's out (a --out that build used),
|
||||||
|
* then apple.build.out / build/ios. Duplicates dropped. */
|
||||||
|
export function uploadSearchDirs(o: { flagOut?: string; lastOut?: string; configOut: string }): string[] {
|
||||||
|
const dirs = o.flagOut ? [o.flagOut] : [...(o.lastOut ? [o.lastOut] : []), o.configOut];
|
||||||
|
return [...new Set(dirs.map(d => join(d, 'export')))];
|
||||||
|
}
|
||||||
|
|
|
||||||
15
cli/mcp-cmd.ts
Normal file
15
cli/mcp-cmd.ts
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
// `storebound mcp`: stdio by default (one process per agent session), or `--http` for one shared server
|
||||||
|
// (cli/mcp-http.ts: every session of the machine, or a team behind OAuth).
|
||||||
|
import type { parseArgs } from './lib/args';
|
||||||
|
|
||||||
|
export async function run(a: ReturnType<typeof parseArgs>): Promise<void> {
|
||||||
|
if (!a.has('http')) return (await import('./mcp')).serve();
|
||||||
|
const { serveHttp } = await import('./mcp-http');
|
||||||
|
await serveHttp({
|
||||||
|
host: a.get('host'), port: a.get('port'), roots: a.get('roots'), project: a.get('project'), allowOrigin: a.get('allow-origin'),
|
||||||
|
auth: a.get('auth'), tokenFile: a.get('token-file'), introspectUrl: a.get('introspect-url'), introspectKeyFile: a.get('introspect-key-file'),
|
||||||
|
resource: a.get('resource'), issuer: a.get('issuer'), allowRemoteToken: a.has('allow-remote-token'),
|
||||||
|
brokerProfiles: a.get('broker-profiles'), readOnly: a.has('read-only'),
|
||||||
|
public: a.has('public'), rate: a.get('rate'), trustProxy: a.has('trust-proxy'),
|
||||||
|
});
|
||||||
|
}
|
||||||
306
cli/mcp-http.ts
Normal file
306
cli/mcp-http.ts
Normal file
|
|
@ -0,0 +1,306 @@
|
||||||
|
// `storebound mcp --http`: the same MCP server over Streamable HTTP, so one process serves every agent session on a
|
||||||
|
// machine (or one host serves a whole team) instead of one stdio process per session.
|
||||||
|
// storebound mcp --http [--host 127.0.0.1] [--port 7787] [--roots <dir,dir>] [--project <dir>]
|
||||||
|
// [--auth token|introspect] [--token-file ~/.storebound/mcp-token]
|
||||||
|
// storebound mcp --http --public [--port 7788] [--host 127.0.0.1] [--rate 60] [--trust-proxy] (see below)
|
||||||
|
// [--introspect-url <url> --introspect-key-file <file> --resource <url> --issuer <url>]
|
||||||
|
// Transport (https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#streamable-http): one endpoint,
|
||||||
|
// /mcp. POST carries one JSON-RPC message and gets one JSON answer (202 for a notification); GET and DELETE are 405
|
||||||
|
// (no server-initiated stream, no session state: every call is independent, so no Mcp-Session-Id is issued). The
|
||||||
|
// Origin header, when sent, must be a localhost origin unless --allow-origin names it (DNS rebinding).
|
||||||
|
// Project: every tool gets a `project` argument, the absolute path of the app folder the CLI runs in. It must be inside
|
||||||
|
// --roots (default: the home folder); --project (or STOREBOUND_PROJECT) is the default when a call has none.
|
||||||
|
// Public (--public): the key-less server behind a public URL. No sign-in, no project, no store credentials; it serves only the
|
||||||
|
// read-only tools of mcp-public.ts (skills, pitfalls, limits, listing lint, App Store search), never starts a process, rate
|
||||||
|
// limited per client (--rate per minute, 429 + Retry-After; --trust-proxy reads the first X-Forwarded-For entry), body <= 64 KB.
|
||||||
|
// Auth (every request to /mcp):
|
||||||
|
// token (default): `Authorization: Bearer <token>`, the token in --token-file (made with mode 600 on first start;
|
||||||
|
// never printed). Clients: claude mcp add --transport http storebound http://127.0.0.1:7787/mcp
|
||||||
|
// --header "Authorization: Bearer $(cat ~/.storebound/mcp-token)".
|
||||||
|
// introspect: an OAuth 2.0 bearer token checked at --introspect-url (RFC 7662; this server authenticates with the
|
||||||
|
// key in --introspect-key-file). The token must be active, carry the `mcp` scope and name --resource in aud
|
||||||
|
// (RFC 8707). Without a valid token: 401 with WWW-Authenticate: Bearer resource_metadata=".../.well-known/
|
||||||
|
// oauth-protected-resource/mcp" (RFC 9728), which names --issuer as the authorization server. Answers are cached
|
||||||
|
// for 60 s per token (hashed); the token itself is never logged.
|
||||||
|
import { createHash, randomBytes } from 'node:crypto';
|
||||||
|
import { chmodSync, existsSync, mkdirSync, readFileSync, statSync, writeFileSync } from 'node:fs';
|
||||||
|
import { createServer, type IncomingMessage, type ServerResponse } from 'node:http';
|
||||||
|
import { homedir } from 'node:os';
|
||||||
|
import { dirname, isAbsolute, join, relative, resolve } from 'node:path';
|
||||||
|
import pkg from '../package.json' with { type: 'json' };
|
||||||
|
import { handle, LEGACY, PROTOCOL } from './mcp';
|
||||||
|
import { clientKey, createLimiter, publicSurface, type PublicDeps } from './mcp-public';
|
||||||
|
import { TOOLS } from './mcp-tools';
|
||||||
|
import { brokerConfig, brokerProfileEnv } from './lib/broker';
|
||||||
|
import { runCommand } from './lib/runner';
|
||||||
|
|
||||||
|
export const DEFAULT_PORT = 7787;
|
||||||
|
export const PUBLIC_PORT = 7788;
|
||||||
|
const MAX_BODY = 4 * 1024 * 1024;
|
||||||
|
/** SSE comment line interval while a tool call runs (proxies cut silent responses). */
|
||||||
|
export let SSE_KEEPALIVE_MS = 20_000;
|
||||||
|
export const setKeepaliveMs = (ms: number): void => { SSE_KEEPALIVE_MS = ms; };
|
||||||
|
/** Public mode: one JSON-RPC message of a read-only tool never needs more. */
|
||||||
|
export const PUBLIC_MAX_BODY = 64 * 1024;
|
||||||
|
export const PUBLIC_DEFAULT_RATE = 60;
|
||||||
|
|
||||||
|
export interface HttpOptions {
|
||||||
|
host: string;
|
||||||
|
port: number;
|
||||||
|
roots: string[];
|
||||||
|
project: string | null;
|
||||||
|
allowOrigins: string[];
|
||||||
|
/** Credential profiles to take from the broker vault for every call (no key files on this host). */
|
||||||
|
brokerProfiles?: string[];
|
||||||
|
/** Only the tools that change nothing (no dry_run tools at all). */
|
||||||
|
readOnly?: boolean;
|
||||||
|
/** Public key-less mode (`--public`): auth kind 'none', the tool surface of mcp-public.ts, a rate limit per client. */
|
||||||
|
public?: { rate: number; trustProxy: boolean } & PublicDeps;
|
||||||
|
auth: { kind: 'none' } | { kind: 'token'; token: string } | { kind: 'introspect'; url: string; key: string; resource: string; issuer: string };
|
||||||
|
}
|
||||||
|
|
||||||
|
export const PROJECT_PROP = { type: 'string', description: 'The app folder (the one with storebound.config.ts) to run in: an absolute path, or a folder name under the server roots. Required unless the server was started with --project.' } as const;
|
||||||
|
|
||||||
|
/** Inside one of the roots (path compare, case-insensitive on Windows); no "..", no other drive. */
|
||||||
|
export function insideRoots(dir: string, roots: string[]): boolean {
|
||||||
|
const norm = (p: string) => (process.platform === 'win32' ? resolve(p).toLowerCase() : resolve(p));
|
||||||
|
return roots.some(r => { const rel = relative(norm(r), norm(dir)); return rel === '' || (!rel.startsWith('..') && !isAbsolute(rel)); });
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The folder a call runs in, or the reason it cannot run. */
|
||||||
|
export function projectFor(arg: unknown, o: Pick<HttpOptions, 'roots' | 'project'>): { dir: string } | { error: string } {
|
||||||
|
if (arg === undefined || arg === null || arg === '') return o.project ? { dir: o.project } : { error: 'project: required (absolute path of the app folder)' };
|
||||||
|
// a plain folder name is a project under one of the roots (a shared server keeps its checkouts there)
|
||||||
|
if (typeof arg === 'string' && /^[A-Za-z0-9][A-Za-z0-9._-]{0,99}$/.test(arg)) {
|
||||||
|
const hit = o.roots.map(r => join(r, arg)).find(d => { try { return statSync(d).isDirectory(); } catch { return false; } });
|
||||||
|
return hit ? { dir: resolve(hit) } : { error: `project: no folder ${arg} under ${o.roots.join(', ')}` };
|
||||||
|
}
|
||||||
|
if (typeof arg !== 'string' || !isAbsolute(arg)) return { error: 'project: must be an absolute path, or a folder name under the roots' };
|
||||||
|
if (!insideRoots(arg, o.roots)) return { error: `project: ${arg} is outside the server's roots (${o.roots.join(', ')})` };
|
||||||
|
try { if (!statSync(arg).isDirectory()) return { error: `project: ${arg} is not a folder` }; } catch { return { error: `project: ${arg} does not exist` }; }
|
||||||
|
return { dir: resolve(arg) };
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Localhost origins are always fine; others only when listed. No Origin header (non-browser clients) is fine. */
|
||||||
|
export function originAllowed(origin: string | undefined, allow: string[]): boolean {
|
||||||
|
if (!origin) return true;
|
||||||
|
if (allow.includes(origin)) return true;
|
||||||
|
try { const u = new URL(origin); return ['localhost', '127.0.0.1', '[::1]'].includes(u.hostname); } catch { return false; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The protected resource metadata URL for a resource URL (RFC 9728 section 3: the path goes after the well-known part). */
|
||||||
|
export function metadataUrl(resource: string): string {
|
||||||
|
const u = new URL(resource);
|
||||||
|
return `${u.origin}/.well-known/oauth-protected-resource${u.pathname === '/' ? '' : u.pathname}`;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Introspection answer -> allowed? (active, `mcp` scope, our resource in aud). */
|
||||||
|
export function introspectionOk(j: unknown, resource: string): boolean {
|
||||||
|
if (!j || typeof j !== 'object') return false;
|
||||||
|
const r = j as { active?: unknown; scope?: unknown; aud?: unknown };
|
||||||
|
if (r.active !== true) return false;
|
||||||
|
const scopes = typeof r.scope === 'string' ? r.scope.split(/\s+/) : [];
|
||||||
|
if (!scopes.includes('mcp')) return false;
|
||||||
|
const aud = Array.isArray(r.aud) ? r.aud : typeof r.aud === 'string' ? [r.aud] : [];
|
||||||
|
return aud.includes(resource);
|
||||||
|
}
|
||||||
|
|
||||||
|
const bearer = (req: IncomingMessage): string | null => { const h = req.headers.authorization ?? ''; const m = /^Bearer\s+(\S+)$/i.exec(h); return m ? m[1]! : null; };
|
||||||
|
|
||||||
|
const cache = new Map<string, { ok: boolean; until: number }>();
|
||||||
|
async function authorized(req: IncomingMessage, o: HttpOptions): Promise<boolean> {
|
||||||
|
const t = bearer(req);
|
||||||
|
if (!t || o.auth.kind === 'none') return false;
|
||||||
|
if (o.auth.kind === 'token') {
|
||||||
|
const a = createHash('sha256').update(t).digest(), b = createHash('sha256').update(o.auth.token).digest();
|
||||||
|
return a.equals(b);
|
||||||
|
}
|
||||||
|
const key = createHash('sha256').update(t).digest('hex');
|
||||||
|
const hit = cache.get(key);
|
||||||
|
if (hit && hit.until > Date.now()) return hit.ok;
|
||||||
|
let ok = false;
|
||||||
|
try {
|
||||||
|
const r = await fetch(o.auth.url, { method: 'POST', signal: AbortSignal.timeout(10_000),
|
||||||
|
headers: { authorization: `Bearer ${o.auth.key}`, 'content-type': 'application/x-www-form-urlencoded', accept: 'application/json' },
|
||||||
|
body: new URLSearchParams({ token: t }).toString() });
|
||||||
|
ok = r.ok && introspectionOk(await r.json(), o.auth.resource);
|
||||||
|
} catch { return false; } // no cache on a network error
|
||||||
|
cache.set(key, { ok, until: Date.now() + 60_000 });
|
||||||
|
return ok;
|
||||||
|
}
|
||||||
|
|
||||||
|
function sendRaw(res: ServerResponse, status: number, body?: unknown, headers: Record<string, string> = {}): void {
|
||||||
|
res.writeHead(status, { 'cache-control': 'no-store', ...(body === undefined ? {} : { 'content-type': 'application/json' }), ...headers });
|
||||||
|
res.end(body === undefined ? undefined : JSON.stringify(body));
|
||||||
|
}
|
||||||
|
|
||||||
|
async function readBody(req: IncomingMessage, max = MAX_BODY): Promise<string | null> {
|
||||||
|
let size = 0; const parts: Buffer[] = [];
|
||||||
|
for await (const c of req) { size += (c as Buffer).length; if (size > max) return null; parts.push(c as Buffer); }
|
||||||
|
return Buffer.concat(parts).toString('utf8');
|
||||||
|
}
|
||||||
|
|
||||||
|
/** One POST body -> the answer (null for a notification). tools/list gains `project`; tools/call runs in it. */
|
||||||
|
export async function answer(msg: Record<string, unknown>, o: Pick<HttpOptions, 'roots' | 'project'> & { readOnly?: boolean },
|
||||||
|
run: (argv: string[], cwd: string) => Promise<{ code: number; out: string }> = runIn): Promise<Record<string, unknown> | null> {
|
||||||
|
const params = (msg.params ?? {}) as Record<string, unknown>;
|
||||||
|
if (msg.method === 'tools/call') {
|
||||||
|
if (o.readOnly && TOOLS.find(t => t.name === params.name)?.write) return { jsonrpc: '2.0', id: msg.id ?? null, error: { code: -32602, message: `Unknown tool: ${String(params.name)} (this server is read-only)` } };
|
||||||
|
const args = { ...((params.arguments ?? {}) as Record<string, unknown>) };
|
||||||
|
const p = projectFor(args.project, o);
|
||||||
|
if ('error' in p) return { jsonrpc: '2.0', id: msg.id ?? null, result: { content: [{ type: 'text', text: `Invalid arguments: ${p.error}` }], isError: true } };
|
||||||
|
delete args.project;
|
||||||
|
return handle({ ...msg, params: { ...params, arguments: args } } as never, argv => run(argv, p.dir));
|
||||||
|
}
|
||||||
|
const r = await handle(msg as never);
|
||||||
|
if (msg.method === 'tools/list' && r && typeof r.result === 'object') {
|
||||||
|
const res = r.result as { tools?: { name: string; annotations?: { readOnlyHint?: boolean }; inputSchema: { properties: Record<string, unknown>; required?: string[] } }[] };
|
||||||
|
if (o.readOnly) res.tools = (res.tools ?? []).filter(t => t.annotations?.readOnlyHint === true);
|
||||||
|
const tools = res.tools ?? [];
|
||||||
|
for (const t of tools) {
|
||||||
|
t.inputSchema.properties = { project: PROJECT_PROP, ...t.inputSchema.properties };
|
||||||
|
if (!o.project) t.inputSchema.required = ['project', ...(t.inputSchema.required ?? [])];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return r;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Public mode never runs the CLI: a call that would is a bug, not a request. */
|
||||||
|
const noRun = async (): Promise<{ code: number; out: string }> => { throw new Error('public mode does not run commands'); };
|
||||||
|
|
||||||
|
let brokerEnv: { env: Promise<Record<string, string>>; until: number } | null = null;
|
||||||
|
/** The broker profiles' credentials as child env, fetched at most every 10 minutes (memory only, never logged). */
|
||||||
|
async function profileEnvFor(profiles: string[] | undefined): Promise<Record<string, string>> {
|
||||||
|
if (!profiles?.length) return {};
|
||||||
|
if (!brokerEnv || brokerEnv.until < Date.now()) {
|
||||||
|
const cfg = brokerConfig();
|
||||||
|
if (!cfg) throw new Error('--broker-profiles needs a credential broker (~/.storebound/broker.json or STOREBOUND_BROKER_URL)');
|
||||||
|
const env = brokerProfileEnv(cfg, profiles);
|
||||||
|
brokerEnv = { env, until: Date.now() + 600_000 };
|
||||||
|
env.catch(() => { brokerEnv = null; });
|
||||||
|
}
|
||||||
|
return brokerEnv.env;
|
||||||
|
}
|
||||||
|
let serverProfiles: string[] | undefined;
|
||||||
|
|
||||||
|
async function runIn(argv: string[], cwd: string): Promise<{ code: number; out: string }> {
|
||||||
|
const r = runCommand(argv, { cwd, env: { STOREBOUND_MCP: '1', ...(await profileEnvFor(serverProfiles)) } });
|
||||||
|
const { code, out } = await r.result;
|
||||||
|
return { code, out };
|
||||||
|
}
|
||||||
|
|
||||||
|
export function startHttp(o: HttpOptions): Promise<{ close: () => void; port: number }> {
|
||||||
|
serverProfiles = o.brokerProfiles;
|
||||||
|
if (o.auth.kind === 'none' && !o.public) throw new Error('auth none is only for --public');
|
||||||
|
const pub = o.public ? { limiter: createLimiter(o.public.rate), surface: publicSurface(o.public), trustProxy: o.public.trustProxy } : null;
|
||||||
|
// no ambient credential in public mode, so any browser origin may call it
|
||||||
|
const cors: Record<string, string> = pub ? { 'access-control-allow-origin': '*', 'access-control-allow-methods': 'POST, OPTIONS', 'access-control-allow-headers': 'content-type, accept, mcp-protocol-version', 'access-control-max-age': '86400' } : {};
|
||||||
|
const send = (res: ServerResponse, status: number, body?: unknown, headers: Record<string, string> = {}) => sendRaw(res, status, body, { ...cors, ...headers });
|
||||||
|
const resourceMeta = o.auth.kind === 'introspect' ? metadataUrl(o.auth.resource) : null;
|
||||||
|
const server = createServer(async (req, res) => {
|
||||||
|
const path = (req.url ?? '/').split('?')[0];
|
||||||
|
if (resourceMeta && o.auth.kind === 'introspect' && req.method === 'GET' && path === new URL(resourceMeta).pathname)
|
||||||
|
return send(res, 200, { resource: o.auth.resource, authorization_servers: [o.auth.issuer], bearer_methods_supported: ['header'], scopes_supported: ['mcp'], resource_name: 'storebound' });
|
||||||
|
if (path === '/health' && req.method === 'GET') return send(res, 200, { ok: true, version: pkg.version });
|
||||||
|
// public: the bare host is the MCP endpoint too (people paste "mcp.example.com" into a connector), and a browser
|
||||||
|
// opening it gets the connect line instead of a 404
|
||||||
|
if (pub && path === '/' && req.method === 'GET') {
|
||||||
|
// a person in a browser goes to the landing page; any other client gets the connect line
|
||||||
|
if (/text\/html/.test(String(req.headers.accept ?? ''))) { res.writeHead(302, { ...cors, location: 'https://storebound.dev/' }); return res.end(); }
|
||||||
|
res.writeHead(200, { ...cors, 'content-type': 'text/plain; charset=utf-8' });
|
||||||
|
return res.end(`storebound MCP server ${pkg.version} (read-only, no key)\nAdd it as a remote MCP server / custom connector with this URL. Claude Code: claude mcp add --transport http storebound <this URL>\n`);
|
||||||
|
}
|
||||||
|
if (path !== '/mcp' && !(pub && path === '/')) return send(res, 404, { error: 'not found' });
|
||||||
|
if (pub) {
|
||||||
|
if (req.method === 'OPTIONS') return send(res, 204);
|
||||||
|
const hit = pub.limiter.hit(clientKey(req.headers['x-forwarded-for'], req.socket.remoteAddress, pub.trustProxy));
|
||||||
|
if (!hit.ok) return send(res, 429, { error: 'rate limit exceeded' }, { 'retry-after': String(hit.retryAfter) });
|
||||||
|
} else if (!originAllowed(req.headers.origin, o.allowOrigins)) return send(res, 403, { error: 'origin not allowed' });
|
||||||
|
if (!pub && !(await authorized(req, o)))
|
||||||
|
return send(res, 401, { error: 'unauthorized' }, { 'www-authenticate': resourceMeta ? `Bearer resource_metadata="${resourceMeta}"` : 'Bearer' });
|
||||||
|
if (req.method !== 'POST') return send(res, 405, { error: 'POST only (no server-initiated stream)' }, { allow: 'POST' });
|
||||||
|
const body = await readBody(req, pub ? PUBLIC_MAX_BODY : MAX_BODY);
|
||||||
|
if (body === null) return send(res, 413, { error: 'body too large' });
|
||||||
|
let msg: unknown;
|
||||||
|
try { msg = JSON.parse(body); } catch { return send(res, 400, { jsonrpc: '2.0', id: null, error: { code: -32700, message: 'Parse error' } }); }
|
||||||
|
if (Array.isArray(msg) || typeof msg !== 'object' || msg === null) return send(res, 400, { jsonrpc: '2.0', id: null, error: { code: -32600, message: 'One JSON-RPC message per request' } });
|
||||||
|
const work = (async () => {
|
||||||
|
try { return pub ? await handle(msg as never, noRun, pub.surface) : await answer(msg as Record<string, unknown>, o); }
|
||||||
|
catch (e) { return { jsonrpc: '2.0', id: (msg as { id?: unknown }).id ?? null, error: { code: -32603, message: String((e as Error).message) } }; }
|
||||||
|
})();
|
||||||
|
// A tool call may run for minutes; a proxy (Cloudflare: 100 s) cuts a response that sends nothing. A client that
|
||||||
|
// accepts SSE gets the answer as one SSE event with a comment line every 20 s until then.
|
||||||
|
if ((msg as { method?: unknown }).method === 'tools/call' && /text\/event-stream/.test(String(req.headers.accept ?? ''))) {
|
||||||
|
res.writeHead(200, { 'content-type': 'text/event-stream', 'cache-control': 'no-store', 'x-accel-buffering': 'no' });
|
||||||
|
res.write(': started\n\n');
|
||||||
|
const beat = setInterval(() => res.write(': keepalive\n\n'), SSE_KEEPALIVE_MS);
|
||||||
|
const r = await work.finally(() => clearInterval(beat));
|
||||||
|
res.end(`event: message\ndata: ${JSON.stringify(r)}\n\n`);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const r = await work;
|
||||||
|
return r ? send(res, 200, r) : send(res, 202);
|
||||||
|
});
|
||||||
|
// a tool call can run for many minutes (check on a big project, uploads): Node's 300 s request timeout would cut it
|
||||||
|
server.requestTimeout = 0;
|
||||||
|
server.timeout = 0;
|
||||||
|
return new Promise((ok, fail) => {
|
||||||
|
server.once('error', fail);
|
||||||
|
server.listen(o.port, o.host, () => {
|
||||||
|
const a = server.address(); const port = typeof a === 'object' && a ? a.port : o.port;
|
||||||
|
ok({ close: () => server.close(), port });
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The local bearer token: read, or made (32 random bytes, hex, mode 600) on first start. */
|
||||||
|
export function tokenFrom(file: string): string {
|
||||||
|
if (existsSync(file)) { const t = readFileSync(file, 'utf8').trim(); if (t.length >= 32) return t; }
|
||||||
|
mkdirSync(dirname(file), { recursive: true });
|
||||||
|
const t = randomBytes(32).toString('hex');
|
||||||
|
writeFileSync(file, `${t}\n`, { mode: 0o600 });
|
||||||
|
try { chmodSync(file, 0o600); } catch { /* Windows */ }
|
||||||
|
return t;
|
||||||
|
}
|
||||||
|
|
||||||
|
const home = (p: string) => (p.startsWith('~') ? join(homedir(), p.slice(1)) : p);
|
||||||
|
|
||||||
|
export interface HttpFlags { host?: string; port?: string; roots?: string; project?: string; allowOrigin?: string; auth?: string; tokenFile?: string;
|
||||||
|
introspectUrl?: string; introspectKeyFile?: string; resource?: string; issuer?: string; allowRemoteToken?: boolean;
|
||||||
|
brokerProfiles?: string; readOnly?: boolean; public?: boolean; rate?: string; trustProxy?: boolean }
|
||||||
|
|
||||||
|
export async function serveHttp(f: HttpFlags): Promise<void> {
|
||||||
|
const host = f.host ?? '127.0.0.1';
|
||||||
|
if (f.public) {
|
||||||
|
const bad = (['auth', 'tokenFile', 'roots', 'project', 'brokerProfiles', 'allowOrigin', 'introspectUrl'] as const).filter(k => f[k] !== undefined);
|
||||||
|
if (bad.length || f.readOnly) throw new Error('--public takes no credentials or project: do not combine it with --auth, --token-file, --roots, --project, --broker-profiles, --allow-origin, --introspect-* or --read-only');
|
||||||
|
const rate = Number(f.rate ?? PUBLIC_DEFAULT_RATE);
|
||||||
|
if (!Number.isInteger(rate) || rate < 1) throw new Error('--rate: requests per minute per client, a whole number >= 1');
|
||||||
|
const port = Number(f.port ?? PUBLIC_PORT);
|
||||||
|
const s = await startHttp({ host, port, roots: [], project: null, allowOrigins: [], auth: { kind: 'none' }, public: { rate, trustProxy: !!f.trustProxy } });
|
||||||
|
console.error(`[storebound mcp] ${pkg.version} PUBLIC key-less server on http://${host}:${s.port}/mcp (MCP ${PROTOCOL}, legacy ${LEGACY.join(', ')}), read-only, ${rate} requests/min per client${f.trustProxy ? ', X-Forwarded-For trusted' : ''}`);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const port = Number(f.port ?? DEFAULT_PORT);
|
||||||
|
const roots = (f.roots ?? homedir()).split(',').map(s => resolve(home(s.trim()))).filter(Boolean);
|
||||||
|
const projectArg = f.project ?? process.env.STOREBOUND_PROJECT;
|
||||||
|
const project = projectArg ? resolve(home(projectArg)) : null;
|
||||||
|
const allowOrigins = (f.allowOrigin ?? '').split(',').map(s => s.trim()).filter(Boolean);
|
||||||
|
const kind = f.auth ?? 'token';
|
||||||
|
let auth: HttpOptions['auth'];
|
||||||
|
if (kind === 'introspect') {
|
||||||
|
const { introspectUrl: url, introspectKeyFile: keyFile, resource, issuer } = f;
|
||||||
|
if (!url || !keyFile || !resource || !issuer) throw new Error('--auth introspect needs --introspect-url, --introspect-key-file, --resource and --issuer');
|
||||||
|
auth = { kind, url, key: readFileSync(home(keyFile), 'utf8').trim(), resource, issuer };
|
||||||
|
} else if (kind === 'token') {
|
||||||
|
const file = home(f.tokenFile ?? '~/.storebound/mcp-token');
|
||||||
|
auth = { kind, token: tokenFrom(file) };
|
||||||
|
console.error(`[storebound mcp] bearer token in ${file}`);
|
||||||
|
} else throw new Error('--auth token | introspect');
|
||||||
|
if (!['127.0.0.1', 'localhost', '::1'].includes(host) && kind === 'token' && !f.allowRemoteToken)
|
||||||
|
throw new Error(`--host ${host} listens beyond this machine: use --auth introspect (or --allow-remote-token behind your own TLS proxy)`);
|
||||||
|
const brokerProfiles = (f.brokerProfiles ?? '').split(',').map(s => s.trim()).filter(Boolean);
|
||||||
|
if (brokerProfiles.length) await profileEnvFor(brokerProfiles).catch(e => { throw new Error(`--broker-profiles: ${(e as Error).message}`); });
|
||||||
|
const s = await startHttp({ host, port, roots, project, allowOrigins, auth, brokerProfiles, readOnly: !!f.readOnly });
|
||||||
|
console.error(`[storebound mcp] ${pkg.version} on http://${host}:${s.port}/mcp (MCP ${PROTOCOL}, legacy ${LEGACY.join(', ')}), auth ${kind}${f.readOnly ? ', read-only' : ''}${brokerProfiles.length ? `, broker profiles ${brokerProfiles.join(', ')}` : ''}, roots ${roots.join(', ')}${project ? `, default project ${project}` : ''}`);
|
||||||
|
}
|
||||||
329
cli/mcp-public.ts
Normal file
329
cli/mcp-public.ts
Normal file
|
|
@ -0,0 +1,329 @@
|
||||||
|
// The public, key-less MCP surface (`storebound mcp --http --public`): what anyone may call without signing in.
|
||||||
|
// Everything is pure and in-process. This module never reads store credentials, project folders or the cwd, never
|
||||||
|
// starts a child process (no runner, no CLI) and makes one kind of network call: the public iTunes Search API
|
||||||
|
// (aso_search). The only files it reads are the skills/ folder of the storebound package itself.
|
||||||
|
import { existsSync, readdirSync, readFileSync } from 'node:fs';
|
||||||
|
import { dirname, join, resolve } from 'node:path';
|
||||||
|
import { fileURLToPath } from 'node:url';
|
||||||
|
import type { Surface } from './mcp';
|
||||||
|
import { APPLE_LIMITS, PLAY_LIMITS } from './lib/copy';
|
||||||
|
import { parseFrontMatter } from './lib/frontmatter';
|
||||||
|
import { appleLocaleIssues, playLangIssues } from './lib/listing-rules';
|
||||||
|
import { IMAGE_SPECS, PREVIEW_RULES, VIDEO_TARGETS } from './shots/spec';
|
||||||
|
|
||||||
|
export const PUBLIC_INSTRUCTIONS = [
|
||||||
|
'This is the public, key-less storebound server: anyone may use it, it needs no sign-in and it never touches store accounts, keys or project files.',
|
||||||
|
'It is read-only and offers store knowledge: the skills (skills_list, skill_get), known store pitfalls (pitfalls_search), listing and screenshot limits (store_limits), a text linter for App Store / Google Play listings (listing_lint) and a public App Store search (aso_search).',
|
||||||
|
'For real store work (builds, uploads, listings, releases) install the toolchain: `npx storebound` (see https://storebound.dev) and use its own MCP server, `npx storebound mcp`.',
|
||||||
|
].join(' ');
|
||||||
|
|
||||||
|
export interface PublicDeps {
|
||||||
|
/** The folder with <name>/SKILL.md files. Default: skills/ of the storebound package that contains this file. */
|
||||||
|
skillsDir?: string;
|
||||||
|
/** iTunes Search API endpoint (tests point it at a local fake). */
|
||||||
|
searchBase?: string;
|
||||||
|
fetch?: typeof fetch;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface PublicResult { text: string; data?: unknown; isError?: boolean }
|
||||||
|
export interface PublicTool {
|
||||||
|
name: string; title: string; description: string;
|
||||||
|
inputSchema: { type: 'object'; properties: Record<string, Schema>; required?: string[]; additionalProperties: false };
|
||||||
|
network?: boolean;
|
||||||
|
run(input: Record<string, unknown>): Promise<PublicResult> | PublicResult;
|
||||||
|
}
|
||||||
|
export interface Schema { type: string; description?: string; enum?: string[]; pattern?: string; minLength?: number; maxLength?: number; minimum?: number; maximum?: number;
|
||||||
|
properties?: Record<string, Schema>; additionalProperties?: boolean }
|
||||||
|
|
||||||
|
export const SEARCH_BASE = 'https://itunes.apple.com/search';
|
||||||
|
const MAX_TEXT = 40_000;
|
||||||
|
const SKILL_NAME = /^[a-z0-9-]+$/;
|
||||||
|
|
||||||
|
// ---- input validation (JSON-Schema subset these tools use) ----
|
||||||
|
|
||||||
|
export function validatePublic(schema: Schema, input: unknown, path = ''): string[] {
|
||||||
|
const e: string[] = [];
|
||||||
|
if (input === undefined || input === null) input = {};
|
||||||
|
if (typeof input !== 'object' || Array.isArray(input)) return [`${path || 'arguments'}: must be an object`];
|
||||||
|
const i = input as Record<string, unknown>;
|
||||||
|
const props = schema.properties ?? {};
|
||||||
|
for (const r of (schema as { required?: string[] }).required ?? []) if (i[r] === undefined) e.push(`${path}${r}: required`);
|
||||||
|
for (const [k, v] of Object.entries(i)) {
|
||||||
|
const p = props[k];
|
||||||
|
if (!p) { e.push(`${path}${k}: unknown argument`); continue; }
|
||||||
|
if (v === undefined) continue;
|
||||||
|
if (p.type === 'object') { e.push(...validatePublic(p, v, `${path}${k}.`)); continue; }
|
||||||
|
if (p.type === 'string') {
|
||||||
|
if (typeof v !== 'string') { e.push(`${path}${k}: must be a string`); continue; }
|
||||||
|
if (p.enum && !p.enum.includes(v)) e.push(`${path}${k}: one of ${p.enum.join(', ')}`);
|
||||||
|
if (p.pattern && !new RegExp(p.pattern).test(v)) e.push(`${path}${k}: does not match ${p.pattern}`);
|
||||||
|
if (p.minLength !== undefined && v.length < p.minLength) e.push(`${path}${k}: at least ${p.minLength} characters`);
|
||||||
|
if (p.maxLength !== undefined && v.length > p.maxLength) e.push(`${path}${k}: at most ${p.maxLength} characters`);
|
||||||
|
} else if (p.type === 'integer') {
|
||||||
|
if (typeof v !== 'number' || !Number.isInteger(v)) { e.push(`${path}${k}: must be an integer`); continue; }
|
||||||
|
if (p.minimum !== undefined && v < p.minimum) e.push(`${path}${k}: >= ${p.minimum}`);
|
||||||
|
if (p.maximum !== undefined && v > p.maximum) e.push(`${path}${k}: <= ${p.maximum}`);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return e;
|
||||||
|
}
|
||||||
|
|
||||||
|
const clipText = (s: string, max = MAX_TEXT): string => (s.length <= max ? s : `${s.slice(0, max)}\n[... ${s.length - max} characters cut]`);
|
||||||
|
const oneLine = (s: string, max: number): string => { const t = s.replace(/\s+/g, ' ').trim(); return t.length <= max ? t : `${t.slice(0, max - 1)}…`; };
|
||||||
|
|
||||||
|
// ---- skills (from the package) ----
|
||||||
|
|
||||||
|
function packageSkillsDir(): string {
|
||||||
|
const start = dirname(fileURLToPath(import.meta.url));
|
||||||
|
for (let d = start; ; d = dirname(d)) {
|
||||||
|
try {
|
||||||
|
const pkg = JSON.parse(readFileSync(join(d, 'package.json'), 'utf8')) as { name?: string };
|
||||||
|
if (pkg.name === 'storebound') return join(d, 'skills');
|
||||||
|
} catch { /* keep looking */ }
|
||||||
|
if (dirname(d) === d) break;
|
||||||
|
}
|
||||||
|
return resolve(start, '..', 'skills');
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface SkillInfo { name: string; description: string; text: string }
|
||||||
|
|
||||||
|
export function loadSkills(dir: string): SkillInfo[] {
|
||||||
|
if (!existsSync(dir)) return [];
|
||||||
|
const out: SkillInfo[] = [];
|
||||||
|
for (const name of readdirSync(dir).filter(n => SKILL_NAME.test(n)).sort()) {
|
||||||
|
let text: string;
|
||||||
|
try { text = readFileSync(join(dir, name, 'SKILL.md'), 'utf8'); } catch { continue; }
|
||||||
|
const { data } = parseFrontMatter(text);
|
||||||
|
out.push({ name, description: oneLine(typeof data.description === 'string' ? data.description : '', 400), text });
|
||||||
|
}
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ---- pitfalls ----
|
||||||
|
|
||||||
|
export interface Section { heading: string; body: string }
|
||||||
|
export function sectionsOf(md: string): Section[] {
|
||||||
|
const parts = md.split(/^## /m).slice(1);
|
||||||
|
return parts.map(p => { const nl = p.indexOf('\n'); return { heading: (nl < 0 ? p : p.slice(0, nl)).trim(), body: nl < 0 ? '' : p.slice(nl + 1).trim() }; });
|
||||||
|
}
|
||||||
|
|
||||||
|
const APPLE_RE = /app store|apple|testflight|\bios\b|\basc\b|xcode|itunes/i;
|
||||||
|
const PLAY_RE = /google play|\bplay\b|\bgradle\b|\baab\b|android/i;
|
||||||
|
|
||||||
|
export function searchSections(sections: Section[], query: string, store?: 'apple' | 'play', max = 8): { heading: string; excerpt: string; score: number }[] {
|
||||||
|
const words = [...new Set(query.toLowerCase().split(/[^\p{L}\p{N}]+/u).filter(w => w.length > 1))].slice(0, 12);
|
||||||
|
if (!words.length) return [];
|
||||||
|
const scored = sections.map(s => {
|
||||||
|
const head = s.heading.toLowerCase(), body = s.body.toLowerCase();
|
||||||
|
let score = 0;
|
||||||
|
for (const w of words) { if (head.includes(w)) score += 5; const n = body.split(w).length - 1; score += Math.min(n, 5); }
|
||||||
|
return { s, score };
|
||||||
|
}).filter(x => x.score > 0);
|
||||||
|
const filtered = scored.filter(({ s }) => {
|
||||||
|
if (!store) return true;
|
||||||
|
const t = `${s.heading} ${s.body}`;
|
||||||
|
const a = APPLE_RE.test(t), p = PLAY_RE.test(t);
|
||||||
|
return store === 'apple' ? a || !p : p || !a;
|
||||||
|
});
|
||||||
|
return filtered.sort((a, b) => b.score - a.score).slice(0, max).map(({ s, score }) => {
|
||||||
|
// the excerpt starts at the first matching line
|
||||||
|
const lines = s.body.split('\n');
|
||||||
|
const at = Math.max(0, lines.findIndex(l => words.some(w => l.toLowerCase().includes(w))));
|
||||||
|
return { heading: s.heading, score, excerpt: clipText(lines.slice(at).join('\n'), 1200) };
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// ---- limits ----
|
||||||
|
|
||||||
|
export function limits(store?: 'apple' | 'play'): Record<string, unknown> {
|
||||||
|
const specs = (s: 'apple' | 'play') => Object.entries(IMAGE_SPECS).filter(([, v]) => v.store === s).map(([key, v]) => ({
|
||||||
|
key, type: v.type, label: v.label, acceptedPixelSizes: v.sizes.map(([w, h]) => `${w}x${h}`), perSet: `${v.min}-${v.max}`,
|
||||||
|
maxBytes: v.maxBytes, alpha: v.alpha, ...(v.landscapeOnly ? { landscapeOnly: true } : {}),
|
||||||
|
}));
|
||||||
|
const previews = (s: 'apple' | 'play') => Object.values(VIDEO_TARGETS).filter(v => v.store === s).map(v => ({ label: v.label, size: `${v.w}x${v.h}` }));
|
||||||
|
const apple = {
|
||||||
|
textLimitsCharacters: { ...APPLE_LIMITS },
|
||||||
|
keywordField: ['at most 100 characters (characters, not bytes)', 'comma-separated, no spaces around commas (they count)', 'fill at least 90 of the 100', 'no repeats of words already in the name or subtitle (they are indexed anyway)', 'no duplicates', 'single words combine on their own; multi-word phrases waste characters'],
|
||||||
|
screenshots: specs('apple'),
|
||||||
|
appPreviews: { targets: previews('apple'), ...PREVIEW_RULES },
|
||||||
|
};
|
||||||
|
const play = {
|
||||||
|
textLimitsCharacters: { ...PLAY_LIMITS },
|
||||||
|
screenshots: specs('play'),
|
||||||
|
images: { featureGraphic: '1024x500, JPEG or 24-bit PNG, no alpha', icon: '512x512 PNG (Play listing icon)' },
|
||||||
|
promoVideo: previews('play'),
|
||||||
|
};
|
||||||
|
return store === 'apple' ? { apple } : store === 'play' ? { play } : { apple, play };
|
||||||
|
}
|
||||||
|
|
||||||
|
// ---- listing lint ----
|
||||||
|
|
||||||
|
const APPLE_FIELDS = ['name', 'subtitle', 'keywords', 'promotionalText', 'description', 'whatsNew'] as const;
|
||||||
|
const PLAY_FIELDS = ['title', 'shortDescription', 'fullDescription', 'whatsNew'] as const;
|
||||||
|
const FIELD_MAX = 5000;
|
||||||
|
|
||||||
|
export function lintListing(store: 'apple' | 'play', fields: Record<string, unknown>, locale: string): { problems: { level: string; field: string; msg: string }[]; counts: Record<string, string> } {
|
||||||
|
const f = fields as Record<string, string | undefined>;
|
||||||
|
const counts: Record<string, string> = {};
|
||||||
|
let issues: { level: string; field: string; msg: string }[];
|
||||||
|
if (store === 'apple') {
|
||||||
|
const v = Object.fromEntries(APPLE_FIELDS.filter(k => f[k] !== undefined).map(k => [k, f[k]!]));
|
||||||
|
issues = appleLocaleIssues(locale, v, '');
|
||||||
|
// keywords with no name / subtitle given still get the stand-alone keyword rules
|
||||||
|
if (v.keywords === undefined) issues = issues.filter(i => i.field !== 'keywords');
|
||||||
|
for (const k of APPLE_FIELDS) if (v[k] !== undefined) counts[k] = `${[...v[k]!].length}/${APPLE_LIMITS[k]}`;
|
||||||
|
} else {
|
||||||
|
const v = { title: f.title, short: f.shortDescription, full: f.fullDescription, whatsNew: f.whatsNew };
|
||||||
|
issues = playLangIssues(locale, v, f.title ?? '');
|
||||||
|
for (const [k, lim] of [['title', 'title'], ['shortDescription', 'short'], ['fullDescription', 'full'], ['whatsNew', 'whatsNew']] as const)
|
||||||
|
if (f[k] !== undefined) counts[k] = `${[...f[k]!].length}/${PLAY_LIMITS[lim]}`;
|
||||||
|
const rename: Record<string, string> = { short: 'shortDescription', full: 'fullDescription' };
|
||||||
|
issues = issues.map(i => ({ ...i, field: rename[i.field] ?? i.field, msg: i.msg.replace(/^(short|full) is /, (_m, w: string) => `${rename[w]} is `) }));
|
||||||
|
}
|
||||||
|
// fields not given are not "missing": only the ones the caller sent are judged
|
||||||
|
const given = new Set(Object.keys(fields));
|
||||||
|
const problems = issues.filter(i => !/is required$|description is required$/.test(i.msg) || given.has(i.field));
|
||||||
|
return { problems: problems.map(i => ({ level: i.level, field: i.field, msg: i.msg })), counts };
|
||||||
|
}
|
||||||
|
|
||||||
|
// ---- iTunes search ----
|
||||||
|
|
||||||
|
interface ItunesApp { trackId?: number; trackName?: string; sellerName?: string; averageUserRating?: number; userRatingCount?: number; primaryGenreName?: string }
|
||||||
|
|
||||||
|
// Apple allows about 20 search calls a minute per IP: one shared budget for the whole server, whoever asks
|
||||||
|
const SEARCH_PER_MIN = 20;
|
||||||
|
const searchTimes: number[] = [];
|
||||||
|
export function searchBudget(now = Date.now()): { ok: true } | { ok: false; retryAfter: number } {
|
||||||
|
while (searchTimes.length && searchTimes[0]! <= now - 60_000) searchTimes.shift();
|
||||||
|
if (searchTimes.length >= SEARCH_PER_MIN) return { ok: false, retryAfter: Math.ceil((searchTimes[0]! + 60_000 - now) / 1000) };
|
||||||
|
searchTimes.push(now);
|
||||||
|
return { ok: true };
|
||||||
|
}
|
||||||
|
|
||||||
|
export async function searchApps(term: string, country: string, limit: number, base: string, f: typeof fetch): Promise<{ results: Record<string, unknown>[] }> {
|
||||||
|
const b = searchBudget();
|
||||||
|
if (!b.ok) throw new Error(`the App Store search is busy (Apple allows ${SEARCH_PER_MIN} calls a minute for this server): try again in ${b.retryAfter} s`);
|
||||||
|
const url = `${base}${base.includes('?') ? '&' : '?'}${new URLSearchParams({ term, country: country.toLowerCase(), media: 'software', entity: 'software', limit: String(limit) })}`;
|
||||||
|
const r = await f(url, { signal: AbortSignal.timeout(10_000), headers: { accept: 'application/json' } });
|
||||||
|
if (!r.ok) throw new Error(`the App Store search answered ${r.status}`);
|
||||||
|
const j = (await r.json()) as { results?: ItunesApp[] };
|
||||||
|
const results = (j.results ?? []).slice(0, limit).map((a, n) => ({
|
||||||
|
rank: n + 1, name: oneLine(a.trackName ?? '', 120), developer: oneLine(a.sellerName ?? '', 120), id: a.trackId ?? null,
|
||||||
|
rating: typeof a.averageUserRating === 'number' ? Math.round(a.averageUserRating * 100) / 100 : null,
|
||||||
|
ratingCount: a.userRatingCount ?? 0, genre: a.primaryGenreName ?? null,
|
||||||
|
}));
|
||||||
|
return { results };
|
||||||
|
}
|
||||||
|
|
||||||
|
// ---- the tools ----
|
||||||
|
|
||||||
|
const store: Schema = { type: 'string', enum: ['apple', 'play'] };
|
||||||
|
|
||||||
|
export function publicTools(deps: PublicDeps = {}): PublicTool[] {
|
||||||
|
let skills: SkillInfo[] | null = null;
|
||||||
|
const getSkills = () => (skills ??= loadSkills(deps.skillsDir ?? packageSkillsDir()));
|
||||||
|
const obj = (properties: Record<string, Schema>, required?: string[]): PublicTool['inputSchema'] => ({ type: 'object', properties, ...(required ? { required } : {}), additionalProperties: false });
|
||||||
|
const textField = (description: string, maxLength = FIELD_MAX): Schema => ({ type: 'string', description, maxLength });
|
||||||
|
const locale: Schema = { type: 'string', description: 'Locale or language id, e.g. en-US (default en-US)', pattern: '^[A-Za-z]{2,3}([-_][A-Za-z0-9]{2,8}){0,2}$', maxLength: 20 };
|
||||||
|
|
||||||
|
return [
|
||||||
|
{ name: 'skills_list', title: 'List storebound skills', description: 'Name and one-line description of every storebound skill (step-by-step guides for store releases, listings, screenshots, IAP, privacy, ASO ...).',
|
||||||
|
inputSchema: obj({}),
|
||||||
|
run: () => { const list = getSkills().map(s => ({ name: s.name, description: s.description })); return { text: list.map(s => `${s.name}: ${s.description}`).join('\n'), data: { skills: list } }; } },
|
||||||
|
{ name: 'skill_get', title: 'Read one skill', description: 'The full SKILL.md text of one skill (name from skills_list).',
|
||||||
|
inputSchema: obj({ name: { type: 'string', description: 'Skill name, e.g. aso-basics', pattern: SKILL_NAME.source, minLength: 1, maxLength: 80 } }, ['name']),
|
||||||
|
run: i => {
|
||||||
|
const s = getSkills().find(x => x.name === i.name);
|
||||||
|
if (!s) return { text: `Unknown skill: ${String(i.name)}. Call skills_list for the names.`, isError: true };
|
||||||
|
return { text: clipText(s.text, 120_000), data: { name: s.name } };
|
||||||
|
} },
|
||||||
|
{ name: 'pitfalls_search', title: 'Search known store pitfalls', description: 'Sections of the store-pitfalls skill (mistakes made in real App Store and Google Play releases) that match the query words, best first (at most 8, each clipped).',
|
||||||
|
inputSchema: obj({ query: { type: 'string', description: 'Words to look for, e.g. "keywords rejected screenshots"', minLength: 2, maxLength: 200 }, store }, ['query']),
|
||||||
|
run: i => {
|
||||||
|
const sk = getSkills().find(x => x.name === 'store-pitfalls');
|
||||||
|
if (!sk) return { text: 'The store-pitfalls skill is not in this package.', isError: true };
|
||||||
|
const hits = searchSections(sectionsOf(sk.text), String(i.query), i.store as 'apple' | 'play' | undefined);
|
||||||
|
if (!hits.length) return { text: 'No pitfall matches those words. Try fewer or different words.', data: { matches: [] } };
|
||||||
|
return { text: clipText(hits.map(h => `## ${h.heading}\n${h.excerpt}`).join('\n\n---\n\n')), data: { matches: hits.map(h => ({ heading: h.heading, score: h.score })) } };
|
||||||
|
} },
|
||||||
|
{ name: 'store_limits', title: 'Store listing and image limits', description: 'Listing field character limits, the App Store keyword field rules, screenshot and app preview sizes per device class and the Google Play feature graphic and icon sizes.',
|
||||||
|
inputSchema: obj({ store }),
|
||||||
|
run: i => { const d = limits(i.store as 'apple' | 'play' | undefined); return { text: JSON.stringify(d, null, 2), data: d }; } },
|
||||||
|
{ name: 'listing_lint', title: 'Lint a store listing', description: 'Runs storebound\'s listing and ASO checks on the text you give (limits, keyword field rules, repeated name words, other platforms or apps named, placeholder text, keyword stuffing). Only the fields you send are judged. Nothing is stored.',
|
||||||
|
inputSchema: obj({
|
||||||
|
store, locale,
|
||||||
|
fields: { type: 'object', description: 'Apple: name, subtitle, keywords, promotionalText, description, whatsNew. Play: title, shortDescription, fullDescription, whatsNew.', additionalProperties: false,
|
||||||
|
properties: Object.fromEntries([...new Set([...APPLE_FIELDS, ...PLAY_FIELDS])].map(k => [k, textField(`The ${k} text`)])) },
|
||||||
|
}, ['store', 'fields']),
|
||||||
|
run: i => {
|
||||||
|
const st = i.store as 'apple' | 'play';
|
||||||
|
const fields = i.fields as Record<string, unknown>;
|
||||||
|
const allowed: readonly string[] = st === 'apple' ? APPLE_FIELDS : PLAY_FIELDS;
|
||||||
|
const bad = Object.keys(fields).filter(k => !allowed.includes(k));
|
||||||
|
if (bad.length) return { text: `Invalid arguments: fields: ${bad.join(', ')} not used for ${st}; use ${allowed.join(', ')}`, isError: true };
|
||||||
|
if (!Object.keys(fields).length) return { text: 'Invalid arguments: fields: send at least one field', isError: true };
|
||||||
|
const r = lintListing(st, fields, String(i.locale ?? 'en-US').replace('_', '-'));
|
||||||
|
const lines = r.problems.map(p => `${p.level.toUpperCase()} ${p.field}: ${p.msg}`);
|
||||||
|
return { text: `${Object.entries(r.counts).map(([k, v]) => `${k} ${v}`).join(', ')}\n${lines.length ? lines.join('\n') : 'No problems found.'}`, data: r };
|
||||||
|
} },
|
||||||
|
{ name: 'aso_search', title: 'Search the App Store', description: 'The public iTunes Search API: the top apps for a search term in one storefront (name, developer, id, rating, rating count, genre). The order is close to, not the same as, App Store search.',
|
||||||
|
network: true,
|
||||||
|
inputSchema: obj({ term: { type: 'string', description: 'Search term', minLength: 1, maxLength: 100 }, country: { type: 'string', description: 'Two-letter storefront, default us', pattern: '^[A-Za-z]{2}$', minLength: 2, maxLength: 2 },
|
||||||
|
limit: { type: 'integer', description: 'Results, 1-25 (default 10)', minimum: 1, maximum: 25 } }, ['term']),
|
||||||
|
run: async i => {
|
||||||
|
try {
|
||||||
|
const r = await searchApps(String(i.term), String(i.country ?? 'us'), Number(i.limit ?? 10), deps.searchBase ?? SEARCH_BASE, deps.fetch ?? fetch);
|
||||||
|
return { text: r.results.map(a => `${a.rank}. ${String(a.name)} (${String(a.developer)}) id ${String(a.id)}, ${a.rating ?? 'no rating'} / ${String(a.ratingCount)} ratings, ${String(a.genre)}`).join('\n') || 'No results.', data: r };
|
||||||
|
} catch (e) { return { text: `Search failed: ${(e as Error).message}`, isError: true }; }
|
||||||
|
} },
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The surface handle() serves in public mode: only these tools exist (the type lives in mcp.ts). */
|
||||||
|
|
||||||
|
export function publicSurface(deps: PublicDeps = {}): Surface {
|
||||||
|
const tools = publicTools(deps);
|
||||||
|
return {
|
||||||
|
instructions: PUBLIC_INSTRUCTIONS,
|
||||||
|
list: () => tools.map(t => ({ name: t.name, title: t.title, description: t.description, inputSchema: t.inputSchema,
|
||||||
|
annotations: { title: t.title, readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: !!t.network } })),
|
||||||
|
call: async (name, input) => {
|
||||||
|
const t = tools.find(x => x.name === name);
|
||||||
|
if (!t) return null;
|
||||||
|
const problems = validatePublic(t.inputSchema, input);
|
||||||
|
if (problems.length) return { text: `Invalid arguments: ${problems.join('; ')}`, isError: true };
|
||||||
|
const r = await t.run((input ?? {}) as Record<string, unknown>);
|
||||||
|
return { ...r, text: clipText(r.text) };
|
||||||
|
},
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
// ---- rate limit ----
|
||||||
|
|
||||||
|
export interface Limiter { hit(key: string): { ok: boolean; retryAfter: number } }
|
||||||
|
|
||||||
|
/** Fixed one-minute window per client key, kept in memory; expired windows are swept so the map stays small. */
|
||||||
|
export function createLimiter(perMinute: number, now: () => number = Date.now): Limiter {
|
||||||
|
const win = new Map<string, { start: number; n: number }>();
|
||||||
|
let sweptAt = now();
|
||||||
|
return {
|
||||||
|
hit(key) {
|
||||||
|
const t = now();
|
||||||
|
if (t - sweptAt > 60_000 || win.size > 50_000) { for (const [k, w] of win) if (t - w.start >= 60_000) win.delete(k); sweptAt = t; }
|
||||||
|
let w = win.get(key);
|
||||||
|
if (!w || t - w.start >= 60_000) { w = { start: t, n: 0 }; win.set(key, w); }
|
||||||
|
w.n++;
|
||||||
|
return w.n <= perMinute ? { ok: true, retryAfter: 0 } : { ok: false, retryAfter: Math.max(1, Math.ceil((w.start + 60_000 - t) / 1000)) };
|
||||||
|
},
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The client key: the first X-Forwarded-For entry only when the proxy is trusted, else the socket address. */
|
||||||
|
export function clientKey(forwardedFor: string | string[] | undefined, remote: string | undefined, trustProxy: boolean): string {
|
||||||
|
if (trustProxy) {
|
||||||
|
const h = Array.isArray(forwardedFor) ? forwardedFor[0] : forwardedFor;
|
||||||
|
const first = h?.split(',')[0]?.trim();
|
||||||
|
if (first) return first.slice(0, 64);
|
||||||
|
}
|
||||||
|
return remote ?? 'unknown';
|
||||||
|
}
|
||||||
|
|
@ -219,7 +219,8 @@ export const TOOLS: ToolDef[] = [
|
||||||
{ name: 'apple_appinfo', title: 'App Store app info', command: ['apple', 'appinfo'], write: true, network: true, idempotent: true,
|
{ name: 'apple_appinfo', title: 'App Store app info', command: ['apple', 'appinfo'], write: true, network: true, idempotent: true,
|
||||||
description: 'Categories, age rating declaration, content rights, Free price and availability (when missing).' },
|
description: 'Categories, age rating declaration, content rights, Free price and availability (when missing).' },
|
||||||
{ name: 'apple_review_details', title: 'App Review information', command: ['apple', 'review-details'], write: true, network: true, idempotent: true,
|
{ name: 'apple_review_details', title: 'App Review information', command: ['apple', 'review-details'], write: true, network: true, idempotent: true,
|
||||||
description: 'App Review contact and, when reviewAccess.signInRequired, the demo account (both from .storebound/credentials.json or env, masked in the output), plus the review notes (apple.info.reviewNotes, sign-in instructions, where account deletion is).' },
|
description: 'App Review contact and, when reviewAccess.signInRequired, the demo account (both from .storebound/credentials.json or env, masked in the output), plus the review notes (apple.info.reviewNotes, or apple.macos.reviewNotes for platform macos; sign-in instructions, where account deletion is). Written to the editable version of the platform.',
|
||||||
|
props: { platform }, args: i => opt('platform', i.platform) },
|
||||||
{ name: 'apple_encryption', title: 'Export compliance answer', command: ['apple', 'encryption'], write: true, network: true, idempotent: true,
|
{ name: 'apple_encryption', title: 'Export compliance answer', command: ['apple', 'encryption'], write: true, network: true, idempotent: true,
|
||||||
description: 'Answer export compliance for builds from apple.usesNonExemptEncryption in the config (never guesses).',
|
description: 'Answer export compliance for builds from apple.usesNonExemptEncryption in the config (never guesses).',
|
||||||
props: { build: { type: 'string', description: 'Build number (default: every build without an answer)' } }, args: i => opt('build', i.build) },
|
props: { build: { type: 'string', description: 'Build number (default: every build without an answer)' } }, args: i => opt('build', i.build) },
|
||||||
|
|
|
||||||
21
cli/mcp.ts
21
cli/mcp.ts
|
|
@ -56,6 +56,13 @@ export const INSTRUCTIONS = [
|
||||||
'Run `check` (offline) and `validate` (read-only) before writes. Long uploads (images, screenshots) are better run in a terminal with a log.',
|
'Run `check` (offline) and `validate` (read-only) before writes. Long uploads (images, screenshots) are better run in a terminal with a log.',
|
||||||
].join(' ');
|
].join(' ');
|
||||||
|
|
||||||
|
/** A replacement tool surface (the public key-less server, mcp-public.ts): its own instructions, tool list and calls. */
|
||||||
|
export interface Surface {
|
||||||
|
instructions: string;
|
||||||
|
list(): Record<string, unknown>[];
|
||||||
|
call(name: string, input: unknown): Promise<{ text: string; data?: unknown; isError?: boolean } | null>;
|
||||||
|
}
|
||||||
|
|
||||||
type Id = string | number;
|
type Id = string | number;
|
||||||
interface Msg { jsonrpc: '2.0'; id?: Id; method?: string; params?: Record<string, unknown> }
|
interface Msg { jsonrpc: '2.0'; id?: Id; method?: string; params?: Record<string, unknown> }
|
||||||
|
|
||||||
|
|
@ -71,7 +78,7 @@ export function eraOf(m: Msg): { era: 'modern' | 'legacy'; version: string | nul
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Handles one message; returns the response object (or null for notifications). Exported for tests. */
|
/** Handles one message; returns the response object (or null for notifications). Exported for tests. */
|
||||||
export async function handle(m: Msg, run: (argv: string[], id: Id) => Promise<{ code: number; out: string }> = runCli): Promise<Record<string, unknown> | null> {
|
export async function handle(m: Msg, run: (argv: string[], id: Id) => Promise<{ code: number; out: string }> = runCli, surface?: Surface): Promise<Record<string, unknown> | null> {
|
||||||
const err = (code: number, message: string, data?: unknown) => ({ jsonrpc: '2.0', id: m.id ?? null, error: { code, message, ...(data === undefined ? {} : { data }) } });
|
const err = (code: number, message: string, data?: unknown) => ({ jsonrpc: '2.0', id: m.id ?? null, error: { code, message, ...(data === undefined ? {} : { data }) } });
|
||||||
if (m.id === undefined) {
|
if (m.id === undefined) {
|
||||||
if (m.method === 'notifications/cancelled') cancel(m.params?.requestId as Id);
|
if (m.method === 'notifications/cancelled') cancel(m.params?.requestId as Id);
|
||||||
|
|
@ -83,7 +90,7 @@ export async function handle(m: Msg, run: (argv: string[], id: Id) => Promise<{
|
||||||
protocolVersion: LEGACY.includes(asked) ? asked : LEGACY_PROTOCOL,
|
protocolVersion: LEGACY.includes(asked) ? asked : LEGACY_PROTOCOL,
|
||||||
capabilities: { tools: { listChanged: false } },
|
capabilities: { tools: { listChanged: false } },
|
||||||
serverInfo: { ...serverInfo(), description: pkg.description },
|
serverInfo: { ...serverInfo(), description: pkg.description },
|
||||||
instructions: INSTRUCTIONS,
|
instructions: surface?.instructions ?? INSTRUCTIONS,
|
||||||
} };
|
} };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -101,11 +108,17 @@ export async function handle(m: Msg, run: (argv: string[], id: Id) => Promise<{
|
||||||
|
|
||||||
switch (m.method) {
|
switch (m.method) {
|
||||||
case 'server/discover':
|
case 'server/discover':
|
||||||
return ok({ supportedVersions: SUPPORTED, capabilities: { tools: {} }, instructions: INSTRUCTIONS, ttlMs: TOOLS_TTL_MS, cacheScope: 'public' });
|
return ok({ supportedVersions: SUPPORTED, capabilities: { tools: {} }, instructions: surface?.instructions ?? INSTRUCTIONS, ttlMs: TOOLS_TTL_MS, cacheScope: 'public' });
|
||||||
case 'ping': return ok({});
|
case 'ping': return ok({});
|
||||||
case 'tools/list': return ok({ tools: listTools(bypassOn()), ...(era === 'modern' ? { ttlMs: TOOLS_TTL_MS, cacheScope: 'public' } : {}) });
|
case 'tools/list': return ok({ tools: surface ? surface.list() : listTools(bypassOn()), ...(era === 'modern' ? { ttlMs: TOOLS_TTL_MS, cacheScope: 'public' } : {}) });
|
||||||
case 'tools/call': {
|
case 'tools/call': {
|
||||||
const name = String(m.params?.name ?? '');
|
const name = String(m.params?.name ?? '');
|
||||||
|
if (surface) {
|
||||||
|
// public mode: only the surface's own tools exist; nothing below (the CLI tools, owner_step) is reachable
|
||||||
|
const r = await surface.call(name, m.params?.arguments ?? {});
|
||||||
|
if (!r) return err(-32602, `Unknown tool: ${name}`);
|
||||||
|
return ok({ content: [{ type: 'text', text: r.text }], ...(r.data === undefined ? {} : { structuredContent: { result: r.data } }), isError: !!r.isError });
|
||||||
|
}
|
||||||
const tool = TOOLS.find(t => t.name === name) ?? (name === OWNER_STEP.name && bypassOn() ? OWNER_STEP : undefined);
|
const tool = TOOLS.find(t => t.name === name) ?? (name === OWNER_STEP.name && bypassOn() ? OWNER_STEP : undefined);
|
||||||
if (!tool) return err(-32602, `Unknown tool: ${name}`);
|
if (!tool) return err(-32602, `Unknown tool: ${name}`);
|
||||||
const input = (m.params?.arguments ?? {}) as Record<string, unknown>;
|
const input = (m.params?.arguments ?? {}) as Record<string, unknown>;
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@
|
||||||
// Before Gradle runs, the app module's build file must read -PversionCode / -PversionName in defaultConfig (a literal
|
// Before Gradle runs, the app module's build file must read -PversionCode / -PversionName in defaultConfig (a literal
|
||||||
// or an env var keeps the AAB at that value; android.injected.version.* does not override it for bundleRelease): a
|
// or an env var keeps the AAB at that value; android.injected.version.* does not override it for bundleRelease): a
|
||||||
// warning with the exact line to use. After the build, an AAB whose versionCode is not the planned one is a hard stop.
|
// warning with the exact line to use. After the build, an AAB whose versionCode is not the planned one is a hard stop.
|
||||||
import { copyFileSync, existsSync, mkdirSync, writeFileSync } from 'node:fs';
|
import { chmodSync, copyFileSync, existsSync, mkdirSync, statSync, writeFileSync } from 'node:fs';
|
||||||
import { join, relative } from 'node:path';
|
import { join, relative } from 'node:path';
|
||||||
import { androidSigning } from '../lib/credentials';
|
import { androidSigning } from '../lib/credentials';
|
||||||
import type { Ctx } from '../lib/ctx';
|
import type { Ctx } from '../lib/ctx';
|
||||||
|
|
@ -108,6 +108,11 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
shipPhase('build', `${plan.task}, versionCode ${code || '?'}`);
|
shipPhase('build', `${plan.task}, versionCode ${code || '?'}`);
|
||||||
const started = Date.now();
|
const started = Date.now();
|
||||||
mkdirSync(out, { recursive: true });
|
mkdirSync(out, { recursive: true });
|
||||||
|
// a gradlew committed from Windows has no exec bit: macOS / Linux then say "Executable not found: ./gradlew"
|
||||||
|
if (hasWrapper && process.platform !== 'win32') {
|
||||||
|
const w = join(t.dir, 'gradlew');
|
||||||
|
if ((statSync(w).mode & 0o111) === 0) { chmodSync(w, statSync(w).mode | 0o755); log(TAG, `${relative(root, w)} had no exec bit (committed from Windows?): made it executable; commit it with git update-index --chmod=+x`); }
|
||||||
|
}
|
||||||
const p = rt.spawn(argv, { cwd, stdout: 'pipe', stderr: 'pipe', env: { ...process.env, ...androidSdkEnv(sdk), ...signingEnv(signing) } });
|
const p = rt.spawn(argv, { cwd, stdout: 'pipe', stderr: 'pipe', env: { ...process.env, ...androidSdkEnv(sdk), ...signingEnv(signing) } });
|
||||||
const lines: string[] = [];
|
const lines: string[] = [];
|
||||||
const each = (line: string): void => {
|
const each = (line: string): void => {
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ import { noteGoogle } from '../lib/quota';
|
||||||
import { AmbiguousWriteError, isAmbiguous, retrySafe } from '../lib/upsert';
|
import { AmbiguousWriteError, isAmbiguous, retrySafe } from '../lib/upsert';
|
||||||
import * as rt from '../lib/rt';
|
import * as rt from '../lib/rt';
|
||||||
import { withMachineLock } from '../lib/lock';
|
import { withMachineLock } from '../lib/lock';
|
||||||
import { clearPending, isReviewRefused, notSentMessage, publishingUrl, recordPending, withNotSent } from './review-pending';
|
import { clearPending, isAutoSendOnly, isReviewRefused, notSentMessage, publishingUrl, recordPending, withNotSent } from './review-pending';
|
||||||
|
|
||||||
/** A read's edit is gone: replaced by a newer edit of the app, committed elsewhere or expired. */
|
/** A read's edit is gone: replaced by a newer edit of the app, committed elsewhere or expired. */
|
||||||
export const EDIT_GONE = /Edit has been deleted|editAlreadyCommitted|already been committed|edit.*(expired|not found)|outside of this Edit/i;
|
export const EDIT_GONE = /Edit has been deleted|editAlreadyCommitted|already been committed|edit.*(expired|not found)|outside of this Edit/i;
|
||||||
|
|
@ -118,9 +118,15 @@ export async function playClient(root: string, packageName: string) {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
try { await commit(); } catch (err) {
|
try { await commit(); } catch (err) {
|
||||||
if (notSent || !isReviewRefused(err)) throw err;
|
if (notSent && isAutoSendOnly(err)) {
|
||||||
refused();
|
notSent = false;
|
||||||
await commit();
|
log('play', 'Play answered "Changes are sent for review automatically" (managed publishing is off): committing again without changesNotSentForReview; Play sends the changes for review itself');
|
||||||
|
await commit();
|
||||||
|
} else {
|
||||||
|
if (notSent || !isReviewRefused(err)) throw err;
|
||||||
|
refused();
|
||||||
|
await commit();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
openEdit = null;
|
openEdit = null;
|
||||||
log('play', `edit ${id} committed${notSent ? ' with changesNotSentForReview=true' : ''}`);
|
log('play', `edit ${id} committed${notSent ? ' with changesNotSentForReview=true' : ''}`);
|
||||||
|
|
|
||||||
42
cli/play/old-builds.ts
Normal file
42
cli/play/old-builds.ts
Normal file
|
|
@ -0,0 +1,42 @@
|
||||||
|
// Builds still active on a testing track below the production build (pitfall 129). Play reviews every active build
|
||||||
|
// with each submission: a policy issue in an old one (a media permission it asked for, "Use alternative system
|
||||||
|
// pickers") blocks "Send changes for review" for the whole app, while the API still reads production as completed.
|
||||||
|
// The Developer API cannot read a bundle's permissions, so each old build is named with the command that replaces it.
|
||||||
|
// Pure.
|
||||||
|
|
||||||
|
export interface TrackLike { track: string; releases?: { name?: string; versionCodes?: string[]; status: string }[] }
|
||||||
|
export interface OldBuild { track: string; versionCodes: number[]; name: string | null; status: string; productionCode: number }
|
||||||
|
|
||||||
|
/** Permissions Play reviews as policy-sensitive (Photo and video permissions, All files access). */
|
||||||
|
export const SENSITIVE_PERMISSIONS = ['READ_MEDIA_IMAGES', 'READ_MEDIA_VIDEO', 'READ_EXTERNAL_STORAGE', 'MANAGE_EXTERNAL_STORAGE', 'WRITE_EXTERNAL_STORAGE'];
|
||||||
|
|
||||||
|
const ACTIVE = new Set(['completed', 'inProgress', 'halted']);
|
||||||
|
const codes = (r: { versionCodes?: string[] }): number[] => (r.versionCodes ?? []).map(Number).filter(Number.isFinite);
|
||||||
|
|
||||||
|
export function oldTrackBuilds(tracks: TrackLike[]): OldBuild[] {
|
||||||
|
const prod = tracks.find(t => t.track === 'production');
|
||||||
|
const prodCodes = (prod?.releases ?? []).filter(r => ACTIVE.has(r.status)).flatMap(codes);
|
||||||
|
if (!prodCodes.length) return [];
|
||||||
|
const productionCode = Math.max(...prodCodes);
|
||||||
|
const out: OldBuild[] = [];
|
||||||
|
for (const t of tracks) {
|
||||||
|
if (t.track === 'production') continue;
|
||||||
|
for (const r of t.releases ?? []) {
|
||||||
|
const cs = codes(r);
|
||||||
|
if (!ACTIVE.has(r.status) || !cs.length || Math.max(...cs) >= productionCode) continue;
|
||||||
|
out.push({ track: t.track, versionCodes: cs, name: r.name ?? null, status: r.status, productionCode });
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The track flag of `play release` for a track name (custom closed tracks go by --track). */
|
||||||
|
const trackFlag = (track: string): string => (['internal', 'alpha', 'beta'].includes(track) ? `--${track}` : `--track ${track}`);
|
||||||
|
|
||||||
|
export function oldBuildLines(old: OldBuild[]): string[] {
|
||||||
|
if (!old.length) return [];
|
||||||
|
return [
|
||||||
|
` old builds still active (${old.length}): Play reviews them with every submission; a policy issue in one (e.g. ${SENSITIVE_PERMISSIONS.slice(0, 2).join(' / ')}) blocks Send changes for review. The API cannot read their permissions:`,
|
||||||
|
...old.map(o => ` ${o.track} [${o.versionCodes.join(',')}] ${o.name ?? ''} ${o.status} -> replace: storebound play release --version-code ${o.productionCode} ${trackFlag(o.track)} completed`),
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
@ -82,12 +82,20 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
}
|
}
|
||||||
let code = fixed ?? '';
|
let code = fixed ?? '';
|
||||||
let uploaded = false;
|
let uploaded = false;
|
||||||
|
// a dry run never uploads: the bundle would go into an edit that is thrown away (14 MB for nothing, and a long
|
||||||
|
// upload can outlive the edit: "This edit has expired"); its tracks are shown, not PUT (Play refuses a track
|
||||||
|
// with a versionCode the edit does not have)
|
||||||
|
let planOnly = false;
|
||||||
if (aab) {
|
if (aab) {
|
||||||
// a versionCode Play already has (an earlier run uploaded it) is reused, never uploaded twice
|
// a versionCode Play already has (an earlier run uploaded it) is reused, never uploaded twice
|
||||||
const info = aabInfo(aab);
|
const info = aabInfo(aab);
|
||||||
if ((await usedVersionCodes(play, id)).includes(info.versionCode)) {
|
if ((await usedVersionCodes(play, id)).includes(info.versionCode)) {
|
||||||
code = String(info.versionCode);
|
code = String(info.versionCode);
|
||||||
log('play', `versionCode ${code} is on Play already: not uploaded again`);
|
log('play', `versionCode ${code} is on Play already: not uploaded again`);
|
||||||
|
} else if (a.has('dry')) {
|
||||||
|
code = String(info.versionCode);
|
||||||
|
planOnly = true;
|
||||||
|
log('play', `dry run: would upload ${aab} (${(statSync(aab).size / 1048576).toFixed(1)} MB, versionCode ${code}); not uploaded`);
|
||||||
} else {
|
} else {
|
||||||
shipPhase('upload', `uploading ${aab}`, 0);
|
shipPhase('upload', `uploading ${aab}`, 0);
|
||||||
log('play', `uploading ${aab} (${(statSync(aab).size / 1048576).toFixed(1)} MB), this can take minutes`);
|
log('play', `uploading ${aab} (${(statSync(aab).size / 1048576).toFixed(1)} MB), this can take minutes`);
|
||||||
|
|
@ -108,6 +116,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (t.status === 'inProgress') release.userFraction = Number(fraction ?? 0.1);
|
if (t.status === 'inProgress') release.userFraction = Number(fraction ?? 0.1);
|
||||||
const cur = (await play.call<{ releases?: PlayTrackRelease[] }>('GET', `${play.API}/edits/${id}/tracks/${t.track}`).catch(() => ({ releases: [] }))).releases ?? [];
|
const cur = (await play.call<{ releases?: PlayTrackRelease[] }>('GET', `${play.API}/edits/${id}/tracks/${t.track}`).catch(() => ({ releases: [] }))).releases ?? [];
|
||||||
if (sameRelease(cur, release)) { log('play', `${t.track}: already ${t.status} ${code}, unchanged`); continue; }
|
if (sameRelease(cur, release)) { log('play', `${t.track}: already ${t.status} ${code}, unchanged`); continue; }
|
||||||
|
if (planOnly) { log('play', `dry run: ${t.track} <- ${code} (${t.status}, notes in ${notes.length} languages)`); changed++; continue; }
|
||||||
await play.call('PUT', `${play.API}/edits/${id}/tracks/${t.track}`, { track: t.track, releases: [release] });
|
await play.call('PUT', `${play.API}/edits/${id}/tracks/${t.track}`, { track: t.track, releases: [release] });
|
||||||
changed++;
|
changed++;
|
||||||
log('play', `${t.track} <- ${code} (${t.status}, notes in ${notes.length} languages)`);
|
log('play', `${t.track} <- ${code} (${t.status}, notes in ${notes.length} languages)`);
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,14 @@ export function isReviewRefused(err: unknown): boolean {
|
||||||
return reasons.every(r => /badRequest|invalid|failedPrecondition|precondition/i.test(r));
|
return reasons.every(r => /badRequest|invalid|failedPrecondition|precondition/i.test(r));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** The opposite 400: with managed publishing off Play refuses changesNotSentForReview=true (live: "Changes are sent for
|
||||||
|
* review automatically"); the commit is redone without it. "cannot be sent ... automatically" is the other refusal. */
|
||||||
|
export function isAutoSendOnly(err: unknown): boolean {
|
||||||
|
const s = String(err instanceof Error ? err.message : err);
|
||||||
|
const m = /-> 400 (.*)$/s.exec(s);
|
||||||
|
return !!m && /are sent for review automatically/i.test(m[1]!);
|
||||||
|
}
|
||||||
|
|
||||||
/** The query string with changesNotSentForReview=true added to `base` ("?a=1" or ''). */
|
/** The query string with changesNotSentForReview=true added to `base` ("?a=1" or ''). */
|
||||||
export function withNotSent(base: string | undefined, on: boolean): string {
|
export function withNotSent(base: string | undefined, on: boolean): string {
|
||||||
const parts = [(base ?? '').replace(/^\?/, ''), on ? 'changesNotSentForReview=true' : ''].filter(Boolean);
|
const parts = [(base ?? '').replace(/^\?/, ''), on ? 'changesNotSentForReview=true' : ''].filter(Boolean);
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,7 @@ import { playReleases, playReleaseLabel } from '../lib/portfolio';
|
||||||
import { playClient } from './client';
|
import { playClient } from './client';
|
||||||
import { listOneTimeProducts } from './products';
|
import { listOneTimeProducts } from './products';
|
||||||
import { readyLines, readyToPublish } from '../lib/play-publish';
|
import { readyLines, readyToPublish } from '../lib/play-publish';
|
||||||
|
import { oldBuildLines, oldTrackBuilds } from './old-builds';
|
||||||
import { clearPending, pendingLine, publishingUrl, readPending } from './review-pending';
|
import { clearPending, pendingLine, publishingUrl, readPending } from './review-pending';
|
||||||
|
|
||||||
interface Track { track: string; releases?: { name?: string; versionCodes?: string[]; status: string; userFraction?: number }[] }
|
interface Track { track: string; releases?: { name?: string; versionCodes?: string[]; status: string; userFraction?: number }[] }
|
||||||
|
|
@ -33,7 +34,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
// the App category is not in the API (edits.details has no category field): a console step
|
// the App category is not in the API (edits.details has no category field): a console step
|
||||||
const cat = playCategoryOf(config);
|
const cat = playCategoryOf(config);
|
||||||
const category = { config: cat?.category ?? null, source: cat?.source ?? null, api: false, plan: 'storebound console plan play-store-settings' };
|
const category = { config: cat?.category ?? null, source: cat?.source ?? null, api: false, plan: 'storebound console plan play-store-settings' };
|
||||||
if (ctx.args.has('json')) { printJson({ details, category, tracks, listings, products, publicPage, managedPublishing: config.play?.managedPublishing ?? null, reviewPending, readyToPublish: readyToPublish({ tracks, publicPage, managedPublishing: config.play?.managedPublishing ?? null }) }); return; }
|
if (ctx.args.has('json')) { printJson({ details, category, tracks, listings, products, publicPage, managedPublishing: config.play?.managedPublishing ?? null, reviewPending, oldBuilds: oldTrackBuilds(tracks), readyToPublish: readyToPublish({ tracks, publicPage, managedPublishing: config.play?.managedPublishing ?? null }) }); return; }
|
||||||
console.log(`${play.packageName}\n details: ${details.defaultLanguage} · ${details.contactEmail ?? '-'} · ${details.contactWebsite ?? '-'}`);
|
console.log(`${play.packageName}\n details: ${details.defaultLanguage} · ${details.contactEmail ?? '-'} · ${details.contactWebsite ?? '-'}`);
|
||||||
console.log(` category: ${cat ? `${cat.category} (${cat.source})` : 'not in the config (play.category)'} · not readable by the API: Store settings is a console step (${category.plan})`);
|
console.log(` category: ${cat ? `${cat.category} (${cat.source})` : 'not in the config (play.category)'} · not readable by the API: Store settings is a console step (${category.plan})`);
|
||||||
console.log(` listings (${listings.length}): ${listings.map(l => l.language).join(', ') || '-'}`);
|
console.log(` listings (${listings.length}): ${listings.map(l => l.language).join(', ') || '-'}`);
|
||||||
|
|
@ -44,6 +45,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
console.log(` public store page: ${publicPage.state === 'public' ? `published (200), live version ${publicPage.versionName ?? (publicPage.varies ? 'varies with device' : 'not shown')}` : publicPage.state === 'notPublic' ? 'not public yet (404)' : `couldn't check it (${publicPage.error ?? 'not read'})`}${publicPage.stale ? ` (last known, ${publicPage.checkedAt.slice(0, 16).replace('T', ' ')} UTC)` : ''}`);
|
console.log(` public store page: ${publicPage.state === 'public' ? `published (200), live version ${publicPage.versionName ?? (publicPage.varies ? 'varies with device' : 'not shown')}` : publicPage.state === 'notPublic' ? 'not public yet (404)' : `couldn't check it (${publicPage.error ?? 'not read'})`}${publicPage.stale ? ` (last known, ${publicPage.checkedAt.slice(0, 16).replace('T', ' ')} UTC)` : ''}`);
|
||||||
for (const r of playReleases({ tracks, publicPage, managedPublishing: config.play?.managedPublishing ?? null }).filter(x => x.track === 'production')) console.log(` production ${r.version ?? '?'} (${r.build ?? '?'}): ${playReleaseLabel(r)}`);
|
for (const r of playReleases({ tracks, publicPage, managedPublishing: config.play?.managedPublishing ?? null }).filter(x => x.track === 'production')) console.log(` production ${r.version ?? '?'} (${r.build ?? '?'}): ${playReleaseLabel(r)}`);
|
||||||
for (const l of readyLines(readyToPublish({ tracks, publicPage, managedPublishing: config.play?.managedPublishing ?? null }))) console.log(l);
|
for (const l of readyLines(readyToPublish({ tracks, publicPage, managedPublishing: config.play?.managedPublishing ?? null }))) console.log(l);
|
||||||
|
for (const l of oldBuildLines(oldTrackBuilds(tracks))) console.log(l);
|
||||||
if (pending) console.log(` review: ${pendingLine(pending)}`);
|
if (pending) console.log(` review: ${pendingLine(pending)}`);
|
||||||
console.log(` products (${products.length}):`);
|
console.log(` products (${products.length}):`);
|
||||||
for (const p of products) console.log(` ${p.productId.padEnd(40)} ${(p.purchaseOptions ?? []).map(o => `${o.purchaseOptionId}:${o.state ?? '?'}`).join(' ')}`);
|
for (const p of products) console.log(` ${p.productId.padEnd(40)} ${(p.purchaseOptions ?? []).map(o => `${o.purchaseOptionId}:${o.state ?? '?'}`).join(' ')}`);
|
||||||
|
|
|
||||||
|
|
@ -28,6 +28,7 @@ import { androidSdk, detectTools } from './lib/tools';
|
||||||
import { compiled, pickCallEnv, runCommand, type RunOptions, type Running } from './lib/runner';
|
import { compiled, pickCallEnv, runCommand, type RunOptions, type Running } from './lib/runner';
|
||||||
import { inputSchema, notSentProp, type ToolDef, TOOLS, toArgv, validateInput } from './mcp-tools';
|
import { inputSchema, notSentProp, type ToolDef, TOOLS, toArgv, validateInput } from './mcp-tools';
|
||||||
import * as rt from './lib/rt';
|
import * as rt from './lib/rt';
|
||||||
|
import { ensureCliShim } from './lib/cli-shim';
|
||||||
|
|
||||||
type Id = string | number;
|
type Id = string | number;
|
||||||
interface Msg { jsonrpc?: string; id?: Id | null; method?: string; params?: unknown }
|
interface Msg { jsonrpc?: string; id?: Id | null; method?: string; params?: unknown }
|
||||||
|
|
@ -613,6 +614,8 @@ export async function serveStdio(): Promise<void> {
|
||||||
const send: Send = o => { process.stdout.write(JSON.stringify(o) + '\n'); };
|
const send: Send = o => { process.stdout.write(JSON.stringify(o) + '\n'); };
|
||||||
const session = new Session(send);
|
const session = new Session(send);
|
||||||
console.error(`[storebound serve] ${pkg.version} on stdio (${DESKTOP_PROTOCOL}), waiting for session.hello`);
|
console.error(`[storebound serve] ${pkg.version} on stdio (${DESKTOP_PROTOCOL}), waiting for session.hello`);
|
||||||
|
// the app's own CLI on the terminal PATH (lib/cli-shim.ts); only the bundled sidecar, after the handshake had its turn
|
||||||
|
if (compiled()) setTimeout(() => { for (const l of ensureCliShim()) console.error(`[storebound serve] ${l}`); }, 2000);
|
||||||
let buf = '';
|
let buf = '';
|
||||||
const decoder = new TextDecoder();
|
const decoder = new TextDecoder();
|
||||||
const reader = rt.stdinStream().getReader();
|
const reader = rt.stdinStream().getReader();
|
||||||
|
|
|
||||||
|
|
@ -30,24 +30,30 @@ import * as rt from '../lib/rt';
|
||||||
class PlaywrightShapeError extends Error {}
|
class PlaywrightShapeError extends Error {}
|
||||||
|
|
||||||
async function chromium(root: string): Promise<any> {
|
async function chromium(root: string): Promise<any> {
|
||||||
|
// why each place failed, for the error: a swallowed import error read as "not found" (a Mac run had it installed)
|
||||||
|
const tried: string[] = [];
|
||||||
for (const base of [root, rt.packageRoot()]) {
|
for (const base of [root, rt.packageRoot()]) {
|
||||||
|
let p = '';
|
||||||
try {
|
try {
|
||||||
const p = rt.resolveFrom('playwright', base);
|
p = rt.resolveFrom('playwright', base);
|
||||||
// only an installed copy (node_modules): outside a project Bun auto-installs the newest playwright into its global
|
// only an installed copy (node_modules): outside a project Bun auto-installs the newest playwright into its global
|
||||||
// cache (~/.bun/install/cache), whose browser build was never downloaded ("headless shell: not installed" on
|
// cache (~/.bun/install/cache), whose browser build was never downloaded ("headless shell: not installed" on
|
||||||
// Linux CI, where no Google Chrome hides it); storebound's own copy is next
|
// Linux CI, where no Google Chrome hides it); storebound's own copy is next
|
||||||
if (!isInstalledPackage(p)) continue;
|
if (!isInstalledPackage(p)) { tried.push(`${p}: not an installed copy (Bun's global cache)`); continue; }
|
||||||
// playwright's entry is CommonJS: depending on the runtime and version the ESM import puts chromium on the
|
// playwright's entry is CommonJS: depending on the runtime and version the ESM import puts chromium on the
|
||||||
// namespace or only under default (a project's playwright 1.57 under a global Bun install gave undefined)
|
// namespace or only under default (a project's playwright 1.57 under a global Bun install gave undefined)
|
||||||
const m = await rt.importPath(p);
|
const m = await rt.importPath(p);
|
||||||
const c = m?.chromium ?? m?.default?.chromium;
|
const c = m?.chromium ?? m?.default?.chromium;
|
||||||
if (!c || typeof c.launch !== 'function') throw new PlaywrightShapeError(`playwright at ${p} has no chromium.launch (exports: ${Object.keys(m ?? {}).slice(0, 8).join(', ') || 'none'}${m?.default ? `; default: ${Object.keys(m.default).slice(0, 8).join(', ')}` : ''})`);
|
if (!c || typeof c.launch !== 'function') throw new PlaywrightShapeError(`playwright at ${p} has no chromium.launch (exports: ${Object.keys(m ?? {}).slice(0, 8).join(', ') || 'none'}${m?.default ? `; default: ${Object.keys(m.default).slice(0, 8).join(', ')}` : ''})`);
|
||||||
return c;
|
return c;
|
||||||
} catch (e) { if (e instanceof PlaywrightShapeError) throw e; /* next */ }
|
} catch (e) {
|
||||||
|
if (e instanceof PlaywrightShapeError) throw e;
|
||||||
|
tried.push(p ? `${p}: ${(e as Error).message.split('\n')[0]}` : `not resolvable from ${base}`);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// only reached in the compiled sidecar: the bundled playwright-core (not a runtime dependency of the npm package)
|
// only reached in the compiled sidecar: the bundled playwright-core (not a runtime dependency of the npm package)
|
||||||
if (compiled()) return (await import('playwright-core')).chromium;
|
if (compiled()) return (await import('playwright-core')).chromium;
|
||||||
throw new Error('playwright not found: in your project run `bun add -d playwright` (and `bunx playwright install chromium` if Google Chrome is not installed)');
|
throw new Error(`playwright not found: in your project run \`bun add -d playwright\` (and \`bunx playwright install chromium\` if Google Chrome is not installed)\n ${tried.join('\n ')}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** A resolved module path inside a node_modules folder (not one of Bun's auto-installs from its global cache). */
|
/** A resolved module path inside a node_modules folder (not one of Bun's auto-installs from its global cache). */
|
||||||
|
|
|
||||||
|
|
@ -23,11 +23,15 @@ import { join } from 'node:path';
|
||||||
import type { ShotSpec, ShotsCapture } from '../lib/config';
|
import type { ShotSpec, ShotsCapture } from '../lib/config';
|
||||||
import { log, warn } from '../lib/log';
|
import { log, warn } from '../lib/log';
|
||||||
import { type AuthPlan, expiredHint, landedOnLogin, maskSecrets, safeUrl } from './auth';
|
import { type AuthPlan, expiredHint, landedOnLogin, maskSecrets, safeUrl } from './auth';
|
||||||
import { shotsFor } from './devices';
|
import { type CaptureDevice, shotsFor } from './devices';
|
||||||
import { applySelectors, candidates, probe } from './selectors';
|
import { applySelectors, candidates, probe } from './selectors';
|
||||||
import type { FrameDims } from './lib';
|
import { DEFAULT_LANDSCAPE, type FrameDims } from './lib';
|
||||||
|
|
||||||
type Device = 'phone' | 'tablet';
|
/** Viewport per device class; landscape defaults to shots.landscape.size's default when a caller passes only phone / tablet. */
|
||||||
|
export type CaptureDims = Record<'phone' | 'tablet', FrameDims> & { landscape?: FrameDims };
|
||||||
|
const dimsOf = (dims: CaptureDims, device: Device): FrameDims => dims[device] ?? DEFAULT_LANDSCAPE;
|
||||||
|
|
||||||
|
type Device = CaptureDevice;
|
||||||
export const STEPS = ['goto', 'waitFor', 'eval', 'delay', 'screenshot'] as const;
|
export const STEPS = ['goto', 'waitFor', 'eval', 'delay', 'screenshot'] as const;
|
||||||
export type Step = typeof STEPS[number];
|
export type Step = typeof STEPS[number];
|
||||||
export type Timing = Record<Step | 'total', number>;
|
export type Timing = Record<Step | 'total', number>;
|
||||||
|
|
@ -100,14 +104,14 @@ export async function hashServed(baseUrl: string): Promise<string> {
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Every web frame to capture, in a fixed order (lang, device, shot), with its URL and its input hash. */
|
/** Every web frame to capture, in a fixed order (lang, device, shot), with its URL and its input hash. */
|
||||||
export function planWeb(cap: ShotsCapture, o: { langs: string[]; devices: Device[]; only: string[]; dims: Record<Device, FrameDims>; framesDir: string;
|
export function planWeb(cap: ShotsCapture, o: { langs: string[]; devices: Device[]; only: string[]; dims: CaptureDims; framesDir: string;
|
||||||
build: string; copyText?: (lang: string) => string; fonts?: string }): WebJob[] {
|
build: string; copyText?: (lang: string) => string; fonts?: string; allLandscape?: boolean }): WebJob[] {
|
||||||
const jobs: WebJob[] = [];
|
const jobs: WebJob[] = [];
|
||||||
for (const lang of o.langs) for (const device of o.devices) for (const [name, spec] of shotsFor(cap, device, o.only)) {
|
for (const lang of o.langs) for (const device of o.devices) for (const [name, spec] of shotsFor(cap, device, o.only, o.allLandscape)) {
|
||||||
const q = (cap.query ?? '').replaceAll('{lang}', lang);
|
const q = (cap.query ?? '').replaceAll('{lang}', lang);
|
||||||
const path = (spec.path ?? '/').replaceAll('{lang}', lang) + (q ? ((spec.path ?? '/').includes('?') ? '&' : '?') + q : '');
|
const path = (spec.path ?? '/').replaceAll('{lang}', lang) + (q ? ((spec.path ?? '/').includes('?') ? '&' : '?') + q : '');
|
||||||
const url = (cap.baseUrl ?? '').replace(/\/$/, '') + path;
|
const url = (cap.baseUrl ?? '').replace(/\/$/, '') + path;
|
||||||
const hash = sha(JSON.stringify({ spec, url, dims: o.dims[device], session: cap.session ?? 'per-shot', build: o.build, copy: o.copyText?.(lang) ?? '', fonts: o.fonts ?? '' }));
|
const hash = sha(JSON.stringify({ spec, url, dims: dimsOf(o.dims, device), session: cap.session ?? 'per-shot', build: o.build, copy: o.copyText?.(lang) ?? '', fonts: o.fonts ?? '' }));
|
||||||
const frame = `${lang}/${device}/${name}.png`;
|
const frame = `${lang}/${device}/${name}.png`;
|
||||||
jobs.push({ lang, device, name, spec, url, path, out: join(o.framesDir, frame), frame, hash });
|
jobs.push({ lang, device, name, spec, url, path, out: join(o.framesDir, frame), frame, hash });
|
||||||
}
|
}
|
||||||
|
|
@ -137,7 +141,7 @@ export interface CaptureReport {
|
||||||
|
|
||||||
/* eslint-disable @typescript-eslint/no-explicit-any */
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
||||||
/** Captures the jobs in a browser: per-shot contexts, or one page per language + device in per-language sessions. */
|
/** Captures the jobs in a browser: per-shot contexts, or one page per language + device in per-language sessions. */
|
||||||
export async function captureWeb(browser: any, cap: ShotsCapture, jobs: WebJob[], o: { concurrency: number; dims: Record<Device, FrameDims>; auth?: AuthPlan }): Promise<CaptureReport> {
|
export async function captureWeb(browser: any, cap: ShotsCapture, jobs: WebJob[], o: { concurrency: number; dims: CaptureDims; auth?: AuthPlan }): Promise<CaptureReport> {
|
||||||
const auth = o.auth;
|
const auth = o.auth;
|
||||||
const mask = (t: string): string => (auth ? maskSecrets(t, auth.secrets) : t);
|
const mask = (t: string): string => (auth ? maskSecrets(t, auth.secrets) : t);
|
||||||
const expired = new Set<string>();
|
const expired = new Set<string>();
|
||||||
|
|
@ -147,8 +151,8 @@ export async function captureWeb(browser: any, cap: ShotsCapture, jobs: WebJob[]
|
||||||
let finished = 0;
|
let finished = 0;
|
||||||
const total = jobs.length;
|
const total = jobs.length;
|
||||||
const newPage = async (j: WebJob): Promise<{ c: any; page: any; errs: string[] }> => {
|
const newPage = async (j: WebJob): Promise<{ c: any; page: any; errs: string[] }> => {
|
||||||
const d = o.dims[j.device];
|
const d = dimsOf(o.dims, j.device);
|
||||||
const c = await browser.newContext({ viewport: { width: d.w, height: d.h }, deviceScaleFactor: d.dpr, hasTouch: true, isMobile: true, serviceWorkers: 'block', locale: j.lang, ...(auth?.contextOptions ?? {}) });
|
const c = await browser.newContext({ viewport: { width: d.w, height: d.h }, deviceScaleFactor: d.dpr, hasTouch: j.device !== 'landscape', isMobile: j.device !== 'landscape', serviceWorkers: 'block', locale: j.lang, ...(auth?.contextOptions ?? {}) }); // landscape = a desktop window: no touch, no mobile emulation
|
||||||
// sign in once per context, cookies kept in it (request auth); a failed sign-in stops the whole capture
|
// sign in once per context, cookies kept in it (request auth); a failed sign-in stops the whole capture
|
||||||
if (auth) try { await auth.prepare(c); } catch (e) { await c.close(); throw Object.assign(new Error(mask((e as Error).message)), { authFailed: true }); }
|
if (auth) try { await auth.prepare(c); } catch (e) { await c.close(); throw Object.assign(new Error(mask((e as Error).message)), { authFailed: true }); }
|
||||||
const page = await c.newPage();
|
const page = await c.newPage();
|
||||||
|
|
@ -167,7 +171,7 @@ export async function captureWeb(browser: any, cap: ShotsCapture, jobs: WebJob[]
|
||||||
if (!expired.has(safeUrl(s.page.url()))) { expired.add(safeUrl(s.page.url())); warn('shots', `${j.lang}/${j.device}/${j.name}: ${mask(expiredHint(s.page.url()))}`); }
|
if (!expired.has(safeUrl(s.page.url()))) { expired.add(safeUrl(s.page.url())); warn('shots', `${j.lang}/${j.device}/${j.name}: ${mask(expiredHint(s.page.url()))}`); }
|
||||||
throw new Error(`landed on the sign-in page ${safeUrl(s.page.url())}`);
|
throw new Error(`landed on the sign-in page ${safeUrl(s.page.url())}`);
|
||||||
}
|
}
|
||||||
await applySelectors(s.page, j.spec, { device: j.device, w: o.dims[j.device].w, h: o.dims[j.device].h }, waitTimeout); // waitSelector, click: a miss names the selector and the size
|
await applySelectors(s.page, j.spec, { device: j.device, w: dimsOf(o.dims, j.device).w, h: dimsOf(o.dims, j.device).h }, waitTimeout); // waitSelector, click: a miss names the selector and the size
|
||||||
if (j.spec.waitFor) await s.page.waitForFunction(j.spec.waitFor, null, { timeout: waitTimeout, polling: 50 });
|
if (j.spec.waitFor) await s.page.waitForFunction(j.spec.waitFor, null, { timeout: waitTimeout, polling: 50 });
|
||||||
t.waitFor = Date.now() - t0; t0 = Date.now();
|
t.waitFor = Date.now() - t0; t0 = Date.now();
|
||||||
for (const js of j.spec.eval ?? []) await s.page.evaluate(js);
|
for (const js of j.spec.eval ?? []) await s.page.evaluate(js);
|
||||||
|
|
@ -251,14 +255,14 @@ export function writeCaptureState(root: string, report: CaptureReport, cache: Ca
|
||||||
/* eslint-disable @typescript-eslint/no-explicit-any */
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
||||||
/** `shots capture --dry --probe`: opens each page (no screenshot), runs the shot's waitFor, and reports per size which
|
/** `shots capture --dry --probe`: opens each page (no screenshot), runs the shot's waitFor, and reports per size which
|
||||||
* selector candidates match. Returns the log lines; `missed` counts shots where no candidate of a list matched. */
|
* selector candidates match. Returns the log lines; `missed` counts shots where no candidate of a list matched. */
|
||||||
export async function probeSelectors(browser: any, jobs: WebJob[], o: { dims: Record<Device, FrameDims>; auth?: AuthPlan; timeoutMs?: number }): Promise<{ lines: string[]; missed: number }> {
|
export async function probeSelectors(browser: any, jobs: WebJob[], o: { dims: CaptureDims; auth?: AuthPlan; timeoutMs?: number }): Promise<{ lines: string[]; missed: number }> {
|
||||||
const lines: string[] = []; let missed = 0;
|
const lines: string[] = []; let missed = 0;
|
||||||
for (const j of jobs) {
|
for (const j of jobs) {
|
||||||
const lists = [['waitSelector', candidates(j.spec.waitSelector, j.device)], ...(Array.isArray(j.spec.click) && j.spec.click.some(c => typeof c !== 'string') ? j.spec.click : j.spec.click === undefined ? [] : [j.spec.click])
|
const lists = [['waitSelector', candidates(j.spec.waitSelector, j.device)], ...(Array.isArray(j.spec.click) && j.spec.click.some(c => typeof c !== 'string') ? j.spec.click : j.spec.click === undefined ? [] : [j.spec.click])
|
||||||
.map((c, i) => [`click[${i}]`, candidates(c as any, j.device)] as const)].filter(([, l]) => l.length) as [string, string[]][];
|
.map((c, i) => [`click[${i}]`, candidates(c as any, j.device)] as const)].filter(([, l]) => l.length) as [string, string[]][];
|
||||||
if (!lists.length) continue;
|
if (!lists.length) continue;
|
||||||
const d = o.dims[j.device];
|
const d = dimsOf(o.dims, j.device);
|
||||||
const c = await browser.newContext({ viewport: { width: d.w, height: d.h }, deviceScaleFactor: 1, hasTouch: true, isMobile: true, serviceWorkers: 'block', locale: j.lang, ...(o.auth?.contextOptions ?? {}) });
|
const c = await browser.newContext({ viewport: { width: d.w, height: d.h }, deviceScaleFactor: 1, hasTouch: j.device !== 'landscape', isMobile: j.device !== 'landscape', serviceWorkers: 'block', locale: j.lang, ...(o.auth?.contextOptions ?? {}) });
|
||||||
try {
|
try {
|
||||||
if (o.auth) await o.auth.prepare(c);
|
if (o.auth) await o.auth.prepare(c);
|
||||||
const page = await c.newPage();
|
const page = await c.newPage();
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,15 @@
|
||||||
// Raw frames from a running build of your app or game, from any engine.
|
// Raw frames from a running build of your app or game, from any engine.
|
||||||
// storebound shots capture [--lang en,tr] [--only hero,shop] [--device phone|tablet] [--source web|ios-sim|android-emu|folder]
|
// storebound shots capture [--lang en,tr] [--only hero,shop] [--device phone|tablet|landscape] [--source web|ios-sim|android-emu|folder]
|
||||||
// [--dry [--probe]] [--keep-booted] [--concurrency N] [--only-missing | --force]
|
// [--dry [--probe]] [--keep-booted] [--concurrency N] [--only-missing | --force]
|
||||||
// Frames go to <shots.frames>/<lang>/<device>/<name>.png: the screen BELOW the status bar (the template draws one).
|
// Frames go to <shots.frames>/<lang>/<device>/<name>.png: the screen BELOW the status bar (the template draws one).
|
||||||
|
// Devices: phone, tablet and landscape (<lang>/landscape/<name>.png, web source only: Mac App Store and Chromebook
|
||||||
|
// screenshots; a desktop window, no status bar crop). The default device list adds landscape when the project renders a
|
||||||
|
// landscape size (apple.mac, play.chromebook, shots.landscape.playTablets); then shots with no device (and 'both') are
|
||||||
|
// captured for landscape too, since render needs a landscape frame per scene. A shot says device: 'landscape' to be
|
||||||
|
// landscape only, 'phone' / 'tablet' to stay out of it. ios-sim / android-emu skip landscape with a warning.
|
||||||
// shots.capture.source (default web):
|
// shots.capture.source (default web):
|
||||||
// web headless Chromium (playwright), mobile viewport + touch at phone / tablet size. Each shot:
|
// web headless Chromium (playwright), mobile viewport + touch at phone / tablet size, or a desktop viewport (no touch)
|
||||||
|
// at shots.landscape.size (default 1440 x 900 @2x) for landscape. Each shot:
|
||||||
// { path, waitFor?: JS expression that turns true, eval?: [JS], delayMs?, device? }; URL = baseUrl + path +
|
// { path, waitFor?: JS expression that turns true, eval?: [JS], delayMs?, device? }; URL = baseUrl + path +
|
||||||
// query, "{lang}" replaced. Parallel contexts, per-language page reuse, the input-hash cache and the
|
// query, "{lang}" replaced. Parallel contexts, per-language page reuse, the input-hash cache and the
|
||||||
// per-frame timing (goto / waitFor / eval / delay / screenshot): capture-web.ts. Signed-in apps:
|
// per-frame timing (goto / waitFor / eval / delay / screenshot): capture-web.ts. Signed-in apps:
|
||||||
|
|
@ -36,15 +42,16 @@ import { done, log, step, warn } from '../lib/log';
|
||||||
import { closeBrowser, launch } from './browser';
|
import { closeBrowser, launch } from './browser';
|
||||||
import { checkFrameFolder } from './check';
|
import { checkFrameFolder } from './check';
|
||||||
import { adbAppLocaleArgs, adbDemoExitArgs, adbDemoModeArgs, adbForceStopArgs, adbInstallArgs, adbScreencapArgs, adbStartArgs, adbStateArgs, adbTarget,
|
import { adbAppLocaleArgs, adbDemoExitArgs, adbDemoModeArgs, adbForceStopArgs, adbInstallArgs, adbScreencapArgs, adbStartArgs, adbStateArgs, adbTarget,
|
||||||
cropArgs, cropTopFor, fill, pickSimulator, shotsFor, simBootArgs, simBootStatusArgs, simInstallArgs, simLaunchArgs, simOpenUrlArgs,
|
cropArgs, cropTopFor, fill, CAPTURE_DEVICES, type CaptureDevice, pickSimulator, shotsFor, simBootArgs, simBootStatusArgs, simInstallArgs, simLaunchArgs, simOpenUrlArgs,
|
||||||
simScreenshotArgs, simShutdownArgs, simStatusBarArgs, simStatusBarClearArgs, simTarget, SOURCES, type Source, TOOL_HINTS, validateCapture } from './devices';
|
simScreenshotArgs, simShutdownArgs, simStatusBarArgs, simStatusBarClearArgs, simTarget, SOURCES, type Source, TOOL_HINTS, validateCapture } from './devices';
|
||||||
import { type CopyFile, copyText, type FrameDims, frameDims } from './lib';
|
import { type CopyFile, copyText, type FrameDims, frameDims, landscapeDims, rendersLandscape } from './lib';
|
||||||
import { captureWeb, defaultConcurrency, probeSelectors, hashPaths, hashServed, planWeb, readCache, selectJobs, summaryLines, writeCaptureState } from './capture-web';
|
import { captureWeb, defaultConcurrency, probeSelectors, hashPaths, hashServed, planWeb, readCache, selectJobs, summaryLines, writeCaptureState } from './capture-web';
|
||||||
import { imageInfo } from './spec';
|
import { imageInfo } from './spec';
|
||||||
import { authPlan, safeUrl } from './auth';
|
import { authPlan, safeUrl } from './auth';
|
||||||
import * as rt from '../lib/rt';
|
import * as rt from '../lib/rt';
|
||||||
|
|
||||||
type Device = 'phone' | 'tablet';
|
type Device = CaptureDevice;
|
||||||
|
type PhoneTablet = 'phone' | 'tablet';
|
||||||
|
|
||||||
export function sh(cmd: string, args: string[], o: { allowFail?: boolean; timeout?: number } = {}): { out: Buffer; err: string; code: number } {
|
export function sh(cmd: string, args: string[], o: { allowFail?: boolean; timeout?: number } = {}): { out: Buffer; err: string; code: number } {
|
||||||
const r = spawnSync(cmd, args, { timeout: o.timeout ?? 120_000, maxBuffer: 256 * 1024 * 1024 });
|
const r = spawnSync(cmd, args, { timeout: o.timeout ?? 120_000, maxBuffer: 256 * 1024 * 1024 });
|
||||||
|
|
@ -75,7 +82,7 @@ export function localeOf(config: ShipConfig, lang: string, source: Source): stri
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Crop the status bar off a full-screen capture and store it as a 24-bit RGB frame. */
|
/** Crop the status bar off a full-screen capture and store it as a 24-bit RGB frame. */
|
||||||
function storeFrame(tmp: string, out: string, cropTop: ShotsCapture['cropTop'], device: Device, dims: FrameDims): void {
|
function storeFrame(tmp: string, out: string, cropTop: ShotsCapture['cropTop'], device: PhoneTablet, dims: FrameDims): void {
|
||||||
const { w, h } = imageInfo(readFileSync(tmp));
|
const { w, h } = imageInfo(readFileSync(tmp));
|
||||||
if (!h) throw new Error('screenshot is not a PNG');
|
if (!h) throw new Error('screenshot is not a PNG');
|
||||||
const top = cropTopFor(cropTop, device, h, dims);
|
const top = cropTopFor(cropTop, device, h, dims);
|
||||||
|
|
@ -98,13 +105,20 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (problems.length) throw new Error(`shots.capture:\n ${problems.join('\n ')}`);
|
if (problems.length) throw new Error(`shots.capture:\n ${problems.join('\n ')}`);
|
||||||
const langs = a.list('lang').length ? a.list('lang') : config.languages.map(l => l.id);
|
const langs = a.list('lang').length ? a.list('lang') : config.languages.map(l => l.id);
|
||||||
const only = a.list('only');
|
const only = a.list('only');
|
||||||
const devices: Device[] = a.get('device') ? [a.get('device') as Device] : ['phone', 'tablet'];
|
if (a.get('device') && !CAPTURE_DEVICES.includes(a.get('device') as Device)) throw new Error(`--device: ${CAPTURE_DEVICES.join(' | ')}`);
|
||||||
if (devices.some(d => d !== 'phone' && d !== 'tablet')) throw new Error('--device: phone | tablet');
|
const landscapeOn = rendersLandscape(config);
|
||||||
|
let devices: Device[] = a.get('device') ? [a.get('device') as Device] : ['phone', 'tablet', ...(landscapeOn ? ['landscape' as const] : [])];
|
||||||
|
const allLandscape = landscapeOn || a.get('device') === 'landscape'; // shots with no device / 'both' also make a landscape frame
|
||||||
|
if (source !== 'web' && source !== 'folder' && devices.includes('landscape')) {
|
||||||
|
warn('shots', `landscape frames (Mac, Chromebook) are not supported from ${source}: skipped; capture them from a web build (--source web) or put them in <shots.frames>/<lang>/landscape/ (--source folder)`);
|
||||||
|
devices = devices.filter(d => d !== 'landscape');
|
||||||
|
}
|
||||||
|
const mobile = devices.filter((d): d is PhoneTablet => d !== 'landscape');
|
||||||
const framesDir = resolve(shots.frames);
|
const framesDir = resolve(shots.frames);
|
||||||
const dims = frameDims(config);
|
const dims = { ...frameDims(config), landscape: landscapeDims(config) };
|
||||||
const tmpDir = join(root, '.storebound', 'tmp');
|
const tmpDir = join(root, '.storebound', 'tmp');
|
||||||
const target = (lang: string, device: Device, name: string) => { const d = join(framesDir, lang, device); if (!dry) mkdirSync(d, { recursive: true }); return join(d, `${name}.png`); };
|
const target = (lang: string, device: Device, name: string) => { const d = join(framesDir, lang, device); if (!dry) mkdirSync(d, { recursive: true }); return join(d, `${name}.png`); };
|
||||||
const total = langs.length * devices.reduce((t, d) => t + shotsFor(cap, d, only).length, 0);
|
const total = langs.length * devices.reduce((t, d) => t + shotsFor(cap, d, only, allLandscape).length, 0);
|
||||||
let failed = 0, n = 0, i = 0;
|
let failed = 0, n = 0, i = 0;
|
||||||
const progress = (what: string) => log('shots', step(++i, total, what));
|
const progress = (what: string) => log('shots', step(++i, total, what));
|
||||||
/** Runs a simctl / adb step, or prints it with --dry. */
|
/** Runs a simctl / adb step, or prints it with --dry. */
|
||||||
|
|
@ -125,7 +139,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
|
|
||||||
if (source === 'web') {
|
if (source === 'web') {
|
||||||
if (dry) {
|
if (dry) {
|
||||||
for (const lang of langs) for (const device of devices) for (const [name, s] of shotsFor(cap, device, only)) {
|
for (const lang of langs) for (const device of devices) for (const [name, s] of shotsFor(cap, device, only, allLandscape)) {
|
||||||
progress(`${lang}/${device}/${name}.png <- ${cap.baseUrl}${(s.path ?? '/').replaceAll('{lang}', lang)}`);
|
progress(`${lang}/${device}/${name}.png <- ${cap.baseUrl}${(s.path ?? '/').replaceAll('{lang}', lang)}`);
|
||||||
const sel: [string, string[]][] = [['waitSelector', candidates(s.waitSelector, device)], ...(Array.isArray(s.click) && s.click.some(c => typeof c !== 'string') ? s.click : s.click === undefined ? [] : [s.click]).map((c, k) => [`click[${k}]`, candidates(c as ShotSelector, device)] as [string, string[]])];
|
const sel: [string, string[]][] = [['waitSelector', candidates(s.waitSelector, device)], ...(Array.isArray(s.click) && s.click.some(c => typeof c !== 'string') ? s.click : s.click === undefined ? [] : [s.click]).map((c, k) => [`click[${k}]`, candidates(c as ShotSelector, device)] as [string, string[]])];
|
||||||
for (const [what, list] of sel) if (list.length) log('shots', ` ${what} on ${device} ${dims[device].w}x${dims[device].h}: ${list.join(' | ')}`);
|
for (const [what, list] of sel) if (list.length) log('shots', ` ${what} on ${device} ${dims[device].w}x${dims[device].h}: ${list.join(' | ')}`);
|
||||||
|
|
@ -133,7 +147,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
if (a.has('probe')) { // open the pages and test every candidate on each size (needs the app running at baseUrl)
|
if (a.has('probe')) { // open the pages and test every candidate on each size (needs the app running at baseUrl)
|
||||||
need(cap.baseUrl, 'shots.capture.baseUrl');
|
need(cap.baseUrl, 'shots.capture.baseUrl');
|
||||||
const auth = cap.auth ? authPlan(cap.auth, { root, baseUrl: cap.baseUrl! }) : undefined;
|
const auth = cap.auth ? authPlan(cap.auth, { root, baseUrl: cap.baseUrl! }) : undefined;
|
||||||
const jobs = planWeb(cap, { langs, devices, only, dims, framesDir, build: '', fonts: '' });
|
const jobs = planWeb(cap, { langs, devices, only, dims, framesDir, build: '', fonts: '', allLandscape });
|
||||||
const browser = await launch(root, { headless: true, args: ['--mute-audio'] });
|
const browser = await launch(root, { headless: true, args: ['--mute-audio'] });
|
||||||
let r;
|
let r;
|
||||||
try { r = await probeSelectors(browser, jobs, { dims, ...(auth ? { auth } : {}) }); } finally { await closeBrowser(browser); }
|
try { r = await probeSelectors(browser, jobs, { dims, ...(auth ? { auth } : {}) }); } finally { await closeBrowser(browser); }
|
||||||
|
|
@ -152,7 +166,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
let copy: CopyFile = {};
|
let copy: CopyFile = {};
|
||||||
try { copy = JSON.parse(readFileSync(resolve(shots.copy), 'utf8')) as CopyFile; } catch { /* no copy yet */ }
|
try { copy = JSON.parse(readFileSync(resolve(shots.copy), 'utf8')) as CopyFile; } catch { /* no copy yet */ }
|
||||||
const fontsCss = join(root, '.storebound', 'fonts', 'fonts.css');
|
const fontsCss = join(root, '.storebound', 'fonts', 'fonts.css');
|
||||||
const jobs = planWeb(cap, { langs, devices, only, dims, framesDir, build, copyText: l => copyText(l, copy[l]),
|
const jobs = planWeb(cap, { langs, devices, only, dims, framesDir, build, allLandscape, copyText: l => copyText(l, copy[l]),
|
||||||
fonts: existsSync(fontsCss) ? readFileSync(fontsCss, 'utf8') : '' });
|
fonts: existsSync(fontsCss) ? readFileSync(fontsCss, 'utf8') : '' });
|
||||||
const cache = readCache(root);
|
const cache = readCache(root);
|
||||||
const { run: todo, skipped } = selectJobs(jobs, cache, a.has('force') ? 'force' : a.has('only-missing') ? 'only-missing' : 'changed');
|
const { run: todo, skipped } = selectJobs(jobs, cache, a.has('force') ? 'force' : a.has('only-missing') ? 'only-missing' : 'changed');
|
||||||
|
|
@ -174,7 +188,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const ios = need(cap.ios, 'shots.capture.ios');
|
const ios = need(cap.ios, 'shots.capture.ios');
|
||||||
if (!dry) { requireTool('xcrun'); requireTool('ffmpeg'); }
|
if (!dry) { requireTool('xcrun'); requireTool('ffmpeg'); }
|
||||||
const list = dry && !rt.which('xcrun') ? '{"devices":{}}' : sh('xcrun', ['simctl', 'list', 'devices', '-j']).out.toString();
|
const list = dry && !rt.which('xcrun') ? '{"devices":{}}' : sh('xcrun', ['simctl', 'list', 'devices', '-j']).out.toString();
|
||||||
for (const device of devices) {
|
for (const device of mobile) {
|
||||||
const want = simTarget(ios, device);
|
const want = simTarget(ios, device);
|
||||||
const todo = shotsFor(cap, device, only);
|
const todo = shotsFor(cap, device, only);
|
||||||
if (!todo.length) continue;
|
if (!todo.length) continue;
|
||||||
|
|
@ -222,7 +236,7 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const and = need(cap.android, 'shots.capture.android');
|
const and = need(cap.android, 'shots.capture.android');
|
||||||
const adb = adbPath();
|
const adb = adbPath();
|
||||||
if (!dry) { requireTool(adb, 'adb'); requireTool('ffmpeg'); }
|
if (!dry) { requireTool(adb, 'adb'); requireTool('ffmpeg'); }
|
||||||
for (const device of devices) {
|
for (const device of mobile) {
|
||||||
const todo = shotsFor(cap, device, only);
|
const todo = shotsFor(cap, device, only);
|
||||||
if (!todo.length) continue;
|
if (!todo.length) continue;
|
||||||
const serial = adbTarget(and, device);
|
const serial = adbTarget(and, device);
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,7 @@ export function validateCapture(c: ShotsCapture | undefined): string[] {
|
||||||
if (s.click !== undefined) for (const [i, c] of (Array.isArray(s.click) && s.click.some(x => typeof x !== 'string') ? s.click : [s.click]).entries()) e.push(...validateSelector(`shots.capture.shots.${name}.click[${i}]`, c));
|
if (s.click !== undefined) for (const [i, c] of (Array.isArray(s.click) && s.click.some(x => typeof x !== 'string') ? s.click : [s.click]).entries()) e.push(...validateSelector(`shots.capture.shots.${name}.click[${i}]`, c));
|
||||||
} else if (s.waitSelector !== undefined || s.click !== undefined) e.push(`shots.capture.shots.${name}: waitSelector / click only apply to source web`);
|
} else if (s.waitSelector !== undefined || s.click !== undefined) e.push(`shots.capture.shots.${name}: waitSelector / click only apply to source web`);
|
||||||
if (s.navigate && !['spa', 'reload'].includes(s.navigate)) e.push(`shots.capture.shots.${name}.navigate: spa | reload`);
|
if (s.navigate && !['spa', 'reload'].includes(s.navigate)) e.push(`shots.capture.shots.${name}.navigate: spa | reload`);
|
||||||
if (s.device && !['phone', 'tablet', 'both'].includes(s.device)) e.push(`shots.capture.shots.${name}.device: phone | tablet | both`);
|
if (s.device && !['phone', 'tablet', 'both', 'landscape'].includes(s.device)) e.push(`shots.capture.shots.${name}.device: phone | tablet | both | landscape`);
|
||||||
if (src === 'web' && s.path === undefined) e.push(`shots.capture.shots.${name}.path: URL path (source web)`);
|
if (src === 'web' && s.path === undefined) e.push(`shots.capture.shots.${name}.path: URL path (source web)`);
|
||||||
if ((src === 'web' || src === 'folder') && (s.args || s.extras)) e.push(`shots.capture.shots.${name}: args / extras only apply to ios-sim / android-emu`);
|
if ((src === 'web' || src === 'folder') && (s.args || s.extras)) e.push(`shots.capture.shots.${name}: args / extras only apply to ios-sim / android-emu`);
|
||||||
for (const [k, v] of Object.entries(s.extras ?? {})) {
|
for (const [k, v] of Object.entries(s.extras ?? {})) {
|
||||||
|
|
@ -96,9 +96,20 @@ export function adbTarget(and: NonNullable<ShotsCapture['android']>, device: 'ph
|
||||||
return device === 'tablet' ? and.serials?.tablet : and.serials?.phone ?? and.serial;
|
return device === 'tablet' ? and.serials?.tablet : and.serials?.phone ?? and.serial;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Which shots run on which device class. */
|
/** Capture device classes: phone / tablet frames (status bar cut) and desktop landscape frames (Mac, Chromebook). */
|
||||||
export function shotsFor(c: ShotsCapture, device: 'phone' | 'tablet', only: string[] = []): [string, ShotSpec][] {
|
export type CaptureDevice = 'phone' | 'tablet' | 'landscape';
|
||||||
return Object.entries(c.shots ?? {}).filter(([name, s]) => (!only.length || only.includes(name)) && ((s.device ?? 'phone') === 'both' || (s.device ?? 'phone') === device));
|
export const CAPTURE_DEVICES: readonly CaptureDevice[] = ['phone', 'tablet', 'landscape'];
|
||||||
|
|
||||||
|
/** Which shots run on which device class. phone / tablet: device unset = phone, 'both' = phone + tablet (unchanged).
|
||||||
|
* landscape: the shots with device 'landscape'; with `allLandscape` (the project renders a landscape size, or
|
||||||
|
* --device landscape was asked for) also every shot with no device or 'both', because render needs a landscape frame
|
||||||
|
* for each scene. A shot that says 'phone' or 'tablet' explicitly stays off the landscape list. */
|
||||||
|
export function shotsFor(c: ShotsCapture, device: CaptureDevice, only: string[] = [], allLandscape = false): [string, ShotSpec][] {
|
||||||
|
return Object.entries(c.shots ?? {}).filter(([name, s]) => {
|
||||||
|
if (only.length && !only.includes(name)) return false;
|
||||||
|
if (device === 'landscape') return s.device === 'landscape' || (allLandscape && (s.device === undefined || s.device === 'both'));
|
||||||
|
return s.device !== 'landscape' && ((s.device ?? 'phone') === 'both' || (s.device ?? 'phone') === device);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// ---- iOS Simulator (xcrun simctl) ----
|
// ---- iOS Simulator (xcrun simctl) ----
|
||||||
|
|
|
||||||
|
|
@ -175,6 +175,15 @@ export function frameDims(config: Pick<ShipConfig, 'apple' | 'shots'>): Record<'
|
||||||
return { phone: { ...DEFAULT_PHONE, ...config.shots?.phone }, tablet: { ...tablet, ...config.shots?.tablet } };
|
return { phone: { ...DEFAULT_PHONE, ...config.shots?.phone }, tablet: { ...tablet, ...config.shots?.tablet } };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Landscape capture viewport (shots.landscape.size): a desktop window, 1440 x 900 CSS px @2x = 2880 x 1800 (the Mac size). No status bar. */
|
||||||
|
export const DEFAULT_LANDSCAPE: FrameDims = { w: 1440, h: 900, dpr: 2, bar: 0 };
|
||||||
|
|
||||||
|
/** Viewport `shots capture` uses for landscape frames (<lang>/landscape/<name>.png): shots.landscape.size over the default. */
|
||||||
|
export function landscapeDims(config: Pick<ShipConfig, 'shots'>): FrameDims {
|
||||||
|
const s = config.shots?.landscape?.size;
|
||||||
|
return { ...DEFAULT_LANDSCAPE, ...(s ? { w: s.w, h: s.h, ...(s.dpr ? { dpr: s.dpr } : {}) } : {}), bar: 0 };
|
||||||
|
}
|
||||||
|
|
||||||
/** Play tablet size keys (7" and 10"): optional on Play, switched by play.tablets. */
|
/** Play tablet size keys (7" and 10"): optional on Play, switched by play.tablets. */
|
||||||
export const PLAY_TABLET_SIZES: readonly string[] = ['tab7', 'tab10'];
|
export const PLAY_TABLET_SIZES: readonly string[] = ['tab7', 'tab10'];
|
||||||
|
|
||||||
|
|
@ -193,6 +202,12 @@ export function defaultSizes(config: Pick<ShipConfig, 'apple' | 'play'>, tablets
|
||||||
: k.startsWith('ios') ? apple : PLAY_TABLET_SIZES.includes(k) ? play && tabs : play));
|
: k.startsWith('ios') ? apple : PLAY_TABLET_SIZES.includes(k) ? play && tabs : play));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** True when `shots render` draws a landscape size for this project (apple.mac, play.chromebook, shots.landscape.playTablets):
|
||||||
|
* it then needs <lang>/landscape/<name>.png frames, which `shots capture` makes with the landscape device. Same rules as render. */
|
||||||
|
export function rendersLandscape(config: Pick<ShipConfig, 'apple' | 'play' | 'shots'>): boolean {
|
||||||
|
return defaultSizes(config).some(s => renderDims(s, config.shots).landscape);
|
||||||
|
}
|
||||||
|
|
||||||
/** Scenes of a variant (its order / subset, palette overrides), or the base scenes. */
|
/** Scenes of a variant (its order / subset, palette overrides), or the base scenes. */
|
||||||
export function variantScenes(shots: ShotsConfig, variant?: string): ShotScene[] {
|
export function variantScenes(shots: ShotsConfig, variant?: string): ShotScene[] {
|
||||||
if (!variant) return shots.scenes;
|
if (!variant) return shots.scenes;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
// a list on the phone and a grid at 1180x820 needs different selectors; the miss message names the selector and the size.
|
// a list on the phone and a grid at 1180x820 needs different selectors; the miss message names the selector and the size.
|
||||||
import type { ShotSelector } from '../lib/config';
|
import type { ShotSelector } from '../lib/config';
|
||||||
|
|
||||||
type Device = 'phone' | 'tablet';
|
import type { CaptureDevice as Device } from './devices';
|
||||||
|
|
||||||
/** Candidates for one device: its own list first, then the shared ones, without repeats. */
|
/** Candidates for one device: its own list first, then the shared ones, without repeats. */
|
||||||
export function candidates(sel: ShotSelector | undefined, device: Device): string[] {
|
export function candidates(sel: ShotSelector | undefined, device: Device): string[] {
|
||||||
|
|
@ -19,12 +19,12 @@ export function validateSelector(where: string, sel: unknown): string[] {
|
||||||
const okList = (v: unknown): boolean => ok(v) || (Array.isArray(v) && v.length > 0 && v.every(ok));
|
const okList = (v: unknown): boolean => ok(v) || (Array.isArray(v) && v.length > 0 && v.every(ok));
|
||||||
if (okList(sel)) return [];
|
if (okList(sel)) return [];
|
||||||
if (sel && typeof sel === 'object' && !Array.isArray(sel)) {
|
if (sel && typeof sel === 'object' && !Array.isArray(sel)) {
|
||||||
const o = sel as Record<string, unknown>, bad = Object.keys(o).filter(k => !['phone', 'tablet', 'any'].includes(k));
|
const o = sel as Record<string, unknown>, bad = Object.keys(o).filter(k => !['phone', 'tablet', 'landscape', 'any'].includes(k));
|
||||||
if (bad.length) return [`${where}: unknown key ${bad.join(', ')} (phone | tablet | any)`];
|
if (bad.length) return [`${where}: unknown key ${bad.join(', ')} (phone | tablet | landscape | any)`];
|
||||||
if (!Object.keys(o).length) return [`${where}: at least one of phone | tablet | any`];
|
if (!Object.keys(o).length) return [`${where}: at least one of phone | tablet | landscape | any`];
|
||||||
return Object.entries(o).filter(([, v]) => !okList(v)).map(([k]) => `${where}.${k}: a selector or a list of selectors`);
|
return Object.entries(o).filter(([, v]) => !okList(v)).map(([k]) => `${where}.${k}: a selector or a list of selectors`);
|
||||||
}
|
}
|
||||||
return [`${where}: a selector, a list of selectors, or { phone, tablet, any }`];
|
return [`${where}: a selector, a list of selectors, or { phone, tablet, landscape, any }`];
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Minimal Playwright surface used here, so tests can fake a page. */
|
/** Minimal Playwright surface used here, so tests can fake a page. */
|
||||||
|
|
|
||||||
|
|
@ -61,11 +61,10 @@ export const IMAGE_SPECS: Record<string, ImageSpec> = {
|
||||||
feature: { store: 'play', type: 'featureGraphic', label: 'Play feature graphic', sizes: [[1024, 500]], min: 1, max: 1, maxBytes: 15 * MB, alpha: false },
|
feature: { store: 'play', type: 'featureGraphic', label: 'Play feature graphic', sizes: [[1024, 500]], min: 1, max: 1, maxBytes: 15 * MB, alpha: false },
|
||||||
};
|
};
|
||||||
|
|
||||||
/** ASC screenshotDisplayType per iPhone Duo size key. null = NOT IN THE API YET: ScreenshotDisplayType in App Store
|
/** iPhone Duo size keys. Values stay null: ScreenshotDisplayType has no Duo value and never will (API 4.5.1 put the
|
||||||
* Connect API 4.5.1 (spec re-checked 2026-10-20: the published zip is still the 2026-10-06 one, same sha256) has no Duo value (only AppAssetLibraryDisplayClass lists IPHONE_DUO).
|
* display class IPHONE_DUO into the App Asset Library only and deprecated screenshot sets); apple screenshots
|
||||||
* When Apple adds it: regenerate (bun tools/gen-api.ts) and put the exact enum names here; uploads then include them. */
|
* uploads Duo through the library (cli/apple/duo-library.ts, pitfall 130). */
|
||||||
export const IPHONE_DUO_DISPLAY: Record<string, string | null> = { 'iphone-duo-outer': null, 'iphone-duo-inner': null };
|
export const IPHONE_DUO_DISPLAY: Record<string, string | null> = { 'iphone-duo-outer': null, 'iphone-duo-inner': null };
|
||||||
export const IPHONE_DUO_NOT_IN_API = 'not uploaded: the App Store Connect API has no iPhone Duo display type yet (the console takes them); the renders stay in store/renders';
|
|
||||||
/** Reportedly required from this date for apps built with the iOS 27.1 SDK or later. */
|
/** Reportedly required from this date for apps built with the iOS 27.1 SDK or later. */
|
||||||
export const IPHONE_DUO_REQUIRED_FROM = '2027-04-01';
|
export const IPHONE_DUO_REQUIRED_FROM = '2027-04-01';
|
||||||
const PLAY_FOLDABLE = 'Google Play has no foldable slot: foldables show the 7" / 10" tablet screenshots (tab7, tab10, play.tablets)';
|
const PLAY_FOLDABLE = 'Google Play has no foldable slot: foldables show the 7" / 10" tablet screenshots (tab7, tab10, play.tablets)';
|
||||||
|
|
@ -75,7 +74,7 @@ const PLAY_FOLDABLE = 'Google Play has no foldable slot: foldables show the 7" /
|
||||||
export function iphoneDuoNote(o: { apple: boolean; duo: boolean; play?: boolean; today?: Date }): { level: 'info' | 'warn'; msg: string } | null {
|
export function iphoneDuoNote(o: { apple: boolean; duo: boolean; play?: boolean; today?: Date }): { level: 'info' | 'warn'; msg: string } | null {
|
||||||
if (!o.apple || o.duo) return null;
|
if (!o.apple || o.duo) return null;
|
||||||
const late = (o.today ?? new Date()).toISOString().slice(0, 10) >= IPHONE_DUO_REQUIRED_FROM;
|
const late = (o.today ?? new Date()).toISOString().slice(0, 10) >= IPHONE_DUO_REQUIRED_FROM;
|
||||||
return { level: late ? 'warn' : 'info', msg: `no iPhone Duo screenshots (outer 1398x2034, inner 2007x2853; apple.iphoneDuo): optional now, required from April 2027 for iOS 27.1 SDK builds; the App Store Connect console takes Duo screenshots and previews, the API does not yet (apple screenshots skips them with the console link)${o.play ? `. ${PLAY_FOLDABLE}` : ''}` };
|
return { level: late ? 'warn' : 'info', msg: `no iPhone Duo screenshots (outer 1398x2034, inner 2007x2853; apple.iphoneDuo): optional now, required from April 2027 for iOS 27.1 SDK builds; apple screenshots uploads them through the App Asset Library (display class IPHONE_DUO)${o.play ? `. ${PLAY_FOLDABLE}` : ''}` };
|
||||||
}
|
}
|
||||||
|
|
||||||
/** validate / check note for an app with a macOS version but no Mac screenshots (apple.mac off or no mac renders). */
|
/** validate / check note for an app with a macOS version but no Mac screenshots (apple.mac off or no mac renders). */
|
||||||
|
|
|
||||||
|
|
@ -22,6 +22,7 @@ import { firstProductReport } from './apple/first-products';
|
||||||
import { requiredDisplayTypes } from './apple/screenshots';
|
import { requiredDisplayTypes } from './apple/screenshots';
|
||||||
import { pendingScreenshots, setRows, type ShotRow, updateLedger } from './apple/screenshot-health';
|
import { pendingScreenshots, setRows, type ShotRow, updateLedger } from './apple/screenshot-health';
|
||||||
import { type Loaded, playCategoryOf, playCodes, profileOf, sellsOn } from './lib/config';
|
import { type Loaded, playCategoryOf, playCodes, profileOf, sellsOn } from './lib/config';
|
||||||
|
import { reviewNotes } from './lib/review-details';
|
||||||
import { reviewDemoAccount } from './lib/credentials';
|
import { reviewDemoAccount } from './lib/credentials';
|
||||||
import { allSubscriptions, basePlanId } from './lib/subscriptions';
|
import { allSubscriptions, basePlanId } from './lib/subscriptions';
|
||||||
import type { Ctx } from './lib/ctx';
|
import type { Ctx } from './lib/ctx';
|
||||||
|
|
@ -34,10 +35,12 @@ import { rendersCheck } from './shots/check';
|
||||||
import { resolvedTablets } from './shots/report';
|
import { resolvedTablets } from './shots/report';
|
||||||
import { runScan } from './lib/scan';
|
import { runScan } from './lib/scan';
|
||||||
import type { ScanFinding } from './lib/scan/rules';
|
import type { ScanFinding } from './lib/scan/rules';
|
||||||
import { playClient } from './play/client';
|
import { EDIT_GONE, playClient } from './play/client';
|
||||||
import { listOneTimeProducts } from './play/products';
|
import { listOneTimeProducts } from './play/products';
|
||||||
import { creativeNote } from './shots/creative';
|
import { creativeNote } from './shots/creative';
|
||||||
import { creativeWaiting, localCreative } from './apple/creative-assets';
|
import { creativeWaiting, localCreative } from './apple/creative-assets';
|
||||||
|
import { liveDeviceFamilies } from './apple/device-families';
|
||||||
|
import { type FamilyVerdict, familyVerdicts, projectFamilies } from './lib/device-families';
|
||||||
import { fixFor, GUIDELINE, hitLine } from './lib/cross-store';
|
import { fixFor, GUIDELINE, hitLine } from './lib/cross-store';
|
||||||
import { listingFileMentions } from './lib/listing-mentions';
|
import { listingFileMentions } from './lib/listing-mentions';
|
||||||
import { brokerConfig, brokerPlayInfo, enabledApisOf, grantsOf, type PlayNeed, playGaps, sdkConfigGaps } from './lib/broker';
|
import { brokerConfig, brokerPlayInfo, enabledApisOf, grantsOf, type PlayNeed, playGaps, sdkConfigGaps } from './lib/broker';
|
||||||
|
|
@ -98,6 +101,14 @@ async function creativeWaitingOf(ctx: Ctx, c: Awaited<ReturnType<typeof ascClien
|
||||||
} catch { return []; }
|
} catch { return []; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Live version's device families against the project and apple.ipad (cli/lib/device-families.ts). A failed read is a warning, never a blocker. */
|
||||||
|
async function deviceFamilyVerdicts(ctx: Ctx, c: Awaited<ReturnType<typeof ascClient>>, appId: string): Promise<FamilyVerdict[]> {
|
||||||
|
const { config, root } = ctx.loaded;
|
||||||
|
try {
|
||||||
|
return familyVerdicts({ live: await liveDeviceFamilies(c, appId), project: projectFamilies(root, config.apple!.bundleId, config.apple?.build?.project), ipad: config.apple?.ipad });
|
||||||
|
} catch (e) { return [{ level: 'warn', msg: `device families not compared: ${(e as Error).message.slice(0, 200)}` }]; }
|
||||||
|
}
|
||||||
|
|
||||||
export async function collectApple(ctx: Ctx): Promise<AppleSnapshot> {
|
export async function collectApple(ctx: Ctx): Promise<AppleSnapshot> {
|
||||||
const { config, root } = ctx.loaded;
|
const { config, root } = ctx.loaded;
|
||||||
const c = await ascClient(root, config.apple!.bundleId, config.apple?.appId);
|
const c = await ascClient(root, config.apple!.bundleId, config.apple?.appId);
|
||||||
|
|
@ -107,7 +118,7 @@ export async function collectApple(ctx: Ctx): Promise<AppleSnapshot> {
|
||||||
const every = await allVersions(c, appId);
|
const every = await allVersions(c, appId);
|
||||||
const editableOf = (x: J) => APPLE_EDITABLE.has(stateOf(x));
|
const editableOf = (x: J) => APPLE_EDITABLE.has(stateOf(x));
|
||||||
const withEditable = [...new Set(every.filter(editableOf).map(platformOf))];
|
const withEditable = [...new Set(every.filter(editableOf).map(platformOf))];
|
||||||
const platform: AscPlatform = parsePlatform(ctx.args.get('platform')) ?? (withEditable.length === 1 ? withEditable[0]! : withEditable.includes('IOS') || !every.length ? 'IOS' : platformOf(every[0]));
|
const platform: AscPlatform = parsePlatform(ctx.args.get('platform')) ?? (withEditable.length === 1 ? withEditable[0]! : withEditable.includes('IOS') || !every.length || every.some(x => platformOf(x) === 'IOS') ? 'IOS' : platformOf(every[0]));
|
||||||
const versions = await c.all(versionsPath(appId, platform, 10));
|
const versions = await c.all(versionsPath(appId, platform, 10));
|
||||||
const v: J = (await c.editableVersion(platform)) ?? versions[0] ?? null;
|
const v: J = (await c.editableVersion(platform)) ?? versions[0] ?? null;
|
||||||
const otherPlatformVersions = every.filter(x => platformOf(x) !== platform && editableOf(x)).map(x => ({ versionString: String(x.attributes.versionString), state: stateOf(x), platform: platformOf(x) }));
|
const otherPlatformVersions = every.filter(x => platformOf(x) !== platform && editableOf(x)).map(x => ({ versionString: String(x.attributes.versionString), state: stateOf(x), platform: platformOf(x) }));
|
||||||
|
|
@ -133,7 +144,7 @@ export async function collectApple(ctx: Ctx): Promise<AppleSnapshot> {
|
||||||
shotRows.push(...setRows(shots, l.attributes.locale, s.attributes.screenshotDisplayType));
|
shotRows.push(...setRows(shots, l.attributes.locale, s.attributes.screenshotDisplayType));
|
||||||
}
|
}
|
||||||
const ia = infoLocs.get(l.attributes.locale) ?? {};
|
const ia = infoLocs.get(l.attributes.locale) ?? {};
|
||||||
locales.push({ locale: l.attributes.locale, name: ia.name, subtitle: ia.subtitle, description: l.attributes.description, keywords: l.attributes.keywords, screenshots });
|
locales.push({ locale: l.attributes.locale, name: ia.name, subtitle: ia.subtitle, description: l.attributes.description, keywords: l.attributes.keywords, promotionalText: l.attributes.promotionalText ?? undefined, whatsNew: l.attributes.whatsNew ?? undefined, screenshots });
|
||||||
}
|
}
|
||||||
reviewDetail = (await c.maybe(`/v1/appStoreVersions/${v.id}/appStoreReviewDetail`))?.data?.attributes ?? null;
|
reviewDetail = (await c.maybe(`/v1/appStoreVersions/${v.id}/appStoreReviewDetail`))?.data?.attributes ?? null;
|
||||||
}
|
}
|
||||||
|
|
@ -173,10 +184,12 @@ export async function collectApple(ctx: Ctx): Promise<AppleSnapshot> {
|
||||||
creativeWaiting: await creativeWaitingOf(ctx, c, appId),
|
creativeWaiting: await creativeWaitingOf(ctx, c, appId),
|
||||||
screenshotsPending: pendingScreenshots(shotRows, updateLedger(root, shotRows), Date.now()),
|
screenshotsPending: pendingScreenshots(shotRows, updateLedger(root, shotRows), Date.now()),
|
||||||
configCopyright: config.app.copyright,
|
configCopyright: config.app.copyright,
|
||||||
|
deviceFamilies: platform === 'IOS' ? await deviceFamilyVerdicts(ctx, c, appId) : undefined,
|
||||||
build, locales, reviewDetail, ageRating,
|
build, locales, reviewDetail, ageRating,
|
||||||
expectedLocales: config.languages.map(l => l.apple).filter((x): x is string => !!x),
|
expectedLocales: config.languages.map(l => l.apple).filter((x): x is string => !!x),
|
||||||
requiredDisplayTypes: requiredDisplayTypes(config.apple),
|
requiredDisplayTypes: requiredDisplayTypes(config.apple, platform),
|
||||||
iphoneDuo: !!config.apple?.iphoneDuo, play: !!config.play,
|
iphoneDuo: !!config.apple?.iphoneDuo, play: !!config.play,
|
||||||
|
macos: platform === 'MAC_OS' ? { notes: reviewNotes(config, 'macos'), gameCenter: config.apple?.macos?.gameCenter, noIap: config.apple?.macos?.noIap } : undefined,
|
||||||
macVersion: every.some(x => platformOf(x) === 'MAC_OS'), mac: !!config.apple?.mac,
|
macVersion: every.some(x => platformOf(x) === 'MAC_OS'), mac: !!config.apple?.mac,
|
||||||
priceSchedule: !!sched?.included?.some((x: J) => x.type === 'appPrices'),
|
priceSchedule: !!sched?.included?.some((x: J) => x.type === 'appPrices'),
|
||||||
availability: !!avail?.data,
|
availability: !!avail?.data,
|
||||||
|
|
@ -191,23 +204,25 @@ export async function collectPlay(ctx: Ctx): Promise<PlaySnapshot> {
|
||||||
const { config, root } = ctx.loaded;
|
const { config, root } = ctx.loaded;
|
||||||
const play = await playClient(root, config.play!.packageName);
|
const play = await playClient(root, config.play!.packageName);
|
||||||
const tablets = resolvedTablets(config, ctx.loaded.resolve(ctx.args.get('src') ?? config.renders ?? config.shots?.out ?? 'store/renders'));
|
const tablets = resolvedTablets(config, ctx.loaded.resolve(ctx.args.get('src') ?? config.renders ?? config.shots?.out ?? 'store/renders'));
|
||||||
const e = await play.call<{ id: string }>('POST', `${play.API}/edits`, {});
|
// play.read: one edit under the machine lock, deleted only after every read inside has finished, and opened anew once
|
||||||
log('validate', `play: read-only edit ${e.id} (deleted afterwards)`);
|
// when Play invalidates it meanwhile ("This Edit has been deleted"). A bare POST /edits here was neither locked nor
|
||||||
try {
|
// retried, so another storebound process (or the Console) ending the edit failed the screenshot reads with a false blocker.
|
||||||
const details = await play.call<{ defaultLanguage?: string; contactWebsite?: string }>('GET', `${play.API}/edits/${e.id}/details`);
|
return play.read(async editId => {
|
||||||
const raw = (await play.call<{ listings?: { language: string; title?: string; shortDescription?: string; fullDescription?: string }[] }>('GET', `${play.API}/edits/${e.id}/listings`)).listings ?? [];
|
log('validate', `play: read-only edit ${editId} (deleted afterwards)`);
|
||||||
|
const details = await play.call<{ defaultLanguage?: string; contactWebsite?: string }>('GET', `${play.API}/edits/${editId}/details`);
|
||||||
|
const raw = (await play.call<{ listings?: { language: string; title?: string; shortDescription?: string; fullDescription?: string }[] }>('GET', `${play.API}/edits/${editId}/listings`)).listings ?? [];
|
||||||
const listings: PlaySnapshot['listings'] = [];
|
const listings: PlaySnapshot['listings'] = [];
|
||||||
for (const l of raw) {
|
for (const l of raw) {
|
||||||
const images: Record<string, number> = {};
|
const images: Record<string, number> = {};
|
||||||
for (const type of Object.keys(playRequiredImages(tablets)))
|
for (const type of Object.keys(playRequiredImages(tablets)))
|
||||||
images[type] = ((await play.call<{ images?: unknown[] }>('GET', `${play.API}/edits/${e.id}/listings/${l.language}/${type}`)).images ?? []).length;
|
images[type] = ((await play.call<{ images?: unknown[] }>('GET', `${play.API}/edits/${editId}/listings/${l.language}/${type}`)).images ?? []).length;
|
||||||
listings.push({ ...l, images });
|
listings.push({ ...l, images });
|
||||||
}
|
}
|
||||||
const tracks = ((await play.call<{ tracks?: { track: string; releases?: { status: string; versionCodes?: string[]; userFraction?: number }[] }[] }>('GET', `${play.API}/edits/${e.id}/tracks`)).tracks ?? [])
|
const tracks = ((await play.call<{ tracks?: { track: string; releases?: { status: string; versionCodes?: string[]; userFraction?: number }[] }[] }>('GET', `${play.API}/edits/${editId}/tracks`)).tracks ?? [])
|
||||||
.map(t => ({ track: t.track, releases: (t.releases ?? []).map(r => ({ status: r.status, versionCodes: r.versionCodes ?? [], userFraction: r.userFraction })) }));
|
.map(t => ({ track: t.track, releases: (t.releases ?? []).map(r => ({ status: r.status, versionCodes: r.versionCodes ?? [], userFraction: r.userFraction })) }));
|
||||||
const products = (await listOneTimeProducts(play)).map(p => ({ productId: p.productId, states: (p.purchaseOptions ?? []).map(o => o.state ?? '') }));
|
const products = (await listOneTimeProducts(play)).map(p => ({ productId: p.productId, states: (p.purchaseOptions ?? []).map(o => o.state ?? '') }));
|
||||||
// the production track's countries (read-only in the API: set in the console, `console plan play-production-countries`)
|
// the production track's countries (read-only in the API: set in the console, `console plan play-production-countries`)
|
||||||
const productionCountries = await play.call<{ countries?: unknown[]; restOfWorld?: boolean }>('GET', `${play.API}/edits/${e.id}/countryAvailability/production`)
|
const productionCountries = await play.call<{ countries?: unknown[]; restOfWorld?: boolean }>('GET', `${play.API}/edits/${editId}/countryAvailability/production`)
|
||||||
.then(r => (r.restOfWorld ? -1 : (r.countries ?? []).length)).catch(() => null);
|
.then(r => (r.restOfWorld ? -1 : (r.countries ?? []).length)).catch(() => null);
|
||||||
const website = details.contactWebsite ?? null;
|
const website = details.contactWebsite ?? null;
|
||||||
const appAdsLines = config.ads?.appAdsTxt ?? [];
|
const appAdsLines = config.ads?.appAdsTxt ?? [];
|
||||||
|
|
@ -234,9 +249,7 @@ export async function collectPlay(ctx: Ctx): Promise<PlaySnapshot> {
|
||||||
expectedProducts: (config.products ?? []).filter(p => sellsOn(config, p, 'play')).map(p => p.id),
|
expectedProducts: (config.products ?? []).filter(p => sellsOn(config, p, 'play')).map(p => p.id),
|
||||||
privacyUrl: await checkUrl(config.app.privacyPolicyUrl), website, appAds, appAdsLines, adsLikely, category: playCategoryOf(config), productionCountries,
|
privacyUrl: await checkUrl(config.app.privacyPolicyUrl), website, appAds, appAdsLines, adsLikely, category: playCategoryOf(config), productionCountries,
|
||||||
};
|
};
|
||||||
} finally {
|
});
|
||||||
await play.call('DELETE', `${play.API}/edits/${e.id}`).catch(() => {});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Scan findings as validate findings: blocker stays blocker, high / medium become warnings; low and owner-accepted
|
/** Scan findings as validate findings: blocker stays blocker, high / medium become warnings; low and owner-accepted
|
||||||
|
|
@ -268,7 +281,13 @@ export async function run(ctx: Ctx): Promise<void> {
|
||||||
const access = await brokerFindings(ctx.loaded).catch(e => [{ store: 'play' as const, level: 'warn' as const, code: 'broker-unavailable', msg: (e as Error).message }]);
|
const access = await brokerFindings(ctx.loaded).catch(e => [{ store: 'play' as const, level: 'warn' as const, code: 'broker-unavailable', msg: (e as Error).message }]);
|
||||||
findings.push(...access);
|
findings.push(...access);
|
||||||
try { findings.push(...playRules({ ...(await collectPlay(ctx)), renders: local?.play })); }
|
try { findings.push(...playRules({ ...(await collectPlay(ctx)), renders: local?.play })); }
|
||||||
catch (e) { findings.push({ store: 'play', level: 'blocker', code: 'api', msg: (e as Error).message.slice(0, 600) }, ...rendersFindings('play', local?.play)); }
|
catch (e) {
|
||||||
|
// a Play edit that vanished under the reads is a tool problem (the retry inside play.read failed too), never a store blocker
|
||||||
|
const gone = EDIT_GONE.test((e as Error).message);
|
||||||
|
findings.push(gone
|
||||||
|
? { store: 'play', level: 'warn', code: 'edit-gone', msg: `Play validate could not finish its read-only edit (${(e as Error).message.slice(0, 300)}): a tool problem, not a store finding`, fix: 'storebound validate --play (run it again; close other storebound runs and Console saves first)' }
|
||||||
|
: { store: 'play', level: 'blocker', code: 'api', msg: (e as Error).message.slice(0, 600) }, ...rendersFindings('play', local?.play));
|
||||||
|
}
|
||||||
} else if (a.has('play')) warn('validate', 'no play section in the config');
|
} else if (a.has('play')) warn('validate', 'no play section in the config');
|
||||||
// Game Center / Play Games Services: entitlement, APP_ID resource, store state vs the config
|
// Game Center / Play Games Services: entitlement, APP_ID resource, store state vs the config
|
||||||
if (config.games || config.apple) {
|
if (config.games || config.apple) {
|
||||||
|
|
|
||||||
|
|
@ -27,8 +27,7 @@ State of storebound for whoever picks it up next. Public-safe: no project, app o
|
||||||
- The Play Games Services console page paths.
|
- The Play Games Services console page paths.
|
||||||
- The Games Configuration API bodies (no pinned spec).
|
- The Games Configuration API bodies (no pinned spec).
|
||||||
- Placing a Header and Search Results asset on a live App Store version.
|
- Placing a Header and Search Results asset on a live App Store version.
|
||||||
- **iPhone Duo:** App Store Connect's API has no Duo screenshot type yet. Uploads skip with a console link; wire it
|
- **iPhone Duo:** uploaded through the App Asset Library (`cli/apple/duo-library.ts`); previews still use the deprecated sets.
|
||||||
when the spec gains the type (`IPHONE_DUO_DISPLAY` in `cli/shots/spec.ts`).
|
|
||||||
|
|
||||||
## Rules that matter here
|
## Rules that matter here
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
|
|
||||||
| API | operations | GET | other | wrapped by a command | owner only |
|
| API | operations | GET | other | wrapped by a command | owner only |
|
||||||
|---|---:|---:|---:|---:|---:|
|
|---|---:|---:|---:|---:|---:|
|
||||||
| App Store Connect API 4.5.1 | 1303 | 826 | 477 | 232 | 166 |
|
| App Store Connect API 4.5.1 | 1303 | 826 | 477 | 236 | 166 |
|
||||||
| Google Play Android Developer API v3 (revision 20261008) | 145 | 45 | 100 | 35 | 49 |
|
| Google Play Android Developer API v3 (revision 20261008) | 145 | 45 | 100 | 35 | 49 |
|
||||||
| Google Play Developer Reporting API v1beta1 (revision 20261008) | 25 | 15 | 10 | 6 | 0 |
|
| Google Play Developer Reporting API v1beta1 (revision 20261008) | 25 | 15 | 10 | 6 | 0 |
|
||||||
|
|
||||||
|
|
@ -80,7 +80,7 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `androidToIosAppMappingDetails_updateInstance` | PATCH | `/v1/androidToIosAppMappingDetails/{id}` | write (dry by default) | |
|
| `androidToIosAppMappingDetails_updateInstance` | PATCH | `/v1/androidToIosAppMappingDetails/{id}` | write (dry by default) | |
|
||||||
| **appAssetLibraries** (5) | | | | |
|
| **appAssetLibraries** (5) | | | | |
|
||||||
| `appAssetLibraries_getInstance` | GET | `/v1/appAssetLibraries/{id}` | read | |
|
| `appAssetLibraries_getInstance` | GET | `/v1/appAssetLibraries/{id}` | read | |
|
||||||
| `appAssetLibraries_images_getToManyRelated` | GET | `/v1/appAssetLibraries/{id}/images` | read | apple/creative-assets |
|
| `appAssetLibraries_images_getToManyRelated` | GET | `/v1/appAssetLibraries/{id}/images` | read | apple/creative-assets, apple/duo-library |
|
||||||
| `appAssetLibraries_images_getToManyRelationship` | GET | `/v1/appAssetLibraries/{id}/relationships/images` | read | |
|
| `appAssetLibraries_images_getToManyRelationship` | GET | `/v1/appAssetLibraries/{id}/relationships/images` | read | |
|
||||||
| `appAssetLibraries_videos_getToManyRelated` | GET | `/v1/appAssetLibraries/{id}/videos` | read | apple/creative-assets |
|
| `appAssetLibraries_videos_getToManyRelated` | GET | `/v1/appAssetLibraries/{id}/videos` | read | apple/creative-assets |
|
||||||
| `appAssetLibraries_videos_getToManyRelationship` | GET | `/v1/appAssetLibraries/{id}/relationships/videos` | read | |
|
| `appAssetLibraries_videos_getToManyRelationship` | GET | `/v1/appAssetLibraries/{id}/relationships/videos` | read | |
|
||||||
|
|
@ -94,11 +94,11 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| **appAssetLibraryPlacementOrderingRequests** (1) | | | | |
|
| **appAssetLibraryPlacementOrderingRequests** (1) | | | | |
|
||||||
| `appAssetLibraryPlacementOrderingRequests_createInstance` | POST | `/v1/appAssetLibraryPlacementOrderingRequests` | write (dry by default) | |
|
| `appAssetLibraryPlacementOrderingRequests_createInstance` | POST | `/v1/appAssetLibraryPlacementOrderingRequests` | write (dry by default) | |
|
||||||
| **appAssetLibraryPlacements** (3) | | | | |
|
| **appAssetLibraryPlacements** (3) | | | | |
|
||||||
| `appAssetLibraryPlacements_createInstance` | POST | `/v1/appAssetLibraryPlacements` | write (dry by default) | apple/creative-assets |
|
| `appAssetLibraryPlacements_createInstance` | POST | `/v1/appAssetLibraryPlacements` | write (dry by default) | apple/creative-assets, apple/duo-library |
|
||||||
| `appAssetLibraryPlacements_deleteInstance` | DELETE | `/v1/appAssetLibraryPlacements/{id}` | owner only (typed confirm) | apple/creative-assets |
|
| `appAssetLibraryPlacements_deleteInstance` | DELETE | `/v1/appAssetLibraryPlacements/{id}` | owner only (typed confirm) | apple/creative-assets, apple/duo-library |
|
||||||
| `appAssetLibraryPlacements_getInstance` | GET | `/v1/appAssetLibraryPlacements/{id}` | read | |
|
| `appAssetLibraryPlacements_getInstance` | GET | `/v1/appAssetLibraryPlacements/{id}` | read | |
|
||||||
| **appAssetLibraryRefData** (2) | | | | |
|
| **appAssetLibraryRefData** (2) | | | | |
|
||||||
| `appAssetLibraryRefData_getCollection` | GET | `/v1/appAssetLibraryRefData` | read | |
|
| `appAssetLibraryRefData_getCollection` | GET | `/v1/appAssetLibraryRefData` | read | apple/duo-library |
|
||||||
| `appAssetLibraryRefData_getInstance` | GET | `/v1/appAssetLibraryRefData/{id}` | read | |
|
| `appAssetLibraryRefData_getInstance` | GET | `/v1/appAssetLibraryRefData/{id}` | read | |
|
||||||
| **appAssetLibraryVideos** (6) | | | | |
|
| **appAssetLibraryVideos** (6) | | | | |
|
||||||
| `appAssetLibraryVideos_createInstance` | POST | `/v1/appAssetLibraryVideos` | write (dry by default) | |
|
| `appAssetLibraryVideos_createInstance` | POST | `/v1/appAssetLibraryVideos` | write (dry by default) | |
|
||||||
|
|
@ -337,12 +337,12 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| **appStoreVersionLocalizations** (14) | | | | |
|
| **appStoreVersionLocalizations** (14) | | | | |
|
||||||
| `appStoreVersionLocalizations_appPreviewSets_getToManyRelated` | GET | `/v1/appStoreVersionLocalizations/{id}/appPreviewSets` | read | apple/previews, art |
|
| `appStoreVersionLocalizations_appPreviewSets_getToManyRelated` | GET | `/v1/appStoreVersionLocalizations/{id}/appPreviewSets` | read | apple/previews, art |
|
||||||
| `appStoreVersionLocalizations_appPreviewSets_getToManyRelationship` | GET | `/v1/appStoreVersionLocalizations/{id}/relationships/appPreviewSets` | read | |
|
| `appStoreVersionLocalizations_appPreviewSets_getToManyRelationship` | GET | `/v1/appStoreVersionLocalizations/{id}/relationships/appPreviewSets` | read | |
|
||||||
| `appStoreVersionLocalizations_appScreenshotSets_getToManyRelated` | GET | `/v1/appStoreVersionLocalizations/{id}/appScreenshotSets` | read | apple/screenshot-health, apple/screenshots, art, validate |
|
| `appStoreVersionLocalizations_appScreenshotSets_getToManyRelated` | GET | `/v1/appStoreVersionLocalizations/{id}/appScreenshotSets` | read | apple/device-families, apple/screenshot-health, apple/screenshots, art, validate |
|
||||||
| `appStoreVersionLocalizations_appScreenshotSets_getToManyRelationship` | GET | `/v1/appStoreVersionLocalizations/{id}/relationships/appScreenshotSets` | read | |
|
| `appStoreVersionLocalizations_appScreenshotSets_getToManyRelationship` | GET | `/v1/appStoreVersionLocalizations/{id}/relationships/appScreenshotSets` | read | |
|
||||||
| `appStoreVersionLocalizations_createInstance` | POST | `/v1/appStoreVersionLocalizations` | write (dry by default) | listing-store |
|
| `appStoreVersionLocalizations_createInstance` | POST | `/v1/appStoreVersionLocalizations` | write (dry by default) | listing-store |
|
||||||
| `appStoreVersionLocalizations_deleteInstance` | DELETE | `/v1/appStoreVersionLocalizations/{id}` | owner only (typed confirm) | |
|
| `appStoreVersionLocalizations_deleteInstance` | DELETE | `/v1/appStoreVersionLocalizations/{id}` | owner only (typed confirm) | |
|
||||||
| `appStoreVersionLocalizations_getInstance` | GET | `/v1/appStoreVersionLocalizations/{id}` | read | |
|
| `appStoreVersionLocalizations_getInstance` | GET | `/v1/appStoreVersionLocalizations/{id}` | read | |
|
||||||
| `appStoreVersionLocalizations_placements_getToManyRelated` | GET | `/v1/appStoreVersionLocalizations/{id}/placements` | read | apple/creative-assets |
|
| `appStoreVersionLocalizations_placements_getToManyRelated` | GET | `/v1/appStoreVersionLocalizations/{id}/placements` | read | apple/creative-assets, apple/duo-library |
|
||||||
| `appStoreVersionLocalizations_placements_getToManyRelationship` | GET | `/v1/appStoreVersionLocalizations/{id}/relationships/placements` | read | |
|
| `appStoreVersionLocalizations_placements_getToManyRelationship` | GET | `/v1/appStoreVersionLocalizations/{id}/relationships/placements` | read | |
|
||||||
| `appStoreVersionLocalizations_searchKeywords_createToManyRelationship` | POST | `/v1/appStoreVersionLocalizations/{id}/relationships/searchKeywords` | write (dry by default) | |
|
| `appStoreVersionLocalizations_searchKeywords_createToManyRelationship` | POST | `/v1/appStoreVersionLocalizations/{id}/relationships/searchKeywords` | write (dry by default) | |
|
||||||
| `appStoreVersionLocalizations_searchKeywords_deleteToManyRelationship` | DELETE | `/v1/appStoreVersionLocalizations/{id}/relationships/searchKeywords` | owner only (typed confirm) | |
|
| `appStoreVersionLocalizations_searchKeywords_deleteToManyRelationship` | DELETE | `/v1/appStoreVersionLocalizations/{id}/relationships/searchKeywords` | owner only (typed confirm) | |
|
||||||
|
|
@ -371,13 +371,13 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `appStoreVersions_appStoreVersionExperimentsV2_getToManyRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionExperimentsV2` | read | |
|
| `appStoreVersions_appStoreVersionExperimentsV2_getToManyRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionExperimentsV2` | read | |
|
||||||
| `appStoreVersions_appStoreVersionExperiments_getToManyRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionExperiments` | read | |
|
| `appStoreVersions_appStoreVersionExperiments_getToManyRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionExperiments` | read | |
|
||||||
| `appStoreVersions_appStoreVersionExperiments_getToManyRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionExperiments` | read | |
|
| `appStoreVersions_appStoreVersionExperiments_getToManyRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionExperiments` | read | |
|
||||||
| `appStoreVersions_appStoreVersionLocalizations_getToManyRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionLocalizations` | read | apple/creative-assets, apple/listing, apple/previews, apple/screenshot-health, apple/screenshots, art, listing-store, onboard, validate |
|
| `appStoreVersions_appStoreVersionLocalizations_getToManyRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionLocalizations` | read | apple/creative-assets, apple/device-families, apple/listing, apple/previews, apple/screenshot-health, apple/screenshots, art, listing-store, onboard, validate |
|
||||||
| `appStoreVersions_appStoreVersionLocalizations_getToManyRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionLocalizations` | read | |
|
| `appStoreVersions_appStoreVersionLocalizations_getToManyRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionLocalizations` | read | |
|
||||||
| `appStoreVersions_appStoreVersionPhasedRelease_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionPhasedRelease` | read | apple/release, apple/status |
|
| `appStoreVersions_appStoreVersionPhasedRelease_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionPhasedRelease` | read | apple/release, apple/status |
|
||||||
| `appStoreVersions_appStoreVersionPhasedRelease_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionPhasedRelease` | read | |
|
| `appStoreVersions_appStoreVersionPhasedRelease_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionPhasedRelease` | read | |
|
||||||
| `appStoreVersions_appStoreVersionSubmission_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionSubmission` | read | |
|
| `appStoreVersions_appStoreVersionSubmission_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/appStoreVersionSubmission` | read | |
|
||||||
| `appStoreVersions_appStoreVersionSubmission_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionSubmission` | read | |
|
| `appStoreVersions_appStoreVersionSubmission_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/appStoreVersionSubmission` | read | |
|
||||||
| `appStoreVersions_build_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/build` | read | apple/listing, apple/resubmit, validate |
|
| `appStoreVersions_build_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/build` | read | apple/device-families, apple/listing, apple/resubmit, validate |
|
||||||
| `appStoreVersions_build_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/build` | read | |
|
| `appStoreVersions_build_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/build` | read | |
|
||||||
| `appStoreVersions_build_updateToOneRelationship` | PATCH | `/v1/appStoreVersions/{id}/relationships/build` | write (dry by default) | apple/listing, apple/resubmit |
|
| `appStoreVersions_build_updateToOneRelationship` | PATCH | `/v1/appStoreVersions/{id}/relationships/build` | write (dry by default) | apple/listing, apple/resubmit |
|
||||||
| `appStoreVersions_createInstance` | POST | `/v1/appStoreVersions` | write (dry by default) | apple/listing |
|
| `appStoreVersions_createInstance` | POST | `/v1/appStoreVersions` | write (dry by default) | apple/listing |
|
||||||
|
|
@ -389,7 +389,7 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `appStoreVersions_getInstance` | GET | `/v1/appStoreVersions/{id}` | read | apple/listing |
|
| `appStoreVersions_getInstance` | GET | `/v1/appStoreVersions/{id}` | read | apple/listing |
|
||||||
| `appStoreVersions_routingAppCoverage_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/routingAppCoverage` | read | |
|
| `appStoreVersions_routingAppCoverage_getToOneRelated` | GET | `/v1/appStoreVersions/{id}/routingAppCoverage` | read | |
|
||||||
| `appStoreVersions_routingAppCoverage_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/routingAppCoverage` | read | |
|
| `appStoreVersions_routingAppCoverage_getToOneRelationship` | GET | `/v1/appStoreVersions/{id}/relationships/routingAppCoverage` | read | |
|
||||||
| `appStoreVersions_updateInstance` | PATCH | `/v1/appStoreVersions/{id}` | write (dry by default) | apple/listing |
|
| `appStoreVersions_updateInstance` | PATCH | `/v1/appStoreVersions/{id}` | write (dry by default) | apple/listing, apple/release, apple/resubmit |
|
||||||
| **appTags** (3) | | | | |
|
| **appTags** (3) | | | | |
|
||||||
| `appTags_territories_getToManyRelated` | GET | `/v1/appTags/{id}/territories` | read | |
|
| `appTags_territories_getToManyRelated` | GET | `/v1/appTags/{id}/territories` | read | |
|
||||||
| `appTags_territories_getToManyRelationship` | GET | `/v1/appTags/{id}/relationships/territories` | read | |
|
| `appTags_territories_getToManyRelationship` | GET | `/v1/appTags/{id}/relationships/territories` | read | |
|
||||||
|
|
@ -425,7 +425,7 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `apps_appStoreVersions_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/appStoreVersions` | read | |
|
| `apps_appStoreVersions_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/appStoreVersions` | read | |
|
||||||
| `apps_appTags_getToManyRelated` | GET | `/v1/apps/{id}/appTags` | read | |
|
| `apps_appTags_getToManyRelated` | GET | `/v1/apps/{id}/appTags` | read | |
|
||||||
| `apps_appTags_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/appTags` | read | |
|
| `apps_appTags_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/appTags` | read | |
|
||||||
| `apps_assetLibrary_getToOneRelated` | GET | `/v1/apps/{id}/assetLibrary` | read | apple/creative-assets |
|
| `apps_assetLibrary_getToOneRelated` | GET | `/v1/apps/{id}/assetLibrary` | read | apple/creative-assets, apple/duo-library |
|
||||||
| `apps_assetLibrary_getToOneRelationship` | GET | `/v1/apps/{id}/relationships/assetLibrary` | read | |
|
| `apps_assetLibrary_getToOneRelationship` | GET | `/v1/apps/{id}/relationships/assetLibrary` | read | |
|
||||||
| `apps_backgroundAssets_getToManyRelated` | GET | `/v1/apps/{id}/backgroundAssets` | read | |
|
| `apps_backgroundAssets_getToManyRelated` | GET | `/v1/apps/{id}/backgroundAssets` | read | |
|
||||||
| `apps_backgroundAssets_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/backgroundAssets` | read | |
|
| `apps_backgroundAssets_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/backgroundAssets` | read | |
|
||||||
|
|
@ -459,7 +459,7 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `apps_gameCenterEnabledVersions_getToManyRelated` | GET | `/v1/apps/{id}/gameCenterEnabledVersions` | read | |
|
| `apps_gameCenterEnabledVersions_getToManyRelated` | GET | `/v1/apps/{id}/gameCenterEnabledVersions` | read | |
|
||||||
| `apps_gameCenterEnabledVersions_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/gameCenterEnabledVersions` | read | |
|
| `apps_gameCenterEnabledVersions_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/gameCenterEnabledVersions` | read | |
|
||||||
| `apps_getCollection` | GET | `/v1/apps` | read | apple/asc, apple/bundle, apps, console/app-id, console/verify, lib/store-apps |
|
| `apps_getCollection` | GET | `/v1/apps` | read | apple/asc, apple/bundle, apps, console/app-id, console/verify, lib/store-apps |
|
||||||
| `apps_getInstance` | GET | `/v1/apps/{id}` | read | apple/appinfo, apple/status, apps, onboard, watch |
|
| `apps_getInstance` | GET | `/v1/apps/{id}` | read | apple/appinfo, apple/status, apple/testflight, apps, onboard, watch |
|
||||||
| `apps_inAppPurchasesV2_getToManyRelated` | GET | `/v1/apps/{id}/inAppPurchasesV2` | read | apple/first-products, apple/iap, apple/iap-review, apple/iap-submit, apple/offer-codes, apple/promoted, apple/status, catalog, prices, validate |
|
| `apps_inAppPurchasesV2_getToManyRelated` | GET | `/v1/apps/{id}/inAppPurchasesV2` | read | apple/first-products, apple/iap, apple/iap-review, apple/iap-submit, apple/offer-codes, apple/promoted, apple/status, catalog, prices, validate |
|
||||||
| `apps_inAppPurchasesV2_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/inAppPurchasesV2` | read | |
|
| `apps_inAppPurchasesV2_getToManyRelationship` | GET | `/v1/apps/{id}/relationships/inAppPurchasesV2` | read | |
|
||||||
| `apps_inAppPurchases_getToManyRelated` | GET | `/v1/apps/{id}/inAppPurchases` | read | |
|
| `apps_inAppPurchases_getToManyRelated` | GET | `/v1/apps/{id}/inAppPurchases` | read | |
|
||||||
|
|
@ -620,7 +620,7 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `buildBundles_appClipDomainDebugStatus_getToOneRelationship` | GET | `/v1/buildBundles/{id}/relationships/appClipDomainDebugStatus` | read | |
|
| `buildBundles_appClipDomainDebugStatus_getToOneRelationship` | GET | `/v1/buildBundles/{id}/relationships/appClipDomainDebugStatus` | read | |
|
||||||
| `buildBundles_betaAppClipInvocations_getToManyRelated` | GET | `/v1/buildBundles/{id}/betaAppClipInvocations` | read | |
|
| `buildBundles_betaAppClipInvocations_getToManyRelated` | GET | `/v1/buildBundles/{id}/betaAppClipInvocations` | read | |
|
||||||
| `buildBundles_betaAppClipInvocations_getToManyRelationship` | GET | `/v1/buildBundles/{id}/relationships/betaAppClipInvocations` | read | |
|
| `buildBundles_betaAppClipInvocations_getToManyRelationship` | GET | `/v1/buildBundles/{id}/relationships/betaAppClipInvocations` | read | |
|
||||||
| `buildBundles_buildBundleFileSizes_getToManyRelated` | GET | `/v1/buildBundles/{id}/buildBundleFileSizes` | read | |
|
| `buildBundles_buildBundleFileSizes_getToManyRelated` | GET | `/v1/buildBundles/{id}/buildBundleFileSizes` | read | apple/device-families |
|
||||||
| `buildBundles_buildBundleFileSizes_getToManyRelationship` | GET | `/v1/buildBundles/{id}/relationships/buildBundleFileSizes` | read | |
|
| `buildBundles_buildBundleFileSizes_getToManyRelationship` | GET | `/v1/buildBundles/{id}/relationships/buildBundleFileSizes` | read | |
|
||||||
| **buildUploadFiles** (3) | | | | |
|
| **buildUploadFiles** (3) | | | | |
|
||||||
| `buildUploadFiles_createInstance` | POST | `/v1/buildUploadFiles` | write (dry by default) | lib/xcode |
|
| `buildUploadFiles_createInstance` | POST | `/v1/buildUploadFiles` | write (dry by default) | lib/xcode |
|
||||||
|
|
@ -647,12 +647,12 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `builds_betaBuildUsages_getMetrics` | GET | `/v1/builds/{id}/metrics/betaBuildUsages` | read | |
|
| `builds_betaBuildUsages_getMetrics` | GET | `/v1/builds/{id}/metrics/betaBuildUsages` | read | |
|
||||||
| `builds_betaGroups_createToManyRelationship` | POST | `/v1/builds/{id}/relationships/betaGroups` | write (dry by default) | |
|
| `builds_betaGroups_createToManyRelationship` | POST | `/v1/builds/{id}/relationships/betaGroups` | write (dry by default) | |
|
||||||
| `builds_betaGroups_deleteToManyRelationship` | DELETE | `/v1/builds/{id}/relationships/betaGroups` | owner only (typed confirm) | |
|
| `builds_betaGroups_deleteToManyRelationship` | DELETE | `/v1/builds/{id}/relationships/betaGroups` | owner only (typed confirm) | |
|
||||||
| `builds_buildBetaDetail_getToOneRelated` | GET | `/v1/builds/{id}/buildBetaDetail` | read | |
|
| `builds_buildBetaDetail_getToOneRelated` | GET | `/v1/builds/{id}/buildBetaDetail` | read | apple/testflight |
|
||||||
| `builds_buildBetaDetail_getToOneRelationship` | GET | `/v1/builds/{id}/relationships/buildBetaDetail` | read | |
|
| `builds_buildBetaDetail_getToOneRelationship` | GET | `/v1/builds/{id}/relationships/buildBetaDetail` | read | |
|
||||||
| `builds_diagnosticSignatures_getToManyRelated` | GET | `/v1/builds/{id}/diagnosticSignatures` | read | health |
|
| `builds_diagnosticSignatures_getToManyRelated` | GET | `/v1/builds/{id}/diagnosticSignatures` | read | health |
|
||||||
| `builds_diagnosticSignatures_getToManyRelationship` | GET | `/v1/builds/{id}/relationships/diagnosticSignatures` | read | |
|
| `builds_diagnosticSignatures_getToManyRelationship` | GET | `/v1/builds/{id}/relationships/diagnosticSignatures` | read | |
|
||||||
| `builds_getCollection` | GET | `/v1/builds` | read | apple/build, apple/build-mas, apple/encryption, apple/listing, apple/next-build, apple/resubmit, apple/status, apple/testflight, apple/upload, art, health, lib/store-apps, triage |
|
| `builds_getCollection` | GET | `/v1/builds` | read | apple/encryption, apple/listing, apple/next-build, apple/resubmit, apple/status, apple/testflight, apple/upload, art, health, lib/store-apps, triage |
|
||||||
| `builds_getInstance` | GET | `/v1/builds/{id}` | read | |
|
| `builds_getInstance` | GET | `/v1/builds/{id}` | read | apple/device-families |
|
||||||
| `builds_icons_getToManyRelated` | GET | `/v1/builds/{id}/icons` | read | |
|
| `builds_icons_getToManyRelated` | GET | `/v1/builds/{id}/icons` | read | |
|
||||||
| `builds_icons_getToManyRelationship` | GET | `/v1/builds/{id}/relationships/icons` | read | |
|
| `builds_icons_getToManyRelationship` | GET | `/v1/builds/{id}/relationships/icons` | read | |
|
||||||
| `builds_individualTesters_createToManyRelationship` | POST | `/v1/builds/{id}/relationships/individualTesters` | owner only (typed confirm) | |
|
| `builds_individualTesters_createToManyRelationship` | POST | `/v1/builds/{id}/relationships/individualTesters` | owner only (typed confirm) | |
|
||||||
|
|
@ -1565,9 +1565,9 @@ Specs: Apple [App Store Connect API 4.5.1](https://developer.apple.com/sample-co
|
||||||
| `androidpublisher.appstorecatalog.recentupdateevents.list` | GET | `androidpublisher/v3/appstorecatalog/{appStorePackageName}/recentUpdateEvents` | read | |
|
| `androidpublisher.appstorecatalog.recentupdateevents.list` | GET | `androidpublisher/v3/appstorecatalog/{appStorePackageName}/recentUpdateEvents` | read | |
|
||||||
| **androidpublisher.edits** (5) | | | | |
|
| **androidpublisher.edits** (5) | | | | |
|
||||||
| `androidpublisher.edits.commit` | POST | `androidpublisher/v3/applications/{packageName}/edits/{editId}:commit` | owner only (typed confirm) | play/client |
|
| `androidpublisher.edits.commit` | POST | `androidpublisher/v3/applications/{packageName}/edits/{editId}:commit` | owner only (typed confirm) | play/client |
|
||||||
| `androidpublisher.edits.delete` | DELETE | `androidpublisher/v3/applications/{packageName}/edits/{editId}` | owner only (typed confirm) | apps, onboard, play/client, validate |
|
| `androidpublisher.edits.delete` | DELETE | `androidpublisher/v3/applications/{packageName}/edits/{editId}` | owner only (typed confirm) | apps, onboard, play/client |
|
||||||
| `androidpublisher.edits.get` | GET | `androidpublisher/v3/applications/{packageName}/edits/{editId}` | read | |
|
| `androidpublisher.edits.get` | GET | `androidpublisher/v3/applications/{packageName}/edits/{editId}` | read | |
|
||||||
| `androidpublisher.edits.insert` | POST | `androidpublisher/v3/applications/{packageName}/edits` | write (dry by default) | apps, onboard, play/client, validate |
|
| `androidpublisher.edits.insert` | POST | `androidpublisher/v3/applications/{packageName}/edits` | write (dry by default) | apps, onboard, play/client |
|
||||||
| `androidpublisher.edits.validate` | POST | `androidpublisher/v3/applications/{packageName}/edits/{editId}:validate` | write (dry by default) | play/client |
|
| `androidpublisher.edits.validate` | POST | `androidpublisher/v3/applications/{packageName}/edits/{editId}:validate` | write (dry by default) | play/client |
|
||||||
| **androidpublisher.edits.apks** (3) | | | | |
|
| **androidpublisher.edits.apks** (3) | | | | |
|
||||||
| `androidpublisher.edits.apks.addexternallyhosted` | POST | `androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted` | write (dry by default) | |
|
| `androidpublisher.edits.apks.addexternallyhosted` | POST | `androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted` | write (dry by default) | |
|
||||||
|
|
|
||||||
|
|
@ -87,7 +87,7 @@ run in the background with a log (`storebound shots render > .storebound/render.
|
||||||
| `apple game-center [status]` | API | Game Center from `games`: the app's Game Center detail, the version switch, leaderboards and achievements with localizations (upsert by vendor id, read back; nothing submitted); dry first, asks |
|
| `apple game-center [status]` | API | Game Center from `games`: the app's Game Center detail, the version switch, leaderboards and achievements with localizations (upsert by vendor id, read back; nothing submitted); dry first, asks |
|
||||||
| `games status [--json]` | API, read-only | Game Center and Play Games Services on both stores: capability, entitlement, games_APP_ID, counts vs the config, pending changes, console links |
|
| `games status [--json]` | API, read-only | Game Center and Play Games Services on both stores: capability, entitlement, games_APP_ID, counts vs the config, pending changes, console links |
|
||||||
| `apple encryption` | API | export compliance answer from `apple.usesNonExemptEncryption` (never guessed) |
|
| `apple encryption` | API | export compliance answer from `apple.usesNonExemptEncryption` (never guessed) |
|
||||||
| `apple release --phased on\|pause\|resume\|complete`, `--manual-release` | API | phased release, release an approved version (resume / complete / release ask first) |
|
| `apple release --phased on\|pause\|resume\|complete`, `--manual-release`, `--after-approval \| --manual \| --scheduled <date>` | API | phased release, release an approved version (resume / complete / release ask first), how an unapproved version goes live (`apple.releaseType`; exit 7 when already that type) |
|
||||||
| `apple signing status` | API, read-only | bundle id capabilities, distribution certificates (with / without a private key on this Mac), App Store profiles per bundle id, installed or not |
|
| `apple signing status` | API, read-only | bundle id capabilities, distribution certificates (with / without a private key on this Mac), App Store profiles per bundle id, installed or not |
|
||||||
| `apple signing ensure [--keychain] [--no-install]` | API | missing capabilities, a distribution certificate from a key made here (kept 0600 in `.storebound/signing/`, never printed), App Store profiles installed for Xcode; dry first, asks; Developer ID needs the Account Holder (403 explained) |
|
| `apple signing ensure [--keychain] [--no-install]` | API | missing capabilities, a distribution certificate from a key made here (kept 0600 in `.storebound/signing/`, never printed), App Store profiles installed for Xcode; dry first, asks; Developer ID needs the Account Holder (403 explained) |
|
||||||
| `apple build [--version x.y.z] [--build-number N]` | local + API read | `build.prebuild` first (Capacitor: web build + cap sync; stale copied web assets stop the build), then xcodebuild archive + exportArchive with a generated ExportOptions.plist (app-store-connect, team, signing style, profiles) and the API key; next build number; Capacitor, React Native, Flutter, Unity projects found |
|
| `apple build [--version x.y.z] [--build-number N]` | local + API read | `build.prebuild` first (Capacitor: web build + cap sync; stale copied web assets stop the build), then xcodebuild archive + exportArchive with a generated ExportOptions.plist (app-store-connect, team, signing style, profiles) and the API key; next build number; Capacitor, React Native, Flutter, Unity projects found |
|
||||||
|
|
|
||||||
78
docs/mcp.md
78
docs/mcp.md
|
|
@ -24,6 +24,84 @@ per-request `_meta`, `resultType`, cacheable `tools/list`) and, on the same proc
|
||||||
Manual config for a tool that `install` does not know: command `bunx` with args `["storebound", "mcp"]` (or the
|
Manual config for a tool that `install` does not know: command `bunx` with args `["storebound", "mcp"]` (or the
|
||||||
absolute path of `bin/storebound` plus `mcp`).
|
absolute path of `bin/storebound` plus `mcp`).
|
||||||
|
|
||||||
|
## One shared server over HTTP
|
||||||
|
|
||||||
|
`storebound mcp --http` serves the same tools over Streamable HTTP (MCP 2025-06-18 and later) at `/mcp`, so every
|
||||||
|
agent session of a machine shares one process instead of starting its own. POST carries one JSON-RPC message and gets
|
||||||
|
one JSON answer; there is no server-initiated stream and no session state. A browser Origin other than localhost is
|
||||||
|
refused unless `--allow-origin` names it.
|
||||||
|
|
||||||
|
- Every tool gets a `project` argument: the absolute path of the app folder to run in. It must be inside `--roots`
|
||||||
|
(comma-separated, default the home folder). `--project <dir>` sets a default for calls without one.
|
||||||
|
- `--auth token` (default): the server makes `~/.storebound/mcp-token` (mode 600) on first start and requires it as a
|
||||||
|
bearer token. Only localhost hosts are allowed with it.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
storebound mcp --http --port 7787
|
||||||
|
claude mcp add --transport http storebound http://127.0.0.1:7787/mcp --header "Authorization: Bearer $(cat ~/.storebound/mcp-token)"
|
||||||
|
```
|
||||||
|
- `--auth introspect`: for a server shared over the network behind TLS. Bearer tokens are OAuth 2.0 access tokens from
|
||||||
|
your authorization server, checked through its introspection endpoint (RFC 7662; this server authenticates with the
|
||||||
|
key in `--introspect-key-file`). A token must be active, carry the `mcp` scope and list `--resource` in `aud`
|
||||||
|
(RFC 8707). Without one the answer is 401 with `WWW-Authenticate: Bearer resource_metadata=...`, and
|
||||||
|
`/.well-known/oauth-protected-resource/mcp` names `--issuer` (RFC 9728).
|
||||||
|
|
||||||
|
```bash
|
||||||
|
storebound mcp --http --host 0.0.0.0 --auth introspect --introspect-url https://auth.example.com/introspect \
|
||||||
|
--introspect-key-file ~/.storebound/introspect.key --resource https://mcp.example.com/mcp --issuer https://auth.example.com
|
||||||
|
```
|
||||||
|
- `--read-only`: only the tools that change nothing are listed and callable.
|
||||||
|
- `--broker-profiles a,b`: a host that keeps no key files takes these credential profiles from the credential broker's
|
||||||
|
vault (`GET /api/store-credentials/<profile>/asc-api-key | play-service-account`, a key with the `store-credentials`
|
||||||
|
scope; docs/credential-broker.md). They reach each tool call as `STOREBOUND_PROFILE_<NAME>_*` env, held in memory for
|
||||||
|
10 minutes and never written. A project picks its profile as usual (the config's `account`).
|
||||||
|
- `project` may also be a folder name under the roots (a shared server keeps its checkouts there).
|
||||||
|
- Long calls: a `tools/call` whose request accepts `text/event-stream` is answered as SSE, with a comment line every
|
||||||
|
20 s until the result arrives as one `message` event, so a proxy that cuts silent responses (Cloudflare: 100 s)
|
||||||
|
keeps the connection. Other requests get plain JSON.
|
||||||
|
- Long calls: a `tools/call` whose request accepts `text/event-stream` is answered as SSE, with a comment line every
|
||||||
|
20 s until the result arrives as one `message` event, so a proxy that cuts silent responses (Cloudflare: 100 s)
|
||||||
|
keeps the connection. Other requests get plain JSON.
|
||||||
|
- `/health` answers `{ ok, version }` without auth.
|
||||||
|
|
||||||
|
|
||||||
|
## Public key-less server
|
||||||
|
|
||||||
|
`storebound mcp --http --public [--port 7788] [--host 127.0.0.1] [--rate 60] [--trust-proxy]` is a separate mode for a
|
||||||
|
server anyone may connect to (for example behind a public HTTPS address). No sign-in, no token, no project: it never
|
||||||
|
reads store credentials, project folders or the working directory, never starts a child process and never runs the CLI.
|
||||||
|
It is read-only and keeps no state. The only network call it makes is the public iTunes Search API (`aso_search`).
|
||||||
|
It cannot be combined with `--auth`, `--token-file`, `--roots`, `--project`, `--broker-profiles`, `--allow-origin`
|
||||||
|
or `--read-only`.
|
||||||
|
|
||||||
|
Tools (and only these; the CLI tools of the normal server do not exist here, a call gets "Unknown tool"):
|
||||||
|
|
||||||
|
- `skills_list`: name and one-line description of every skill in the package.
|
||||||
|
- `skill_get {name}`: the full SKILL.md of one skill (`^[a-z0-9-]+$`, must be in the list).
|
||||||
|
- `pitfalls_search {query, store?}`: the sections of the store-pitfalls skill that match the query words, best first (at
|
||||||
|
most 8, each clipped). `store` is `apple` or `play`.
|
||||||
|
- `store_limits {store?}`: listing field character limits, the App Store keyword field rules, screenshot and app
|
||||||
|
preview sizes per device class, Play feature graphic and icon sizes.
|
||||||
|
- `listing_lint {store, fields, locale?}`: storebound's listing and ASO checks on the text you send (limits, keyword
|
||||||
|
field rules, repeated name words, other platforms or apps named, placeholder text, keyword stuffing). Apple fields:
|
||||||
|
`name`, `subtitle`, `keywords`, `promotionalText`, `description`, `whatsNew`. Play fields: `title`,
|
||||||
|
`shortDescription`, `fullDescription`, `whatsNew`. Only the fields you send are judged; nothing is stored.
|
||||||
|
- `aso_search {term, country?, limit?}`: top apps for a term in one storefront from the iTunes Search API (name,
|
||||||
|
developer, id, rating, rating count, genre; 1-25 results, 10 s timeout).
|
||||||
|
|
||||||
|
Limits: `--rate N` requests per minute per client (default 60; over the limit the answer is 429 with `Retry-After`),
|
||||||
|
bodies over 64 KB get 413, every tool input is validated against a closed schema, and output is bounded. Behind a
|
||||||
|
reverse proxy add `--trust-proxy` so the first `X-Forwarded-For` entry is the client; without it that header is
|
||||||
|
ignored. Any browser origin may call it (there is no ambient credential), and CORS preflight is answered. `/health`
|
||||||
|
works as before. Request bodies are not logged.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
storebound mcp --http --public --port 7788 --trust-proxy
|
||||||
|
claude mcp add --transport http storebound-public https://mcp.example.com/mcp
|
||||||
|
```
|
||||||
|
|
||||||
|
For real store work (builds, uploads, listings, releases) use `npx storebound` and its own MCP server.
|
||||||
|
|
||||||
## Desktop machine interface
|
## Desktop machine interface
|
||||||
|
|
||||||
`storebound serve --stdio` is what the desktop app (`apps/desktop`, in progress) runs as its sidecar: newline-delimited
|
`storebound serve --stdio` is what the desktop app (`apps/desktop`, in progress) runs as its sidecar: newline-delimited
|
||||||
|
|
|
||||||
|
|
@ -63,6 +63,7 @@ fails without the fix.
|
||||||
| 27 | 2026-10 | A real Play first release (an agent with a browser tool) found the steps no API does: the App category stayed "Not selected" (`play listing` cannot set it: edits.details has no category field); production had 0 countries (edits.countryAvailability is read-only); App content had ten cards with their own pages; the IARC questionnaire is one long page whose Yes answers reveal follow-ups, with an IARC Terms of Use agreement on page 1 and a final "Save" (not "Submit") on the Summary; Play's material checkboxes, like its radios, ignore native input; long evaluate calls timed out at 45 s; "Send changes for review" ignored a JS click; managed publishing is off by default, so approved means live. | Plans `play-store-settings`, `play-app-content` (+ one per card), `play-production-countries`, `play-production-release`; config `play.category` (Play's lists), `play.countries`, `play.managedPublishing`, `console.contentRating.details`, `console.appContent`, `social`, `products[].randomRewards`; every ask-owner answer in one batch; `check` warns without a category and counts the open App content answers; `validate` reports the category reminder and "production has 0 countries"; `play status` and `play release` say what is console-only; the IARC Terms box is never-press; material checkboxes get the inner [role=checkbox] click (plan and `console fill`); every plan ships `inPageLoop`. `tests/console-play-plans.test.ts`. |
|
| 27 | 2026-10 | A real Play first release (an agent with a browser tool) found the steps no API does: the App category stayed "Not selected" (`play listing` cannot set it: edits.details has no category field); production had 0 countries (edits.countryAvailability is read-only); App content had ten cards with their own pages; the IARC questionnaire is one long page whose Yes answers reveal follow-ups, with an IARC Terms of Use agreement on page 1 and a final "Save" (not "Submit") on the Summary; Play's material checkboxes, like its radios, ignore native input; long evaluate calls timed out at 45 s; "Send changes for review" ignored a JS click; managed publishing is off by default, so approved means live. | Plans `play-store-settings`, `play-app-content` (+ one per card), `play-production-countries`, `play-production-release`; config `play.category` (Play's lists), `play.countries`, `play.managedPublishing`, `console.contentRating.details`, `console.appContent`, `social`, `products[].randomRewards`; every ask-owner answer in one batch; `check` warns without a category and counts the open App content answers; `validate` reports the category reminder and "production has 0 countries"; `play status` and `play release` say what is console-only; the IARC Terms box is never-press; material checkboxes get the inner [role=checkbox] click (plan and `console fill`); every plan ships `inPageLoop`. `tests/console-play-plans.test.ts`. |
|
||||||
| 26 | 2026-10 | An agent using storebound spent hours handing the owner one click, command or answer at a time ("press Next", "download the CSV template", "now run the upload", a compliance question in the middle of a run): skills said "let the owner do it" / "by hand" for navigation, exports and uploads. | The first rule "Do it, don't ask" heads `docs/agents-core.md` (every generated adapter), README and the store-pitfalls skill: the agent does API calls, uploads, builds, exports, console navigation and forms itself; the owner presses only the final public or irreversible buttons and answers the facts no file proves in one batch at the start. `tests/do-it-dont-ask.test.ts` checks the rule is there and fails on skill text that hands navigation, draft saves, exports, uploads or form filling to the owner. |
|
| 26 | 2026-10 | An agent using storebound spent hours handing the owner one click, command or answer at a time ("press Next", "download the CSV template", "now run the upload", a compliance question in the middle of a run): skills said "let the owner do it" / "by hand" for navigation, exports and uploads. | The first rule "Do it, don't ask" heads `docs/agents-core.md` (every generated adapter), README and the store-pitfalls skill: the agent does API calls, uploads, builds, exports, console navigation and forms itself; the owner presses only the final public or irreversible buttons and answers the facts no file proves in one batch at the start. `tests/do-it-dont-ask.test.ts` checks the rule is there and fails on skill text that hands navigation, draft saves, exports, uploads or form filling to the owner. |
|
||||||
| 25 | 2026-10 | In a non-interactive shell `play build` stopped in Gradle with "SDK location not found" (no `ANDROID_HOME` there, `local.properties` gitignored) although the SDK was in `~/Library/Android/sdk`; `apple upload --no-wait --yes` sent the IPA for over 10 minutes without a line (progress every 10th part only, no per-part or per-call timeout). | `resolveAndroidSdk` (ANDROID_HOME, ANDROID_SDK_ROOT, `sdk.dir` in local.properties, the Android Studio default folder; only folders with platforms/ or platform-tools/) hands the SDK to Gradle in the environment, never writes local.properties, stops before Gradle with the places checked; `doctor` shows it (`cli/lib/tools.ts`, `cli/play/build.ts`, `cli/doctor.ts`). `apple upload` prints the size, a line per part and a 20 s heartbeat (api, altool, processing wait), per-part and per-call timeouts, `--timeout` exits 7 with the resume hint (`sendParts` in `cli/apple/upload.ts`, `cli/lib/progress.ts`; `tests/tools-path.test.ts`, `tests/build-sign.test.ts`, `tests/upload-progress.test.ts`). |
|
| 25 | 2026-10 | In a non-interactive shell `play build` stopped in Gradle with "SDK location not found" (no `ANDROID_HOME` there, `local.properties` gitignored) although the SDK was in `~/Library/Android/sdk`; `apple upload --no-wait --yes` sent the IPA for over 10 minutes without a line (progress every 10th part only, no per-part or per-call timeout). | `resolveAndroidSdk` (ANDROID_HOME, ANDROID_SDK_ROOT, `sdk.dir` in local.properties, the Android Studio default folder; only folders with platforms/ or platform-tools/) hands the SDK to Gradle in the environment, never writes local.properties, stops before Gradle with the places checked; `doctor` shows it (`cli/lib/tools.ts`, `cli/play/build.ts`, `cli/doctor.ts`). `apple upload` prints the size, a line per part and a 20 s heartbeat (api, altool, processing wait), per-part and per-call timeouts, `--timeout` exits 7 with the resume hint (`sendParts` in `cli/apple/upload.ts`, `cli/lib/progress.ts`; `tests/tools-path.test.ts`, `tests/build-sign.test.ts`, `tests/upload-progress.test.ts`). |
|
||||||
|
| 25 | 2026-10 | `apple build --out <shared dir>` still used `~/Library/Developer/Xcode/DerivedData`, and the app binary plus the archive's dSYMs / `Symbols/*.symbols` held the home folder, user name and checkout path (543 privacy-gate hits). | `--derived-data` / default `<out>/DerivedData`, `--path-free` (Swift and clang prefix maps) with an archive scan that stops before the export: `cli/lib/path-free.ts`, `tests/path-free.test.ts`; store-pitfalls 124. |
|
||||||
| 24 | 2026-10 | `flow run release --apply --yes` ran `apple upload --no-wait`, which printed "not a terminal: re-run with --yes to confirm" and declined, yet the flow logged "4/13 upload: ok" and went on to `apple testflight wait` for a build that was never uploaded: a declined confirmation exited 0, and the flow's `--yes` never reached the steps. | `confirm()` (`cli/lib/ctx.ts`): every decline (answered no, not a terminal without `--yes`, under serve) prints `declined: <reason>` and exits 3 (`DECLINED_EXIT`). `flow run` reports "step N declined: <reason>" (status `declined`) and stops; `--apply --yes` adds `--yes` to write steps only (`planStep`, `declinedReason`; `tests/flow.test.ts`). |
|
| 24 | 2026-10 | `flow run release --apply --yes` ran `apple upload --no-wait`, which printed "not a terminal: re-run with --yes to confirm" and declined, yet the flow logged "4/13 upload: ok" and went on to `apple testflight wait` for a build that was never uploaded: a declined confirmation exited 0, and the flow's `--yes` never reached the steps. | `confirm()` (`cli/lib/ctx.ts`): every decline (answered no, not a terminal without `--yes`, under serve) prints `declined: <reason>` and exits 3 (`DECLINED_EXIT`). `flow run` reports "step N declined: <reason>" (status `declined`) and stops; `--apply --yes` adds `--yes` to write steps only (`planStep`, `declinedReason`; `tests/flow.test.ts`). |
|
||||||
| 23 | 2026-10 | Capacitor: native build ships old web assets. `flow run release --apply` went straight into `apple build` (xcodebuild archive) with `ios/App/App/public` and `android/app/src/main/assets/public` 3.5 hours older than the latest source commit: the native projects hold the copy `npx cap sync` made last, and nothing ran the web build + cap sync first, so the old game would have shipped. | New `build.prebuild` (per store `apple.prebuild` / `play.prebuild`): `apple build` / `play build` run it first (printed, streamed, nonzero exit stops; `--dry` only prints; `--no-prebuild`; once per `flow run` through `STOREBOUND_PREBUILD_DONE`). After it, a Capacitor project's copied `public/index.html` must be newer than the last commit outside ios/ android/ node_modules/ store/ .storebound/ and `<webDir>/index.html`, else the build stops ("web assets are older than the source ..."; `--allow-stale-web` overrides). `check` warns when stale without a prebuild; build output and dry plan show the bundle's sha256 + mtime. Monorepo (`apps/native` with its own capacitor.config.ts, android/, ios/; `play build` failed with "no Gradle project ... in android or ."): the one Capacitor project one or two levels down is found and named, several ask for `play.build.dir` / `apple.build.*` (`cli/lib/web-assets.ts`, `tests/web-assets.test.ts`). |
|
| 23 | 2026-10 | Capacitor: native build ships old web assets. `flow run release --apply` went straight into `apple build` (xcodebuild archive) with `ios/App/App/public` and `android/app/src/main/assets/public` 3.5 hours older than the latest source commit: the native projects hold the copy `npx cap sync` made last, and nothing ran the web build + cap sync first, so the old game would have shipped. | New `build.prebuild` (per store `apple.prebuild` / `play.prebuild`): `apple build` / `play build` run it first (printed, streamed, nonzero exit stops; `--dry` only prints; `--no-prebuild`; once per `flow run` through `STOREBOUND_PREBUILD_DONE`). After it, a Capacitor project's copied `public/index.html` must be newer than the last commit outside ios/ android/ node_modules/ store/ .storebound/ and `<webDir>/index.html`, else the build stops ("web assets are older than the source ..."; `--allow-stale-web` overrides). `check` warns when stale without a prebuild; build output and dry plan show the bundle's sha256 + mtime. Monorepo (`apps/native` with its own capacitor.config.ts, android/, ios/; `play build` failed with "no Gradle project ... in android or ."): the one Capacitor project one or two levels down is found and named, several ask for `play.build.dir` / `apple.build.*` (`cli/lib/web-assets.ts`, `tests/web-assets.test.ts`). |
|
||||||
| 22 | 2026-10 | `play build` built a good AAB (Capacitor 8 / AGP), then failed its own check with "AAB manifest without package / versionCode". The aapt2 proto manifest was read with element field numbers one too high (name 4, attribute 5, child 6 instead of Resources.proto's 3, 4, 5). The test fixture came from the same wrong encoder, so the tests passed. | `aabInfo` / `encodeProtoManifest` in `cli/lib/gradle.ts` follow Resources.proto. `tests/build-sign.test.ts` builds the manifest bytes by tag, without the encoder, and the parser was checked against real AGP bundles. Lesson: a parser's fixture must not come from the same code's encoder. |
|
| 22 | 2026-10 | `play build` built a good AAB (Capacitor 8 / AGP), then failed its own check with "AAB manifest without package / versionCode". The aapt2 proto manifest was read with element field numbers one too high (name 4, attribute 5, child 6 instead of Resources.proto's 3, 4, 5). The test fixture came from the same wrong encoder, so the tests passed. | `aabInfo` / `encodeProtoManifest` in `cli/lib/gradle.ts` follow Resources.proto. `tests/build-sign.test.ts` builds the manifest bytes by tag, without the encoder, and the parser was checked against real AGP bundles. Lesson: a parser's fixture must not come from the same code's encoder. |
|
||||||
|
|
|
||||||
|
|
@ -82,8 +82,7 @@ languages, every store size, a review gallery and an app preview video. No store
|
||||||
Play takes a YouTube URL in `play.video`.
|
Play takes a YouTube URL in `play.video`.
|
||||||
7. **iPhone Duo (foldable).** `apple.iphoneDuo: true` renders and checks the outer (1398 x 2034) and inner
|
7. **iPhone Duo (foldable).** `apple.iphoneDuo: true` renders and checks the outer (1398 x 2034) and inner
|
||||||
(2007 x 2853) sets. Optional now, reportedly required from April 2027 for iOS 27.1 SDK builds (`check` / `validate`
|
(2007 x 2853) sets. Optional now, reportedly required from April 2027 for iOS 27.1 SDK builds (`check` / `validate`
|
||||||
note it). The API has no Duo display type yet, so `apple screenshots` skips them with a link to the console's
|
note it). `apple screenshots` uploads them through the App Asset Library (display class IPHONE_DUO). Play has no foldable slot: foldables use the 7" / 10" tablet sets.
|
||||||
iPhone Duo tab. Play has no foldable slot: foldables use the 7" / 10" tablet sets.
|
|
||||||
|
|
||||||
Details: the [store-screenshots](../skills/store-screenshots/SKILL.md) and [app-previews](../skills/app-previews/SKILL.md)
|
Details: the [store-screenshots](../skills/store-screenshots/SKILL.md) and [app-previews](../skills/app-previews/SKILL.md)
|
||||||
skills.
|
skills.
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "storebound",
|
"name": "storebound",
|
||||||
"version": "0.8.53",
|
"version": "0.8.78",
|
||||||
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every questionnaire (Data safety, App access and demo accounts, account deletion, IARC, target audience, ads, App Privacy, age rating, export compliance), privacy, icons, screenshots and previews, validate, TestFlight, release management, and after launch: crash vitals, review replies, price sheets, store analytics, Product Page Optimization. Agent Skills plus a Bun CLI and MCP server (storebound); you press Submit. CRTkafa's own toolchain, open-sourced.",
|
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every questionnaire (Data safety, App access and demo accounts, account deletion, IARC, target audience, ads, App Privacy, age rating, export compliance), privacy, icons, screenshots and previews, validate, TestFlight, release management, and after launch: crash vitals, review replies, price sheets, store analytics, Product Page Optimization. Agent Skills plus a Bun CLI and MCP server (storebound); you press Submit. CRTkafa's own toolchain, open-sourced.",
|
||||||
"contextFileName": "GEMINI.md",
|
"contextFileName": "GEMINI.md",
|
||||||
"mcpServers": {
|
"mcpServers": {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "storebound",
|
"name": "storebound",
|
||||||
"version": "0.8.53",
|
"version": "0.8.78",
|
||||||
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every store questionnaire (incl. account deletion and App Review demo accounts), privacy, icons, screenshots and previews, TestFlight. After launch: crash vitals, review replies, price sheets, analytics and Product Page Optimization. One config, a CLI (Node 20+ or Bun), an MCP server and Agent Skills for your AI coding agent.",
|
"description": "Take a mobile app or game from nothing to Submit for review on Google Play and the App Store: app records, listings in every language, in-app products and subscriptions with regional prices, every store questionnaire (incl. account deletion and App Review demo accounts), privacy, icons, screenshots and previews, TestFlight. After launch: crash vitals, review replies, price sheets, analytics and Product Page Optimization. One config, a CLI (Node 20+ or Bun), an MCP server and Agent Skills for your AI coding agent.",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"author": "CRTkafa",
|
"author": "CRTkafa",
|
||||||
|
|
|
||||||
|
|
@ -63,7 +63,12 @@ answers the compliance facts no file proves, all in one batch at the start.
|
||||||
10. **API · Review details.** `storebound apple review-details` (contact from `.storebound/credentials.json`
|
10. **API · Review details.** `storebound apple review-details` (contact from `.storebound/credentials.json`
|
||||||
`reviewContact`, or `--contact-from <Apple ID of another app of the team>`; notes from the config). Apps behind a
|
`reviewContact`, or `--contact-from <Apple ID of another app of the team>`; notes from the config). Apps behind a
|
||||||
sign-in: the demo account from `.storebound/` (`review-access` skill). Apps with accounts: in-app deletion
|
sign-in: the demo account from `.storebound/` (`review-access` skill). Apps with accounts: in-app deletion
|
||||||
(`account-deletion` skill).
|
(`account-deletion` skill). An app with an iOS **and** a macOS version: `--platform macos` (`apple listing`, `apple
|
||||||
|
review-details`) uses `apple.macos.listing` (its own appstore file) and `apple.macos.reviewNotes` when set, else
|
||||||
|
the iOS ones; the Mac app often has no Game Center, IAP or ads, so say so there. `storebound validate --platform
|
||||||
|
macos` warns about iOS-only claims in the Mac texts and notes (Game Center unless `apple.macos.gameCenter: true`,
|
||||||
|
tap / swipe / pinch / touch screen, iPhone / iPad, and IAP lines when `apple.macos.noIap: true`). Not `apple.mac`
|
||||||
|
(that only turns Mac screenshots on).
|
||||||
11. **API · In-app purchases and subscriptions.** `store-iap-setup` and `store-subscriptions` skills. First
|
11. **API · In-app purchases and subscriptions.** `store-iap-setup` and `store-subscriptions` skills. First
|
||||||
IAPs and subscriptions go to review **with** this version: `storebound apple iap-submit --with-version --dry`,
|
IAPs and subscriptions go to review **with** this version: `storebound apple iap-submit --with-version --dry`,
|
||||||
then (after the owner's yes, since it submits) `storebound apple iap-submit --with-version --yes`. On a real first
|
then (after the owner's yes, since it submits) `storebound apple iap-submit --with-version --yes`. On a real first
|
||||||
|
|
@ -76,7 +81,7 @@ answers the compliance facts no file proves, all in one batch at the start.
|
||||||
14. **Submit.** `storebound apple submit --build <n>` (dry run: the plan table with the build you uploaded, by its
|
14. **Submit.** `storebound apple submit --build <n>` (dry run: the plan table with the build you uploaded, by its
|
||||||
number, the version and the ready IAPs in one review submission), then the owner's yes for the same command with
|
number, the version and the ready IAPs in one review submission), then the owner's yes for the same command with
|
||||||
`--yes`; with IAPs `apple iap-submit --with-version --yes` does the same without attaching a build (step 11). In
|
`--yes`; with IAPs `apple iap-submit --with-version --yes` does the same without attaching a build (step 11). In
|
||||||
the desktop app the owner presses Releases > Submit for review (plan, then a system dialog). Release type MANUAL
|
the desktop app the owner presses Releases > Submit for review (plan, then a system dialog). Release type MANUAL (or apple.releaseType: afterApproval | manual | scheduled; `apple release --after-approval | --manual | --scheduled <date>` changes it until the version is approved; for the first version of an app after-approval is the owner's step)
|
||||||
means the owner presses "Release" after approval.
|
means the owner presses "Release" after approval.
|
||||||
15. **Verify + wait.** `storebound apple status`: version WAITING_FOR_REVIEW, IAPs WAITING_FOR_REVIEW, one review
|
15. **Verify + wait.** `storebound apple status`: version WAITING_FOR_REVIEW, IAPs WAITING_FOR_REVIEW, one review
|
||||||
submission. `storebound apple status --wait-review` polls until approved (exit 0) or rejected (exit 1,
|
submission. `storebound apple status --wait-review` polls until approved (exit 0) or rejected (exit 1,
|
||||||
|
|
|
||||||
|
|
@ -64,6 +64,11 @@ when the owner said so for this run). The MCP server offers only `apple_signing_
|
||||||
unlocks that one; `signing ensure --keychain <path>` imports the key + certificate into it). It
|
unlocks that one; `signing ensure --keychain <path>` imports the key + certificate into it). It
|
||||||
also stops before the archive when a target's App Group is missing (manual: its installed profile; automatic: the profile
|
also stops before the archive when a target's App Group is missing (manual: its installed profile; automatic: the profile
|
||||||
the API lists; store-pitfalls 121; `--allow-app-group-gap` overrides).
|
the API lists; store-pitfalls 121; `--allow-app-group-gap` overrides).
|
||||||
|
`--out <dir>` also puts DerivedData in `<out>/DerivedData` (`--derived-data <dir>` / `apple.build.derivedData`
|
||||||
|
overrides), so a build is hermetic per output folder. Building under a shared folder, or anything a privacy gate scans:
|
||||||
|
add `--path-free` (`apple.build.pathFree`): Swift and clang prefix maps keep the home folder, user name and checkout
|
||||||
|
out of the binary and the archive's dSYMs / Symbols, and the build stops before the export on a leftover hit
|
||||||
|
(store-pitfalls 124). `--scan-paths` scans without remapping.
|
||||||
- Capacitor: the archive ships the web assets `npx cap sync` copied last. Set `build.prebuild` (e.g.
|
- Capacitor: the archive ships the web assets `npx cap sync` copied last. Set `build.prebuild` (e.g.
|
||||||
`"npm run build && npx cap sync"`; per store `apple.prebuild` / `play.prebuild`) and `apple build` / `play build`
|
`"npm run build && npx cap sync"`; per store `apple.prebuild` / `play.prebuild`) and `apple build` / `play build`
|
||||||
run it first (once per `flow run`; `--no-prebuild` skips it). Then the copied `public/index.html` must be newer
|
run it first (once per `flow run`; `--no-prebuild` skips it). Then the copied `public/index.html` must be newer
|
||||||
|
|
@ -107,6 +112,13 @@ when the owner said so for this run). The MCP server offers only `apple_signing_
|
||||||
the generated entitlements (app sandbox, application / team identifier, your own keys kept), the embedded profile,
|
the generated entitlements (app sandbox, application / team identifier, your own keys kept), the embedded profile,
|
||||||
hardened runtime and `bundleVersion`. Set `bundle.category` and `bundle.macOS.minimumSystemVersion` in
|
hardened runtime and `bundleVersion`. Set `bundle.category` and `bundle.macOS.minimumSystemVersion` in
|
||||||
tauri.conf.json (the build stops without LSApplicationCategoryType / LSMinimumSystemVersion).
|
tauri.conf.json (the build stops without LSApplicationCategoryType / LSMinimumSystemVersion).
|
||||||
|
A project with a Developer ID and a Mac App Store channel keeps two plists: `--tauri` takes the folder or a
|
||||||
|
`tauri.<name>.conf.json` overlay (merged over tauri.conf.json like Tauri's `--config`, and passed to `tauri build`
|
||||||
|
too; `tauri.appstore.conf.json` / `tauri.mas.conf.json` next to tauri.conf.json is picked up on its own). The
|
||||||
|
entitlements plist comes from `--entitlements <plist>`, else `apple.macos.entitlements`, else the merged
|
||||||
|
`bundle.macOS.entitlements`; the plan shows the source and the final keys. `get-task-allow` and
|
||||||
|
`cs.disable-library-validation` stop the build (App Store Connect refuses them); other hardened-runtime exceptions
|
||||||
|
(`cs.allow-jit`, `cs.allow-unsigned-executable-memory`, `automation.apple-events`...) warn. `--allow-entitlements` builds anyway.
|
||||||
5. Checks of the .app (sandbox, no get-task-allow, profile inside, version / build), `codesign --verify`, then
|
5. Checks of the .app (sandbox, no get-task-allow, profile inside, version / build), `codesign --verify`, then
|
||||||
`productbuild --component <app> /Applications --sign <installer identity>` and `pkgutil --check-signature`.
|
`productbuild --component <app> /Applications --sign <installer identity>` and `pkgutil --check-signature`.
|
||||||
6. `--path-free`: rustc remaps the checkout, CARGO_HOME, RUSTUP_HOME and the home folder, no debug info, symbols stripped;
|
6. `--path-free`: rustc remaps the checkout, CARGO_HOME, RUSTUP_HOME and the home folder, no debug info, symbols stripped;
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ shell after the dry run).
|
||||||
```yaml
|
```yaml
|
||||||
description: Build, upload and check one version on both stores
|
description: Build, upload and check one version on both stores
|
||||||
params:
|
params:
|
||||||
VERSION: "1.0.0" # flow run release VERSION=1.2.0 overrides
|
VERSION: "?" # "?" = required: flow run release VERSION=1.2.0 (no silent default; --resume reuses the last run's)
|
||||||
steps:
|
steps:
|
||||||
- id: next-build
|
- id: next-build
|
||||||
if: apple # apple | play | exists <path> | ${VAR} | !${VAR} | ${A} == x; && joins
|
if: apple # apple | play | exists <path> | ${VAR} | !${VAR} | ${A} == x; && joins
|
||||||
|
|
@ -36,6 +36,10 @@ before: [] # hooks: before / after the steps, onError when a
|
||||||
after: []
|
after: []
|
||||||
onError: []
|
onError: []
|
||||||
```
|
```
|
||||||
|
`${config.testflight.internal}` is filled by the runner with the internal groups of `apple.testflight.groups` (empty when
|
||||||
|
none); the beta template uses it when `GROUP` is empty. The release template has optional steps by param: `MAC_TAURI=<src-tauri>`
|
||||||
|
adds the macOS build + upload, `PLAY_TRACK=beta` uploads to Play open testing (default `internal`); its `promote` step is an
|
||||||
|
owner step listing the Play promotion.
|
||||||
`continueOnError: true` lets a step fail without stopping the flow.
|
`continueOnError: true` lets a step fail without stopping the flow.
|
||||||
A web build before the native builds (Capacitor: `npm run build && npx cap sync`) belongs in `build.prebuild` in the
|
A web build before the native builds (Capacitor: `npm run build && npx cap sync`) belongs in `build.prebuild` in the
|
||||||
config rather than an `sh:` step: `apple build` and `play build` run it themselves, and within one `flow run` it runs
|
config rather than an `sh:` step: `apple build` and `play build` run it themselves, and within one `flow run` it runs
|
||||||
|
|
@ -44,7 +48,8 @@ once (the second build step prints "prebuild skipped (already ran in this flow r
|
||||||
## Modes
|
## Modes
|
||||||
- `flow run release VERSION=1.2.0` (default): read steps (check, validate, scan, release plan, next-build, status ...)
|
- `flow run release VERSION=1.2.0` (default): read steps (check, validate, scan, release plan, next-build, status ...)
|
||||||
run for real; **every write step runs with `--dry`**; wait steps check once; shell steps are skipped. Nothing
|
run for real; **every write step runs with `--dry`**; wait steps check once; shell steps are skipped. Nothing
|
||||||
changes. Show this output to the owner.
|
changes. Show this output to the owner. A dry `apple build` / `play build` writes no IPA / AAB, so the upload after it
|
||||||
|
(and `apple testflight wait` / `distribute` after that) is shown as "planned" instead of failing; a real run is unchanged.
|
||||||
- `--dry`: the plan only, nothing runs.
|
- `--dry`: the plan only, nothing runs.
|
||||||
- `--apply`: writes and shell steps run for real; each write command still asks its own confirmation in the
|
- `--apply`: writes and shell steps run for real; each write command still asks its own confirmation in the
|
||||||
terminal. Never add `--yes` to a step (flow validate refuses it).
|
terminal. Never add `--yes` to a step (flow validate refuses it).
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,12 @@ presses release; you prepare, dry-run and report. `storebound mcp` deliberately
|
||||||
already); the first-ever submission is the owner's (exit 3 `OWNER_STEP`, re-run with `--first-release` after the
|
already); the first-ever submission is the owner's (exit 3 `OWNER_STEP`, re-run with `--first-release` after the
|
||||||
owner's yes). Wait: `storebound apple status --wait-review` (polls with backoff, exit 0 approved, 1 rejected,
|
owner's yes). Wait: `storebound apple status --wait-review` (polls with backoff, exit 0 approved, 1 rejected,
|
||||||
7 timeout; `--timeout 72h`). Rejected: `review-rejections` skill.
|
7 timeout; `--timeout 72h`). Rejected: `review-rejections` skill.
|
||||||
4. Approved = PENDING_DEVELOPER_RELEASE. Release an update yourself: `storebound apple release --manual-release --yes`
|
4. Release type: an update that should go live by itself is `afterApproval`. Set `apple.releaseType: afterApproval` in the
|
||||||
|
config (`apple listing` applies it to a new version, `apple submit` sets it before submitting and its dry run shows
|
||||||
|
`releaseType MANUAL -> AFTER_APPROVAL`), or on one version `storebound apple release --after-approval --yes`
|
||||||
|
(`--manual` / `--scheduled <ISO date>` are the other two; allowed until App Review approves the version, exit 7 when it
|
||||||
|
is that type already; pitfall 125). Without it an approved MANUAL version waits in PENDING_DEVELOPER_RELEASE.
|
||||||
|
Approved = PENDING_DEVELOPER_RELEASE. Release an update yourself: `storebound apple release --manual-release --yes`
|
||||||
(the first-ever release of an app is the owner's: `OWNER_STEP`) or the "Release This Version" button. With phased release on, automatic updates reach 1 %, 2 %, 5 %, 10 %, 20 %,
|
(the first-ever release of an app is the owner's: `OWNER_STEP`) or the "Release This Version" button. With phased release on, automatic updates reach 1 %, 2 %, 5 %, 10 %, 20 %,
|
||||||
50 %, 100 % over 7 days; anyone can still update manually from the store.
|
50 %, 100 % over 7 days; anyone can still update manually from the store.
|
||||||
5. During the rollout watch crashes / reviews. Problem: `storebound apple release --phased pause` (up to 30 days in
|
5. During the rollout watch crashes / reviews. Problem: `storebound apple release --phased pause` (up to 30 days in
|
||||||
|
|
|
||||||
|
|
@ -1533,3 +1533,96 @@ that fails without the fix (see CONTRIBUTING.md).
|
||||||
update-or-first from the config instead of the store.
|
update-or-first from the config instead of the store.
|
||||||
- **Guard:** `cli/lib/release-kind.ts` (the kind from the store, the policy), `tests/update-gate.test.ts` (fake stores:
|
- **Guard:** `cli/lib/release-kind.ts` (the kind from the store, the policy), `tests/update-gate.test.ts` (fake stores:
|
||||||
update goes through, first release is exit 3, already there is exit 7), docs/bypass.md "Updates are agent steps".
|
update goes through, first release is exit 3, already there is exit 7), docs/bypass.md "Updates are agent steps".
|
||||||
|
|
||||||
|
## 124. iOS builds leak the home folder: DerivedData in ~/Library and local paths in the binary and the symbols
|
||||||
|
|
||||||
|
- **Symptom:** a release pipeline building under a shared folder outside the user's home (`apple build --out <dir>`)
|
||||||
|
still wrote DerivedData to `~/Library/Developer/Xcode/DerivedData`, and the app binary and the `.xcarchive`
|
||||||
|
`Symbols/*.symbols` / dSYMs held the home folder, the user name and the checkout path (a privacy gate counted 543 hits).
|
||||||
|
- **Do:** `storebound apple build --out <dir> --path-free` (or `apple.build.pathFree: true`). With `--out` DerivedData is
|
||||||
|
`<out>/DerivedData` (`--derived-data <dir>` / `apple.build.derivedData` to choose); `--path-free` passes Swift
|
||||||
|
`-debug-prefix-map` + `-file-prefix-map` and clang `-ffile-prefix-map` for the home folder, checkout, out and DerivedData,
|
||||||
|
keeps dwarf-with-dsym (symbol upload still works) and scans the archive's Products, dSYMs and Symbols before the export.
|
||||||
|
A hit stops the build with the count and the first file + offsets. Xcode's own toolchain paths (`/Applications/Xcode.app`)
|
||||||
|
are not the user's and are not hits. A prebuilt vendored framework carries its own paths: rebuild it path-free.
|
||||||
|
- **Never:** point a shared build folder at the default DerivedData, or run the privacy scan only after the upload.
|
||||||
|
- **Guard:** `cli/lib/path-free.ts`, `tests/path-free.test.ts`, the hint when `--out` is outside the home folder.
|
||||||
|
|
||||||
|
## 125. Updates sat in Pending Developer Release: the version was created and submitted with release type MANUAL
|
||||||
|
|
||||||
|
- **Symptom:** an approved update did not go live; it waited in PENDING_DEVELOPER_RELEASE because `apple listing` created the
|
||||||
|
version with releaseType MANUAL and `apple submit` never touched it.
|
||||||
|
- **Do:** set `apple.releaseType: afterApproval` (or `manual` / `scheduled` with `apple.earliestReleaseDate`). `apple listing`
|
||||||
|
creates new versions with it, `apple submit` / `apple resubmit` set it on the version before submitting when it differs
|
||||||
|
(the dry run shows `releaseType MANUAL -> AFTER_APPROVAL`). On one version: `storebound apple release --after-approval --yes`
|
||||||
|
(`--manual`, `--scheduled <ISO date>`; `--platform`, `--version`, `--json`; exit 7 when it already has that type). The type
|
||||||
|
is editable until App Review approves the version; an approved one is released with `apple release --manual-release`.
|
||||||
|
Unset: new versions are MANUAL and existing ones are left as they are. Updates are agent steps; `--after-approval` on the
|
||||||
|
first version of an app puts it on sale by itself, so that is the owner's (exit 3 `OWNER_STEP`, `--first-release`).
|
||||||
|
- **Never:** wait for an approval email and then look for the console button, or flip the type back with `apple listing` runs.
|
||||||
|
- **Guard:** `cli/lib/release-type.ts`, `tests/apple-release-gaps.test.ts`.
|
||||||
|
|
||||||
|
## 126. iPhone-only build of an app whose live version runs on iPad: ITMS-90101 after a full archive
|
||||||
|
|
||||||
|
- **Symptom:** `storebound check` passed with `apple.ipad` false; the upload was refused after the archive with ITMS-90101 "This
|
||||||
|
bundle does not support one or more of the devices supported by the previous app version" (TARGETED_DEVICE_FAMILY = 1).
|
||||||
|
- **Do:** `storebound validate` and `apple build` read the live version (READY_FOR_SALE, else the newest that was) from App
|
||||||
|
Store Connect: its build bundle (`deviceProtocols`, device models of `buildBundleFileSizes`) and its screenshot sets
|
||||||
|
(`APP_IPAD_*`); any iPad signal means iPad. They compare it with TARGETED_DEVICE_FAMILY of the Release configuration in the
|
||||||
|
Xcode project and with `apple.ipad`, and stop BEFORE the archive with the fix: `TARGETED_DEVICE_FAMILY = "1,2"` and
|
||||||
|
`apple.ipad: true`. Offline `check` warns when the live families cannot be known. `--allow-device-gap` builds anyway.
|
||||||
|
- **Never:** drop a device family the live version supports, or turn `apple.ipad` off to silence the screenshot check.
|
||||||
|
- **Guard:** `cli/lib/device-families.ts`, `cli/apple/device-families.ts`, `tests/apple-release-gaps.test.ts`. The build bundle
|
||||||
|
attribute names come from Apple's spec; which signal carries the iPad answer live is not recorded, hence the merge.
|
||||||
|
|
||||||
|
## 127. TestFlight invite on a new external group: 409 STATE_ERROR.TESTER_INVITE.NO_INSTALLABLE_BUILDS
|
||||||
|
|
||||||
|
- **Symptom:** `apple testflight testers --group <g> --invite --yes` created the tester but the invitation failed with 409
|
||||||
|
NO_INSTALLABLE_BUILDS: the group had no build past Beta App Review yet.
|
||||||
|
- **Do:** `--invite` first checks that a build of the tester's group is installable (external: BETA_APPROVED / IN_BETA_TESTING;
|
||||||
|
internal: READY_FOR_BETA_TESTING / IN_BETA_TESTING). If not, the tester stays added, no invitation is sent and the run prints
|
||||||
|
"tester added; the invite goes out when a build in <group> passes Beta App Review (re-run with --invite then)", exit 0. The
|
||||||
|
409 itself is treated the same way. `apple testflight distribute --submit-review` prints the line for testers not invited yet.
|
||||||
|
- **Never:** retry the invitation in a loop, or report the added tester as a failure.
|
||||||
|
- **Guard:** `installableBuild` / `noInstallableBuildHint` in `cli/lib/testflight.ts`, `tests/apple-release-gaps.test.ts`.
|
||||||
|
|
||||||
|
## 128. macOS submission of a two-platform app planned the iOS in-app purchases and Game Center
|
||||||
|
|
||||||
|
- **Symptom:** `apple resubmit --platform macos` (and `apple submit`) planned every consumable of the config and a
|
||||||
|
`gameCenterAppVersions` write for a Mac app that sells nothing and has no Game Center.
|
||||||
|
- **Do:** set `apple.macos.noIap: true` and leave `apple.macos.gameCenter` unset; a macOS submission then carries the
|
||||||
|
version and build only, and the dry run names what it left out and why.
|
||||||
|
- **Never:** attach iOS-only products to the Mac submission or switch Game Center on for a Mac app without it.
|
||||||
|
- **Guard:** `macosSubmitSkips` in `cli/lib/config.ts`, `tests/resubmit.test.ts`.
|
||||||
|
|
||||||
|
## 129. Play said "In review" while an old testing build blocked Send changes for review
|
||||||
|
|
||||||
|
- **Symptom:** `play status` showed production as "In review" for days; Publishing overview had "Send changes for
|
||||||
|
review" greyed out. An old build still active on a testing track (alpha) asked for READ_MEDIA_IMAGES /
|
||||||
|
READ_MEDIA_VIDEO ("Use alternative system pickers"); the current production build did not. Play reviews every active
|
||||||
|
build, so the policy issue of the old one held the whole app back. A later commit with `--not-sent-for-review`
|
||||||
|
answered 400 "Changes are sent for review automatically" (managed publishing off).
|
||||||
|
- **Do:** replace each old build: `storebound play release --version-code <production code> --alpha completed` (or
|
||||||
|
`--beta`, `--internal`, `--track <name>`); the changes then go into review by themselves. `play status` and
|
||||||
|
`validate` list every active build below production with that command.
|
||||||
|
- **Never:** read a completed production release that the store page does not show as "In review": the API has no
|
||||||
|
review state, so storebound says "Not live yet: in review or blocked before review".
|
||||||
|
- **Guard:** `cli/play/old-builds.ts` (play status, validate `old-builds`), `PLAY_NOT_LIVE` in `cli/lib/portfolio.ts`,
|
||||||
|
`isAutoSendOnly` in `cli/play/review-pending.ts` (the commit is redone without changesNotSentForReview),
|
||||||
|
`tests/play-old-builds.test.ts`.
|
||||||
|
|
||||||
|
## 130. iPhone Duo screenshots were skipped as "not in the API"
|
||||||
|
|
||||||
|
- **Symptom:** `apple screenshots` skipped the iPhone Duo sets with "the API has no iPhone Duo display type yet".
|
||||||
|
Wrong: ScreenshotDisplayType never gets a Duo value. API 4.5.1 put the display class `IPHONE_DUO` into the App Asset
|
||||||
|
Library (AppAssetLibraryDisplayClass) and deprecated appScreenshotSets / appScreenshots / appPreviewSets /
|
||||||
|
appPreviews in the same release.
|
||||||
|
- **Do:** `storebound apple screenshots` uploads Duo (apple.iphoneDuo, renders iphone-duo-outer/ then
|
||||||
|
iphone-duo-inner/) through the library: `appAssetLibraryRefData` (filter placementTypes APP_SCREENSHOT) gives the
|
||||||
|
iOS placementProfileGroup of IPHONE_DUO, files go up as appAssetLibraryImages (category
|
||||||
|
APP_SCREENSHOTS_AND_PREVIEWS), then appAssetLibraryPlacements (APP_SCREENSHOT, that placementGroup, the version
|
||||||
|
localization). Same MD5 reuse as creative assets; read back.
|
||||||
|
- **Never:** say an API lacks a store feature after checking one enum: search the whole spec (every schema with the
|
||||||
|
feature's name) first.
|
||||||
|
- **Guard:** `cli/apple/duo-library.ts` (duoGroups, syncDuo), `duoDirs` in `cli/apple/screenshots.ts`,
|
||||||
|
`tests/ppo.test.ts`. Previews and the other display classes still use the deprecated sets until they move too.
|
||||||
|
|
|
||||||
|
|
@ -71,10 +71,9 @@ in a plain Android tablet body instead of the iPad one.
|
||||||
outer (1398 x 2034) and an inner (2007 x 2853) set, portrait or landscape, PNG / JPEG without alpha, 1-10 each. It is
|
outer (1398 x 2034) and an inner (2007 x 2853) set, portrait or landscape, PNG / JPEG without alpha, 1-10 each. It is
|
||||||
optional now and reportedly required from April 2027 for builds with the iOS 27.1 SDK or later; `check` / `validate`
|
optional now and reportedly required from April 2027 for builds with the iOS 27.1 SDK or later; `check` / `validate`
|
||||||
print an info note until then (a warning after, never a blocker). `apple.iphoneDuo: true` adds both sizes to
|
print an info note until then (a warning after, never a blocker). `apple.iphoneDuo: true` adds both sizes to
|
||||||
`shots render` / `shots check` / the gallery. The API (4.5.1) has no Duo `ScreenshotDisplayType` yet, so
|
`shots render` / `shots check` / the gallery. ScreenshotDisplayType has no Duo value (and won't get one), so
|
||||||
`apple screenshots` skips the Duo folders with a message and the deep link to the version page; add them in the
|
`apple screenshots` uploads the Duo folders through the App Asset Library (display class IPHONE_DUO, placement
|
||||||
console's iPhone Duo tab until then (one constant, `IPHONE_DUO_DISPLAY` in `cli/shots/spec.ts`, takes the names once
|
APP_SCREENSHOT; pitfall 130). No Duo app preview sizes are published. Google Play has no foldable slot: foldables show the
|
||||||
the enum has them). No Duo app preview sizes are published. Google Play has no foldable slot: foldables show the
|
|
||||||
7" / 10" tablet sets below.
|
7" / 10" tablet sets below.
|
||||||
|
|
||||||
**Mac App Store.** Apple's Screenshot specifications (checked 2026-10-20) list four 16:10 Mac sizes: 1280 x 800,
|
**Mac App Store.** Apple's Screenshot specifications (checked 2026-10-20) list four 16:10 Mac sizes: 1280 x 800,
|
||||||
|
|
@ -83,7 +82,12 @@ the enum has them). No Duo app preview sizes are published. Google Play has no f
|
||||||
alpha) and requires the set, and `apple screenshots --platform macos` uploads it as `APP_DESKTOP` to the macOS
|
alpha) and requires the set, and `apple screenshots --platform macos` uploads it as `APP_DESKTOP` to the macOS
|
||||||
version (versions are per platform, pitfall 79; the iOS run uploads the iOS sets only and says where the Mac set
|
version (versions are per platform, pitfall 79; the iOS run uploads the iOS sets only and says where the Mac set
|
||||||
goes). `validate` prints an info note when the app has a macOS version but no Mac screenshots. Frames: landscape
|
goes). `validate` prints an info note when the app has a macOS version but no Mac screenshots. Frames: landscape
|
||||||
captures in `<frames>/<lang>/landscape/<name>.png`, `shots.landscape.size` CSS px (default 1440 x 900 @2x).
|
captures in `<frames>/<lang>/landscape/<name>.png`, `shots.landscape.size` CSS px (default 1440 x 900 @2x). Make them with
|
||||||
|
`storebound shots capture --device landscape` from a web build (a desktop viewport, no touch, no status bar crop); with
|
||||||
|
`apple.mac`, `play.chromebook` or `shots.landscape.playTablets` the default `capture` run adds the landscape device and
|
||||||
|
captures every shot with no `device` (and `both`) for it too, because render needs a landscape frame per scene; a shot
|
||||||
|
with `device: 'landscape'` is landscape only, `'phone'` / `'tablet'` stays out. `ios-sim` / `android-emu` have no
|
||||||
|
landscape device (skipped with a warning): use a web build or the folder source.
|
||||||
|
|
||||||
**Landscape layout (Mac, Chromebook, Play tablets).** Copy in a column on one side (`shots.landscape.side`, default
|
**Landscape layout (Mac, Chromebook, Play tablets).** Copy in a column on one side (`shots.landscape.side`, default
|
||||||
left), the scene's first frame on the other. `shots.landscape.frame`: `'window'` draws a Mac window (title bar with
|
left), the scene's first frame on the other. `shots.landscape.frame`: `'window'` draws a Mac window (title bar with
|
||||||
|
|
@ -119,6 +123,8 @@ the icon, feature graphic and phone screenshots and prints `tablet screenshots:
|
||||||
`<shots.frames>/<lang>/<phone|tablet>/<shot>.png`, local, not committed.
|
`<shots.frames>/<lang>/<phone|tablet>/<shot>.png`, local, not committed.
|
||||||
- `web` (default): `baseUrl`, `query` with `{lang}`, shots: `path` / `waitFor` / `eval` / `delayMs` / `device`.
|
- `web` (default): `baseUrl`, `query` with `{lang}`, shots: `path` / `waitFor` / `eval` / `delayMs` / `device`.
|
||||||
Phone 440 x 902 @3x and tablet 800 x 1240 @2x by default; the template draws the status bar above.
|
Phone 440 x 902 @3x and tablet 800 x 1240 @2x by default; the template draws the status bar above.
|
||||||
|
Landscape (Mac / Chromebook): `--device landscape` or `device: 'landscape'` per shot, a desktop viewport at
|
||||||
|
`shots.landscape.size` (default 1440 x 900 @2x), `waitSelector` / `click` take a `landscape` list too.
|
||||||
Speed (many languages): frames run in parallel browser contexts (`--concurrency N`, `capture.concurrency`;
|
Speed (many languages): frames run in parallel browser contexts (`--concurrency N`, `capture.concurrency`;
|
||||||
default min(3, cores / 4) since game boots are GPU-heavy). `capture.session: 'per-language'` boots the app once
|
default min(3, cores / 4) since game boots are GPU-heavy). `capture.session: 'per-language'` boots the app once
|
||||||
per language and device and switches shots in that page (per shot `navigate: 'spa'` = pushState + popstate to its
|
per language and device and switches shots in that page (per shot `navigate: 'spa'` = pushState + popstate to its
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,10 @@ changes or deletes a group.
|
||||||
commits; storebound masks them in every log line (`j***@example.com`).
|
commits; storebound masks them in every log line (`j***@example.com`).
|
||||||
- `storebound apple testflight testers --dry` shows: new testers, testers added to more groups, (with `--remove`)
|
- `storebound apple testflight testers --dry` shows: new testers, testers added to more groups, (with `--remove`)
|
||||||
testers who leave a managed group. The real run **asks first**: Apple emails each new tester an invitation once the
|
testers who leave a managed group. The real run **asks first**: Apple emails each new tester an invitation once the
|
||||||
group has a build. `--invite` (re)sends invitations to testers still `NOT_INVITED` / `INVITED` (asks again).
|
group has a build. `--invite` (re)sends invitations to testers still `NOT_INVITED` / `INVITED` (asks again) once a build of the tester's group is
|
||||||
|
installable (an external group: past Beta App Review). Without one the tester is added, the invite is skipped and the run
|
||||||
|
says "tester added; the invite goes out when a build in <group> passes Beta App Review (re-run with --invite then)" (exit 0;
|
||||||
|
Apple's 409 `NO_INSTALLABLE_BUILDS` is handled the same way; `distribute --submit-review` prints the same line; pitfall 127).
|
||||||
- Internal groups only take App Store Connect users (Users and Access); add people there first.
|
- Internal groups only take App Store Connect users (Users and Access); add people there first.
|
||||||
- Testers are an owner action: not an MCP tool. An agent prepares the CSV format and the dry run, the owner runs it.
|
- Testers are an owner action: not an MCP tool. An agent prepares the CSV format and the dry run, the owner runs it.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -51,6 +51,7 @@ const config: ShipConfig = {
|
||||||
// usesNonExemptEncryption: false,
|
// usesNonExemptEncryption: false,
|
||||||
// ipad: true, // the app runs on iPad: 13" iPad screenshots (2064 x 2752, ipad13) are rendered, checked and uploaded
|
// ipad: true, // the app runs on iPad: 13" iPad screenshots (2064 x 2752, ipad13) are rendered, checked and uploaded
|
||||||
// iphoneMedium: true, // optional 6.3" iPhone set (1206 x 2622, iphone-medium); off: Apple scales the 6.5" set down
|
// iphoneMedium: true, // optional 6.3" iPhone set (1206 x 2622, iphone-medium); off: Apple scales the 6.5" set down
|
||||||
|
// releaseType: "afterApproval", // afterApproval | manual | scheduled (+ earliestReleaseDate): how an approved version goes live; unset = new versions MANUAL
|
||||||
// iphoneDuo: true, // optional iPhone Duo (foldable) sets, outer 1398 x 2034 + inner 2007 x 2853; rendered and checked, not uploaded until the API takes them
|
// iphoneDuo: true, // optional iPhone Duo (foldable) sets, outer 1398 x 2034 + inner 2007 x 2853; rendered and checked, not uploaded until the API takes them
|
||||||
// screenshotTypes: ['APP_IPHONE_61'], // what `storebound validate` requires per locale (default: medium display, met by a 6.9" or 6.5" set; + APP_IPAD_PRO_3GEN_129 with ipad)
|
// screenshotTypes: ['APP_IPHONE_61'], // what `storebound validate` requires per locale (default: medium display, met by a 6.9" or 6.5" set; + APP_IPAD_PRO_3GEN_129 with ipad)
|
||||||
// TestFlight (`storebound apple testflight`, testflight skill). Tester emails live in .storebound/testers.csv only.
|
// TestFlight (`storebound apple testflight`, testflight skill). Tester emails live in .storebound/testers.csv only.
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,11 @@
|
||||||
# storebound flow "beta" for a game: a playtest build on TestFlight and Play internal testing.
|
# storebound flow "beta" for a game: a playtest build on TestFlight and Play internal testing.
|
||||||
# storebound flow run beta VERSION=1.2.0 [--apply]
|
# storebound flow run beta VERSION=1.2.0 [--apply]
|
||||||
|
# VERSION is required ("?"). GROUP empty = the internal group of apple.testflight.groups (the group `internal: true`);
|
||||||
|
# GROUP=<name> picks a TestFlight group that exists (or is listed in apple.testflight.groups).
|
||||||
description: Next game build to TestFlight and Play internal testing
|
description: Next game build to TestFlight and Play internal testing
|
||||||
params:
|
params:
|
||||||
VERSION: "1.0.0"
|
VERSION: "?"
|
||||||
GROUP: "Playtesters"
|
GROUP: ""
|
||||||
steps:
|
steps:
|
||||||
- id: check
|
- id: check
|
||||||
run: check
|
run: check
|
||||||
|
|
@ -25,8 +27,14 @@ steps:
|
||||||
if: apple
|
if: apple
|
||||||
run: apple testflight wait --build ${BUILD} --version ${VERSION}
|
run: apple testflight wait --build ${BUILD} --version ${VERSION}
|
||||||
- id: distribute
|
- id: distribute
|
||||||
if: apple
|
if: apple && ${GROUP}
|
||||||
run: apple testflight distribute --build ${BUILD} --group ${GROUP}
|
run: apple testflight distribute --build ${BUILD} --group ${GROUP}
|
||||||
|
- id: distribute-internal
|
||||||
|
if: apple && !${GROUP} && ${config.testflight.internal}
|
||||||
|
run: apple testflight distribute --build ${BUILD} --group ${config.testflight.internal}
|
||||||
|
- id: no-group
|
||||||
|
if: apple && !${GROUP} && !${config.testflight.internal}
|
||||||
|
owner: "No TestFlight group: pass GROUP=<name> or add a group with internal: true to apple.testflight.groups, then storebound apple testflight distribute --build ${BUILD} --group <name>"
|
||||||
- id: play-build
|
- id: play-build
|
||||||
if: play
|
if: play
|
||||||
run: play build --version-name ${VERSION}
|
run: play build --version-name ${VERSION}
|
||||||
|
|
|
||||||
|
|
@ -3,10 +3,13 @@
|
||||||
# storebound flow run release VERSION=1.2.0 --apply writes run for real; each command still asks you first
|
# storebound flow run release VERSION=1.2.0 --apply writes run for real; each command still asks you first
|
||||||
# storebound flow run release --resume --apply continue after fixing a failed step
|
# storebound flow run release --resume --apply continue after fixing a failed step
|
||||||
# Steps are storebound commands (no "storebound" prefix). `if: apple` / `if: play` skip a store the config does not
|
# Steps are storebound commands (no "storebound" prefix). `if: apple` / `if: play` skip a store the config does not
|
||||||
# have; `owner:` steps are never run, they list what you click. `sh:` runs your own build command (only with --apply).
|
# have; `if: ${PARAM}` turns an optional step on by a param (MAC_TAURI=<src-tauri> adds the macOS build, PLAY_TRACK=beta
|
||||||
|
# uploads to Play open testing); VERSION is required; `owner:` steps are never run, they list what you click. `sh:` runs your own build command (only with --apply).
|
||||||
description: Build, upload and check one game version on both stores, then your Submit click
|
description: Build, upload and check one game version on both stores, then your Submit click
|
||||||
params:
|
params:
|
||||||
VERSION: "1.0.0"
|
VERSION: "?"
|
||||||
|
MAC_TAURI: ""
|
||||||
|
PLAY_TRACK: "internal"
|
||||||
steps:
|
steps:
|
||||||
- id: shots
|
- id: shots
|
||||||
if: exists store/renders
|
if: exists store/renders
|
||||||
|
|
@ -24,12 +27,21 @@ steps:
|
||||||
- id: wait
|
- id: wait
|
||||||
if: apple
|
if: apple
|
||||||
run: apple testflight wait --build ${BUILD} --version ${VERSION}
|
run: apple testflight wait --build ${BUILD} --version ${VERSION}
|
||||||
|
- id: mac-build
|
||||||
|
if: apple && ${MAC_TAURI}
|
||||||
|
run: apple build --platform macos --tauri ${MAC_TAURI} --version ${VERSION} --build-number ${BUILD}
|
||||||
|
- id: mac-upload
|
||||||
|
if: apple && ${MAC_TAURI}
|
||||||
|
run: apple upload --platform macos --no-wait --allow-existing
|
||||||
- id: play-build
|
- id: play-build
|
||||||
if: play
|
if: play
|
||||||
run: play build --version-name ${VERSION}
|
run: play build --version-name ${VERSION}
|
||||||
- id: play-upload
|
- id: play-upload
|
||||||
if: play
|
if: play
|
||||||
run: play upload --track internal
|
run: play upload --track ${PLAY_TRACK}
|
||||||
|
- id: promote
|
||||||
|
if: play && ${PLAY_TRACK} != production
|
||||||
|
owner: "Play Console: promote the ${PLAY_TRACK} release to production (storebound play release --version-code <code> --production completed once you agree)"
|
||||||
- id: whats-new
|
- id: whats-new
|
||||||
if: exists store/whats-new
|
if: exists store/whats-new
|
||||||
run: whats-new apply
|
run: whats-new apply
|
||||||
|
|
@ -43,4 +55,4 @@ steps:
|
||||||
- id: plan
|
- id: plan
|
||||||
run: release plan ${VERSION}
|
run: release plan ${VERSION}
|
||||||
- id: submit
|
- id: submit
|
||||||
owner: "App Store Connect: Submit for Review (version ${VERSION}, build ${BUILD}). Play Console: promote the internal release and Send changes for review"
|
owner: "App Store Connect: Submit for Review (version ${VERSION}, build ${BUILD}). Play Console: promote the ${PLAY_TRACK} release and Send changes for review"
|
||||||
|
|
|
||||||
409
tests/apple-release-gaps.test.ts
Normal file
409
tests/apple-release-gaps.test.ts
Normal file
|
|
@ -0,0 +1,409 @@
|
||||||
|
// Three gaps found in real use, against the stateful App Store Connect double (tests/helpers/fake-stores.ts):
|
||||||
|
// 1. release type: updates sat in Pending Developer Release because versions were created / submitted as MANUAL
|
||||||
|
// (apple.releaseType, apple submit, apple release --after-approval | --manual)
|
||||||
|
// 2. device families: an iPhone-only build of an app whose live version runs on iPad is refused AFTER the archive (ITMS-90101)
|
||||||
|
// 3. TestFlight: inviting a tester of a group without an installable build is 409 NO_INSTALLABLE_BUILDS
|
||||||
|
import { afterAll, afterEach, beforeAll, beforeEach, describe, expect, setDefaultTimeout, test } from 'bun:test';
|
||||||
|
import { parseArgs } from '../cli/lib/args';
|
||||||
|
import { runShipStep } from '../cli/lib/ship-step';
|
||||||
|
import { run as appleSubmit } from '../cli/apple/submit';
|
||||||
|
import { run as appleRelease } from '../cli/apple/release';
|
||||||
|
import { run as appleTestflight } from '../cli/apple/testflight';
|
||||||
|
import { run as appleBuild } from '../cli/apple/build';
|
||||||
|
import { validateConfig } from '../cli/lib/config';
|
||||||
|
import { planVersion } from '../cli/lib/listing-plan';
|
||||||
|
import { releaseTypeChanges, validateReleaseType, wantedRelease } from '../cli/lib/release-type';
|
||||||
|
import { familyVerdicts, liveFamilies, pbxFamilies, projectFamilies } from '../cli/lib/device-families';
|
||||||
|
import { liveDeviceFamilies } from '../cli/apple/device-families';
|
||||||
|
import { appleRules } from '../cli/lib/validate-rules';
|
||||||
|
import { installableBuild, noInstallableBuildHint, noInstallableBuilds409 } from '../cli/lib/testflight';
|
||||||
|
import { ascEnv, BASE, capture, project, restore } from './helpers/store-mock';
|
||||||
|
import { installStores, type Stores, uninstallStores, writes } from './helpers/fake-stores';
|
||||||
|
|
||||||
|
const APP = '6400000101';
|
||||||
|
|
||||||
|
/** Runs a ship step in-process with stdout / stderr captured. */
|
||||||
|
async function ship(key: string, argv: string[], body: (a: ReturnType<typeof parseArgs>) => Promise<void>): Promise<{ code: number; out: string; err: string }> {
|
||||||
|
const out: string[] = [], err: string[] = [];
|
||||||
|
const o = process.stdout.write, e = process.stderr.write, cl = console.log, ce = console.error, cw = console.warn, ci = console.info;
|
||||||
|
process.stdout.write = ((s: string | Uint8Array) => { out.push(typeof s === 'string' ? s : new TextDecoder().decode(s)); return true; }) as typeof process.stdout.write;
|
||||||
|
process.stderr.write = ((s: string | Uint8Array) => { err.push(typeof s === 'string' ? s : new TextDecoder().decode(s)); return true; }) as typeof process.stderr.write;
|
||||||
|
console.log = (...a: unknown[]) => { out.push(a.map(String).join(' ') + '\n'); };
|
||||||
|
console.info = console.log;
|
||||||
|
console.error = (...a: unknown[]) => { err.push(a.map(String).join(' ') + '\n'); };
|
||||||
|
console.warn = console.error;
|
||||||
|
try {
|
||||||
|
const code = await runShipStep(key, argv, parseArgs, async a => {
|
||||||
|
const keep = console.log;
|
||||||
|
if (a.has('json')) console.log = (...x: unknown[]) => console.error(...x);
|
||||||
|
try { await body(a); } finally { console.log = keep; }
|
||||||
|
});
|
||||||
|
return { code, out: out.join(''), err: err.join('') };
|
||||||
|
} finally { process.stdout.write = o; process.stderr.write = e; console.log = cl; console.error = ce; console.warn = cw; console.info = ci; }
|
||||||
|
}
|
||||||
|
|
||||||
|
// ------------------------------------------------------------------------------------------------ 1. release type
|
||||||
|
|
||||||
|
describe('release type (pure)', () => {
|
||||||
|
test('config: afterApproval | manual | scheduled (+ date); scheduled needs the date, the date needs scheduled', () => {
|
||||||
|
expect(validateReleaseType({ releaseType: 'afterApproval' })).toEqual([]);
|
||||||
|
expect(validateReleaseType({ releaseType: 'scheduled', earliestReleaseDate: '2027-03-01T09:00:00Z' })).toEqual([]);
|
||||||
|
expect(validateReleaseType({ releaseType: 'soon' }).join()).toContain('afterApproval | manual | scheduled');
|
||||||
|
expect(validateReleaseType({ releaseType: 'scheduled' }).join()).toContain('earliestReleaseDate is required');
|
||||||
|
expect(validateReleaseType({ releaseType: 'manual', earliestReleaseDate: '2027-03-01T09:00:00Z' }).join()).toContain('only with apple.releaseType "scheduled"');
|
||||||
|
expect(validateReleaseType({ releaseType: 'scheduled', earliestReleaseDate: 'tomorrow' }).join()).toContain('ISO 8601');
|
||||||
|
expect(validateConfig({ ...BASE, apple: { ...BASE.apple!, releaseType: 'later' as never } }).join()).toContain('apple.releaseType');
|
||||||
|
expect(wantedRelease({})).toBeNull();
|
||||||
|
expect(wantedRelease({ releaseType: 'afterApproval' })).toEqual({ releaseType: 'AFTER_APPROVAL' });
|
||||||
|
});
|
||||||
|
test('changes are old -> new; the same instant is not a change', () => {
|
||||||
|
expect(releaseTypeChanges({ releaseType: 'MANUAL' }, { releaseType: 'AFTER_APPROVAL' })).toEqual([{ field: 'releaseType', from: 'MANUAL', to: 'AFTER_APPROVAL' }]);
|
||||||
|
expect(releaseTypeChanges({ releaseType: 'AFTER_APPROVAL' }, { releaseType: 'AFTER_APPROVAL' })).toEqual([]);
|
||||||
|
expect(releaseTypeChanges({ releaseType: 'SCHEDULED', earliestReleaseDate: '2027-03-01T09:00:00+00:00' }, { releaseType: 'SCHEDULED', earliestReleaseDate: '2027-03-01T09:00:00Z' })).toEqual([]);
|
||||||
|
expect(releaseTypeChanges({ releaseType: 'MANUAL' }, { releaseType: 'SCHEDULED', earliestReleaseDate: '2027-03-01T09:00:00Z' }).map(c => c.field)).toEqual(['releaseType', 'earliestReleaseDate']);
|
||||||
|
});
|
||||||
|
test('apple listing: a new version takes the configured type (MANUAL when unset); an existing one keeps its own unless asked', () => {
|
||||||
|
const rows = [{ id: 'v1', attributes: { versionString: '1.0.0', appVersionState: 'READY_FOR_SALE', platform: 'IOS' } }];
|
||||||
|
expect(planVersion(rows, '1.1.0', { copyright: 'c' }).attributes.releaseType).toBe('MANUAL');
|
||||||
|
expect(planVersion(rows, '1.1.0', { copyright: 'c', releaseType: 'AFTER_APPROVAL' }).attributes.releaseType).toBe('AFTER_APPROVAL');
|
||||||
|
const sched = planVersion(rows, '1.1.0', { copyright: 'c', releaseType: 'SCHEDULED', earliestReleaseDate: '2027-03-01T09:00:00Z' });
|
||||||
|
expect(sched.attributes).toMatchObject({ releaseType: 'SCHEDULED', earliestReleaseDate: '2027-03-01T09:00:00Z' });
|
||||||
|
const editable = [...rows, { id: 'v2', attributes: { versionString: '1.1.0', appVersionState: 'PREPARE_FOR_SUBMISSION', platform: 'IOS', copyright: 'c', releaseType: 'AFTER_APPROVAL' } }];
|
||||||
|
expect(planVersion(editable, '1.1.0', { copyright: 'c' }).action).toBe('keep');
|
||||||
|
expect(planVersion(editable, '1.1.0', { copyright: 'c', releaseType: 'MANUAL' }).changes).toEqual([{ field: 'releaseType', from: 'AFTER_APPROVAL', to: 'MANUAL' }]);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
describe('release type (fake App Store Connect)', () => {
|
||||||
|
setDefaultTimeout(30_000);
|
||||||
|
let s: Stores;
|
||||||
|
beforeAll(() => { ascEnv(); });
|
||||||
|
afterAll(restore);
|
||||||
|
beforeEach(() => { s = installStores(); });
|
||||||
|
afterEach(() => { uninstallStores(); });
|
||||||
|
const version = (id: string, v: string, state: string, releaseType = 'MANUAL'): void => { s.asc.put({ type: 'appStoreVersions', id, attributes: { versionString: v, appVersionState: state, platform: 'IOS', releaseType }, rels: { app: APP } }); };
|
||||||
|
const build = (): void => { s.asc.put({ type: 'builds', id: 'b-8', attributes: { version: '8', processingState: 'VALID', usesNonExemptEncryption: false }, rels: { app: APP } }); };
|
||||||
|
const typeOf = (id: string): unknown => s.asc.all('appStoreVersions').find(v => v.id === id)!.attributes.releaseType;
|
||||||
|
const cfg = (releaseType: 'afterApproval' | 'manual') => ({ ...BASE, apple: { ...BASE.apple!, releaseType } });
|
||||||
|
|
||||||
|
test('apple submit with apple.releaseType: the dry run shows old -> new, the real run sets it BEFORE the submit, the re-run is exit 7', async () => {
|
||||||
|
version('ver-0', '1.0.0', 'READY_FOR_SALE');
|
||||||
|
version('ver-1', '1.1.0', 'PREPARE_FOR_SUBMISSION');
|
||||||
|
build();
|
||||||
|
const p = project(cfg('afterApproval'));
|
||||||
|
const dry = await ship('apple submit', ['--json', '--build', '8'], a => appleSubmit({ loaded: p.loaded, args: a }));
|
||||||
|
expect(dry.code).toBe(0);
|
||||||
|
expect(JSON.parse(dry.out).releaseType).toEqual({ changes: [{ field: 'releaseType', from: 'MANUAL', to: 'AFTER_APPROVAL' }] });
|
||||||
|
expect(typeOf('ver-1')).toBe('MANUAL');
|
||||||
|
expect(writes(s.calls)).toEqual([]);
|
||||||
|
const r = await ship('apple submit', ['--json', '--yes', '--build', '8'], a => appleSubmit({ loaded: p.loaded, args: a }));
|
||||||
|
expect(r.err).not.toContain('error:');
|
||||||
|
expect(r.code).toBe(0);
|
||||||
|
expect(r.err).toContain('release type of 1.1.0: releaseType MANUAL -> AFTER_APPROVAL');
|
||||||
|
expect(typeOf('ver-1')).toBe('AFTER_APPROVAL');
|
||||||
|
const w = writes(s.calls).map(c => `${c.method} ${c.path}`);
|
||||||
|
expect(w.indexOf('PATCH /v1/appStoreVersions/ver-1')).toBeGreaterThanOrEqual(0);
|
||||||
|
expect(w.indexOf('PATCH /v1/appStoreVersions/ver-1')).toBeLessThan(w.findIndex(x => /^PATCH \/v1\/reviewSubmissions\//.test(x)));
|
||||||
|
const again = await ship('apple submit', ['--json', '--yes', '--build', '8'], a => appleSubmit({ loaded: p.loaded, args: a }));
|
||||||
|
expect(again.code).toBe(7);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('apple submit without apple.releaseType leaves the version\'s release type alone', async () => {
|
||||||
|
version('ver-0', '1.0.0', 'READY_FOR_SALE');
|
||||||
|
version('ver-1', '1.1.0', 'PREPARE_FOR_SUBMISSION');
|
||||||
|
build();
|
||||||
|
const p = project(BASE);
|
||||||
|
const r = await ship('apple submit', ['--json', '--yes', '--build', '8'], a => appleSubmit({ loaded: p.loaded, args: a }));
|
||||||
|
expect(r.code).toBe(0);
|
||||||
|
expect(typeOf('ver-1')).toBe('MANUAL');
|
||||||
|
expect(writes(s.calls).some(c => c.path === '/v1/appStoreVersions/ver-1')).toBe(false);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('apple release --after-approval --yes on an update: set, then exit 7 when it is that type; --manual puts it back', async () => {
|
||||||
|
version('ver-0', '1.0.0', 'READY_FOR_SALE');
|
||||||
|
version('ver-1', '1.1.0', 'WAITING_FOR_REVIEW');
|
||||||
|
const p = project(BASE);
|
||||||
|
const run = (argv: string[]) => ship('apple release', ['--json', '--yes', ...argv], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
const r = await run(['--after-approval', '--version', '1.1.0']);
|
||||||
|
expect(r.err).not.toContain('error:');
|
||||||
|
expect(r.code).toBe(0);
|
||||||
|
expect(JSON.parse(r.out)).toMatchObject({ ok: true, step: 'release', version: '1.1.0', releaseType: 'AFTER_APPROVAL', from: 'MANUAL', changed: true, releaseKind: 'update' });
|
||||||
|
expect(writes(s.calls).map(c => `${c.method} ${c.path}`)).toEqual(['PATCH /v1/appStoreVersions/ver-1']);
|
||||||
|
expect(typeOf('ver-1')).toBe('AFTER_APPROVAL');
|
||||||
|
const n = s.calls.length;
|
||||||
|
const again = await run(['--after-approval']);
|
||||||
|
expect(again.code).toBe(7);
|
||||||
|
expect(JSON.parse(again.out)).toMatchObject({ ok: true, alreadyThere: true });
|
||||||
|
expect(writes(s.calls.slice(n))).toEqual([]);
|
||||||
|
const back = await run(['--manual', '--version', '1.1.0']);
|
||||||
|
expect(back.code).toBe(0);
|
||||||
|
expect(typeOf('ver-1')).toBe('MANUAL');
|
||||||
|
});
|
||||||
|
|
||||||
|
test('apple release --after-approval --dry changes nothing; --scheduled sets the date; two type flags are a usage error', async () => {
|
||||||
|
version('ver-0', '1.0.0', 'READY_FOR_SALE');
|
||||||
|
version('ver-1', '1.1.0', 'PREPARE_FOR_SUBMISSION');
|
||||||
|
const p = project(BASE);
|
||||||
|
const dry = await ship('apple release', ['--json', '--after-approval', '--dry'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(dry.code).toBe(0);
|
||||||
|
expect(JSON.parse(dry.out)).toMatchObject({ dryRun: true, changes: [{ field: 'releaseType', from: 'MANUAL', to: 'AFTER_APPROVAL' }] });
|
||||||
|
expect(writes(s.calls)).toEqual([]);
|
||||||
|
const sch = await ship('apple release', ['--json', '--yes', '--scheduled', '2027-03-01T09:00:00Z'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(sch.code).toBe(0);
|
||||||
|
expect(s.asc.all('appStoreVersions').find(v => v.id === 'ver-1')!.attributes).toMatchObject({ releaseType: 'SCHEDULED', earliestReleaseDate: '2027-03-01T09:00:00Z' });
|
||||||
|
const both = await ship('apple release', ['--json', '--yes', '--manual', '--after-approval'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(both.code).not.toBe(0);
|
||||||
|
expect(both.err).toContain('alternatives');
|
||||||
|
});
|
||||||
|
|
||||||
|
test('an approved version (Pending Developer Release) is refused with the way out; a released one too', async () => {
|
||||||
|
version('ver-0', '1.0.0', 'READY_FOR_SALE');
|
||||||
|
version('ver-1', '1.1.0', 'PENDING_DEVELOPER_RELEASE');
|
||||||
|
const p = project(BASE);
|
||||||
|
const r = await ship('apple release', ['--json', '--yes', '--after-approval', '--version', '1.1.0'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(r.code).not.toBe(0);
|
||||||
|
expect(r.err).toContain('apple release --manual-release --version 1.1.0');
|
||||||
|
expect(writes(s.calls)).toEqual([]);
|
||||||
|
// already MANUAL and asked for MANUAL: nothing to do even in that state
|
||||||
|
const same = await ship('apple release', ['--json', '--yes', '--manual', '--version', '1.1.0'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(same.code).toBe(7);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('--after-approval on the first version of an app is the owner\'s step (exit 3 OWNER_STEP) unless --first-release', async () => {
|
||||||
|
version('ver-1', '1.0.0', 'PREPARE_FOR_SUBMISSION');
|
||||||
|
const p = project(BASE);
|
||||||
|
const r = await ship('apple release', ['--json', '--yes', '--after-approval'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(r.code).toBe(3);
|
||||||
|
expect(JSON.parse(r.out)).toMatchObject({ ok: false, error: { code: 'OWNER_STEP' } });
|
||||||
|
expect(writes(s.calls)).toEqual([]);
|
||||||
|
const manual = await ship('apple release', ['--json', '--yes', '--manual'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(manual.code).toBe(7);
|
||||||
|
const ok = await ship('apple release', ['--json', '--yes', '--after-approval', '--first-release'], a => appleRelease({ loaded: p.loaded, args: a }));
|
||||||
|
expect(ok.code).toBe(0);
|
||||||
|
expect(typeOf('ver-1')).toBe('AFTER_APPROVAL');
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
// ------------------------------------------------------------------------------------------------ 2. device families
|
||||||
|
|
||||||
|
const PBX = (family: string, bundle = 'com.example.notes'): string => `// !$*UTF8*$!
|
||||||
|
{
|
||||||
|
objects = {
|
||||||
|
/* Begin XCBuildConfiguration section */
|
||||||
|
AA01 /* Debug */ = {
|
||||||
|
isa = XCBuildConfiguration;
|
||||||
|
buildSettings = {
|
||||||
|
PRODUCT_BUNDLE_IDENTIFIER = ${bundle};
|
||||||
|
TARGETED_DEVICE_FAMILY = "1,2";
|
||||||
|
};
|
||||||
|
name = Debug;
|
||||||
|
};
|
||||||
|
AA02 /* Release */ = {
|
||||||
|
isa = XCBuildConfiguration;
|
||||||
|
baseConfigurationReference = ZZ01;
|
||||||
|
buildSettings = {
|
||||||
|
PRODUCT_BUNDLE_IDENTIFIER = ${bundle};
|
||||||
|
TARGETED_DEVICE_FAMILY = ${family};
|
||||||
|
};
|
||||||
|
name = Release;
|
||||||
|
};
|
||||||
|
AA03 /* Release */ = {
|
||||||
|
isa = XCBuildConfiguration;
|
||||||
|
buildSettings = {
|
||||||
|
PRODUCT_BUNDLE_IDENTIFIER = ${bundle}.Share;
|
||||||
|
TARGETED_DEVICE_FAMILY = "1,2";
|
||||||
|
WRAPPER_EXTENSION = appex;
|
||||||
|
};
|
||||||
|
name = Release;
|
||||||
|
};
|
||||||
|
/* End XCBuildConfiguration section */
|
||||||
|
};
|
||||||
|
}
|
||||||
|
`;
|
||||||
|
|
||||||
|
describe('device families (pure)', () => {
|
||||||
|
test('pbxproj: the Release configuration of the app\'s bundle id, not the extension\'s or Debug', () => {
|
||||||
|
expect(pbxFamilies(PBX('1'), 'com.example.notes')).toMatchObject({ list: [1], families: { iphone: true, ipad: false }, configurations: ['1'] });
|
||||||
|
expect(pbxFamilies(PBX('"1,2"'), 'com.example.notes')).toMatchObject({ list: [1, 2], families: { iphone: true, ipad: true } });
|
||||||
|
expect(pbxFamilies('no project here', 'com.example.notes')).toBeNull();
|
||||||
|
});
|
||||||
|
test('live signals: any iPad signal means iPad; no signal at all is unknown, never iPhone only', () => {
|
||||||
|
expect(liveFamilies('1.0.0', 'READY_FOR_SALE', [{ name: 'screenshot sets', values: ['APP_IPHONE_67', 'APP_IPAD_PRO_3GEN_129'] }])?.families).toEqual({ iphone: true, ipad: true });
|
||||||
|
expect(liveFamilies('1.0.0', 'READY_FOR_SALE', [{ name: 'a', values: [] }, { name: 'b', values: ['APP_IPHONE_67'] }])?.families).toEqual({ iphone: true, ipad: false });
|
||||||
|
expect(liveFamilies('1.0.0', 'READY_FOR_SALE', [{ name: 'a', values: [] }])).toBeNull();
|
||||||
|
});
|
||||||
|
test('verdicts: the exact fix; unknown is a warning; iPhone-only live version is fine', () => {
|
||||||
|
const live = liveFamilies('1.0.0', 'READY_FOR_SALE', [{ name: 'screenshot sets', values: ['APP_IPAD_PRO_3GEN_129'] }]);
|
||||||
|
const project = pbxFamilies(PBX('1'), 'com.example.notes', 'ios/App/App.xcodeproj/project.pbxproj');
|
||||||
|
const v = familyVerdicts({ live, project, ipad: false });
|
||||||
|
expect(v.map(x => x.level)).toEqual(['blocker', 'blocker']);
|
||||||
|
expect(v[0]!.msg).toContain('ITMS-90101');
|
||||||
|
expect(v[0]!.fix).toContain('"1,2"');
|
||||||
|
expect(v[1]!.fix).toContain('apple.ipad: true');
|
||||||
|
expect(familyVerdicts({ live, project: pbxFamilies(PBX('"1,2"'), 'com.example.notes'), ipad: true }).map(x => x.level)).toEqual(['ok']);
|
||||||
|
expect(familyVerdicts({ live: null, project, ipad: false })[0]!.level).toBe('warn');
|
||||||
|
expect(familyVerdicts({ live: liveFamilies('1.0.0', 'READY_FOR_SALE', [{ name: 'a', values: ['APP_IPHONE_67'] }]), project, ipad: false })[0]!.level).toBe('ok');
|
||||||
|
});
|
||||||
|
test('validate rules turn the verdicts into findings', () => {
|
||||||
|
const f = appleRules({ deviceFamilies: [{ level: 'blocker', msg: 'x ITMS-90101', fix: 'y' }], version: null, build: null, expectedLocales: [], locales: [], requiredDisplayTypes: [], reviewDetail: null, ageRating: null, priceSchedule: true, availability: true, iaps: [], expectedProducts: [], privacyUrl: { url: 'https://example.com', status: 200 } }).filter(x => x.code === 'device-families');
|
||||||
|
expect(f).toMatchObject([{ store: 'apple', level: 'blocker', code: 'device-families', fix: 'y' }]);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
describe('device families (fake App Store Connect + project)', () => {
|
||||||
|
setDefaultTimeout(30_000);
|
||||||
|
let s: Stores;
|
||||||
|
beforeAll(() => { ascEnv(); });
|
||||||
|
afterAll(restore);
|
||||||
|
beforeEach(() => { s = installStores(); });
|
||||||
|
afterEach(() => { uninstallStores(); });
|
||||||
|
/** a live version 1.0.0 with a build whose bundle names the families; screenshotSets: display types of its first locale */
|
||||||
|
function live(o: { protocols?: string[]; sets?: string[]; models?: string[] }): void {
|
||||||
|
s.asc.put({ type: 'appStoreVersions', id: 'ver-live', attributes: { versionString: '1.0.0', appVersionState: 'READY_FOR_SALE', platform: 'IOS' }, rels: { app: APP } });
|
||||||
|
s.asc.put({ type: 'builds', id: 'b-live', attributes: { version: '4', processingState: 'VALID' }, rels: { app: APP, appStoreVersion: 'ver-live' } });
|
||||||
|
s.asc.put({ type: 'buildBundles', id: 'bb-live', attributes: { bundleId: 'com.example.notes', bundleType: 'APP', deviceProtocols: o.protocols ?? [] }, rels: { build: 'b-live' } });
|
||||||
|
for (const [i, m] of (o.models ?? []).entries()) s.asc.put({ type: 'buildBundleFileSizes', id: `fs-${i}`, attributes: { deviceModel: m }, rels: { buildBundle: 'bb-live' } });
|
||||||
|
if (o.sets) {
|
||||||
|
s.asc.put({ type: 'appStoreVersionLocalizations', id: 'loc-live', attributes: { locale: 'en-US' }, rels: { appStoreVersion: 'ver-live' } });
|
||||||
|
for (const [i, t] of o.sets.entries()) s.asc.put({ type: 'appScreenshotSets', id: `set-${i}`, attributes: { screenshotDisplayType: t }, rels: { appStoreVersionLocalization: 'loc-live' } });
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const IPHONE_ONLY = { 'ios/App/App.xcodeproj/project.pbxproj': PBX('1') };
|
||||||
|
const cfg = { ...BASE, apple: { ...BASE.apple!, ipad: false, signing: { teamId: 'ABCDE12345' } } };
|
||||||
|
|
||||||
|
test('the live version\'s families are read from the build bundle, its device models and its screenshot sets', async () => {
|
||||||
|
const c = (await import('../cli/apple/asc')).ascClient;
|
||||||
|
live({ sets: ['APP_IPHONE_67', 'APP_IPAD_PRO_3GEN_129'] });
|
||||||
|
expect((await liveDeviceFamilies(await c('.', 'com.example.notes', APP), APP))?.families).toEqual({ iphone: true, ipad: true });
|
||||||
|
uninstallStores(); s = installStores();
|
||||||
|
live({ protocols: ['iphone', 'ipad'] });
|
||||||
|
expect((await liveDeviceFamilies(await c('.', 'com.example.notes', APP), APP))?.evidence[0]).toContain('deviceProtocols');
|
||||||
|
uninstallStores(); s = installStores();
|
||||||
|
live({ models: ['iPad_Pro_12_9_6th', 'iPhone15,2'] });
|
||||||
|
expect((await liveDeviceFamilies(await c('.', 'com.example.notes', APP), APP))?.families.ipad).toBe(true);
|
||||||
|
uninstallStores(); s = installStores();
|
||||||
|
expect(await liveDeviceFamilies(await c('.', 'com.example.notes', APP), APP)).toBeNull();
|
||||||
|
});
|
||||||
|
|
||||||
|
test('apple build stops BEFORE the archive when the project drops iPad that the live version has; --allow-device-gap goes on', async () => {
|
||||||
|
live({ sets: ['APP_IPHONE_67', 'APP_IPAD_PRO_3GEN_129'] });
|
||||||
|
const argv = ['--build-number', '5', '--no-prebuild'];
|
||||||
|
const p = project(cfg, IPHONE_ONLY);
|
||||||
|
const r = await capture(() => appleBuild(p.ctx(argv))).catch(e => ({ out: '', err: String((e as Error).message ?? e), exit: 1 }));
|
||||||
|
expect(r.exit).toBe(1);
|
||||||
|
expect(r.err).toContain('stopped before the archive');
|
||||||
|
expect(r.err).toContain('ITMS-90101');
|
||||||
|
expect(r.err).toContain('TARGETED_DEVICE_FAMILY to "1,2"');
|
||||||
|
expect(r.err).toContain('apple.ipad: true');
|
||||||
|
expect(r.err).toContain('--allow-device-gap');
|
||||||
|
// dry: warns, never throws
|
||||||
|
const dry = await capture(() => appleBuild(p.ctx([...argv, '--dry'])));
|
||||||
|
expect(dry.err).toContain('ITMS-90101');
|
||||||
|
// the escape hatch passes the check (the run then stops later: no Xcode on this machine)
|
||||||
|
const gap = await capture(() => appleBuild(p.ctx([...argv, '--allow-device-gap']))).catch(e => ({ out: '', err: String((e as Error).message ?? e), exit: 1 }));
|
||||||
|
expect(gap.err).not.toContain('stopped before the archive');
|
||||||
|
// the ship-step path (apple build --yes): a stopped build never exits 0, and the fix is its own short line
|
||||||
|
const sr = await ship('apple build', [...argv, '--yes'], a => appleBuild({ ...p.ctx(argv), args: a }));
|
||||||
|
expect(sr.code).not.toBe(0);
|
||||||
|
expect(sr.err).toMatch(/^fix: apple\.ipad: true in storebound\.config\.ts$/m);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('apple build passes the check with iPad in the project and apple.ipad true; an iPhone-only live version never blocks', async () => {
|
||||||
|
live({ sets: ['APP_IPHONE_67', 'APP_IPAD_PRO_3GEN_129'] });
|
||||||
|
const ok = project({ ...cfg, apple: { ...cfg.apple, ipad: true } }, { 'ios/App/App.xcodeproj/project.pbxproj': PBX('"1,2"') });
|
||||||
|
const r = await capture(() => appleBuild(ok.ctx(['--build-number', '5', '--no-prebuild', '--dry'])));
|
||||||
|
expect(r.err).not.toContain('ITMS-90101');
|
||||||
|
uninstallStores(); s = installStores();
|
||||||
|
live({ sets: ['APP_IPHONE_67'] });
|
||||||
|
const iph = project(cfg, IPHONE_ONLY);
|
||||||
|
const r2 = await capture(() => appleBuild(iph.ctx(['--build-number', '5', '--no-prebuild', '--dry'])));
|
||||||
|
expect(r2.err).not.toContain('ITMS-90101');
|
||||||
|
});
|
||||||
|
|
||||||
|
test('projectFamilies reads the project found under the root (and apple.build.project)', () => {
|
||||||
|
const p = project(cfg, IPHONE_ONLY);
|
||||||
|
expect(projectFamilies(p.root, 'com.example.notes')).toMatchObject({ file: 'ios/App/App.xcodeproj/project.pbxproj', list: [1] });
|
||||||
|
expect(projectFamilies(p.root, 'com.example.notes', 'ios/App/App.xcodeproj')?.list).toEqual([1]);
|
||||||
|
expect(projectFamilies(project(cfg).root, 'com.example.notes')).toBeNull();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
// ------------------------------------------------------------------------------------------------ 3. TestFlight invite
|
||||||
|
|
||||||
|
describe('TestFlight invite needs an installable build', () => {
|
||||||
|
setDefaultTimeout(30_000);
|
||||||
|
let s: Stores;
|
||||||
|
beforeAll(() => { ascEnv(); });
|
||||||
|
afterAll(restore);
|
||||||
|
beforeEach(() => { s = installStores(); });
|
||||||
|
afterEach(() => { uninstallStores(); });
|
||||||
|
const CSV = { '.storebound/testers.csv': 'email,first_name,groups\ntester1@example.com,Ex,Friends\n' };
|
||||||
|
const cfg = { ...BASE, apple: { ...BASE.apple!, testflight: { groups: [{ name: 'Friends' }] } } };
|
||||||
|
const group = (): void => { s.asc.put({ type: 'betaGroups', id: 'grp-friends', attributes: { name: 'Friends', isInternalGroup: false }, rels: { app: APP } }); };
|
||||||
|
const buildIn = (external: string): void => {
|
||||||
|
s.asc.put({ type: 'builds', id: 'b-1', attributes: { version: '7', processingState: 'VALID', expired: false }, rels: { app: APP, betaGroups: ['grp-friends'] } });
|
||||||
|
s.asc.put({ type: 'buildBetaDetails', id: 'bd-1', attributes: { externalBuildState: external, internalBuildState: 'IN_BETA_TESTING' }, rels: { build: 'b-1' } });
|
||||||
|
};
|
||||||
|
const invites = (): number => s.asc.all('betaTesterInvitations').length;
|
||||||
|
|
||||||
|
test('pure: external needs BETA_APPROVED / IN_BETA_TESTING, internal READY_FOR_BETA_TESTING / IN_BETA_TESTING', () => {
|
||||||
|
const b = { attributes: { processingState: 'VALID' } };
|
||||||
|
expect(installableBuild(b, { externalBuildState: 'READY_FOR_BETA_SUBMISSION' }, false)).toBe(false);
|
||||||
|
expect(installableBuild(b, { externalBuildState: 'WAITING_FOR_BETA_REVIEW' }, false)).toBe(false);
|
||||||
|
expect(installableBuild(b, { externalBuildState: 'BETA_APPROVED' }, false)).toBe(true);
|
||||||
|
expect(installableBuild(b, { externalBuildState: 'IN_BETA_TESTING' }, false)).toBe(true);
|
||||||
|
expect(installableBuild(b, { internalBuildState: 'READY_FOR_BETA_TESTING' }, true)).toBe(true);
|
||||||
|
expect(installableBuild({ attributes: { processingState: 'VALID', expired: true } }, { externalBuildState: 'BETA_APPROVED' }, false)).toBe(false);
|
||||||
|
expect(noInstallableBuildHint(['Friends'])).toBe('tester added; the invite goes out when a build in Friends passes Beta App Review (re-run with --invite then)');
|
||||||
|
expect(noInstallableBuilds409(new Error('POST /v1/betaTesterInvitations -> 409 STATE_ERROR.TESTER_INVITE.NO_INSTALLABLE_BUILDS'))).toBe(true);
|
||||||
|
expect(noInstallableBuilds409(new Error('-> 409 ALREADY_EXISTS'))).toBe(false);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('a new external group without an approved build: the tester is added, no invitation is sent, exit 0 with the hint', async () => {
|
||||||
|
group();
|
||||||
|
buildIn('WAITING_FOR_BETA_REVIEW');
|
||||||
|
const p = project(cfg, CSV);
|
||||||
|
const r = await capture(() => appleTestflight(p.ctx(['testers', '--group', 'Friends', '--invite', '--yes'])));
|
||||||
|
expect(r.exit).toBeNull();
|
||||||
|
expect(r.err).toContain('tester added; the invite goes out when a build in Friends passes Beta App Review (re-run with --invite then)');
|
||||||
|
expect(s.asc.all('betaTesters')).toHaveLength(1);
|
||||||
|
expect(invites()).toBe(0);
|
||||||
|
expect(writes(s.calls).some(c => c.path === '/v1/betaTesterInvitations')).toBe(false);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('once a build passed Beta App Review, --invite sends the invitation', async () => {
|
||||||
|
group();
|
||||||
|
const p = project(cfg, CSV);
|
||||||
|
await capture(() => appleTestflight(p.ctx(['testers', '--group', 'Friends', '--invite', '--yes'])));
|
||||||
|
expect(invites()).toBe(0);
|
||||||
|
buildIn('BETA_APPROVED');
|
||||||
|
const r = await capture(() => appleTestflight(p.ctx(['testers', '--group', 'Friends', '--invite', '--yes'])));
|
||||||
|
expect(r.exit).toBeNull();
|
||||||
|
expect(invites()).toBe(1);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('if the 409 still comes back (the build looked installable), it is the same case: warning, no throw, exit 0', async () => {
|
||||||
|
group();
|
||||||
|
buildIn('BETA_APPROVED');
|
||||||
|
const p = project(cfg, CSV);
|
||||||
|
// Apple's answer wins over our read: the double refuses the invitation as the live API did
|
||||||
|
s.faults.push({ method: 'POST', match: /\/v1\/betaTesterInvitations/, when: 'before', status: 409, code: 'STATE_ERROR.TESTER_INVITE.NO_INSTALLABLE_BUILDS', detail: 'The tester cannot be invited because the groups they belong to have no installable builds.' });
|
||||||
|
const r = await capture(() => appleTestflight(p.ctx(['testers', '--group', 'Friends', '--invite', '--yes'])));
|
||||||
|
expect(r.exit).toBeNull();
|
||||||
|
expect(r.err).toContain('passes Beta App Review');
|
||||||
|
expect(s.asc.all('betaTesters')).toHaveLength(1);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('distribute --submit-review prints the hint for testers that are added but not invited', async () => {
|
||||||
|
group();
|
||||||
|
buildIn('READY_FOR_BETA_SUBMISSION');
|
||||||
|
const p = project(cfg, CSV);
|
||||||
|
await capture(() => appleTestflight(p.ctx(['testers', '--group', 'Friends', '--yes'])));
|
||||||
|
s.asc.all('buildBetaDetails')[0]!.attributes.processingState = 'x';
|
||||||
|
s.asc.put({ type: 'preReleaseVersions', id: 'pre-1', attributes: { version: '1.0.0', platform: 'IOS' }, rels: { app: APP } });
|
||||||
|
s.asc.all('builds')[0]!.rels.preReleaseVersion = 'pre-1';
|
||||||
|
s.asc.all('builds')[0]!.rels.buildBetaDetail = 'bd-1';
|
||||||
|
const r = await capture(() => appleTestflight(p.ctx(['distribute', '--build', '7', '--group', 'Friends', '--submit-review', '--yes'])));
|
||||||
|
expect(r.out + r.err).toContain('tester added; the invite goes out when a build in Friends passes Beta App Review');
|
||||||
|
});
|
||||||
|
});
|
||||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue