CLI for desktop D2: doctor, inspect --icon / --listings, reviews drafts / approve, init --dry from embedded templates, iOS phased release share, playwright as optional peer (sidecar bundles playwright-core)
This commit is contained in:
parent
9320d64f46
commit
3f7cf446be
22 changed files with 808 additions and 40 deletions
|
|
@ -54,7 +54,17 @@ export async function run(ctx: Ctx): Promise<void> {
|
|||
const builds = (await c.asc('GET', `/v1/builds?filter[app]=${appId}&sort=-uploadedDate&limit=5&include=preReleaseVersion`));
|
||||
const iaps = await c.all(`/v1/apps/${appId}/inAppPurchasesV2?limit=200`);
|
||||
const subs = await c.all(`/v1/reviewSubmissions?filter[app]=${appId}&limit=20`);
|
||||
if (ctx.args.has('json')) { printJson({ app, versions, builds: builds.data, iaps, subs }); return; }
|
||||
if (ctx.args.has('json')) {
|
||||
// phased release of the newest versions that are live or close to it (rollout share on the desktop timeline)
|
||||
const phased: Record<string, unknown> = {};
|
||||
for (const v of versions.slice(0, 3)) {
|
||||
const st = String(v.attributes.appVersionState ?? v.attributes.appStoreState ?? '');
|
||||
if (!/READY_FOR_SALE|READY_FOR_DISTRIBUTION|PENDING_DEVELOPER_RELEASE|PENDING_APPLE_RELEASE|ACCEPTED/.test(st)) continue;
|
||||
phased[v.id] = (await c.maybe(`/v1/appStoreVersions/${v.id}/appStoreVersionPhasedRelease`))?.data ?? null;
|
||||
}
|
||||
printJson({ app, versions, builds: builds.data, iaps, subs, phased });
|
||||
return;
|
||||
}
|
||||
|
||||
console.log(`${app.attributes.name} · ${app.attributes.bundleId} · Apple ID ${appId}`);
|
||||
for (const v of versions) console.log(` version ${v.attributes.versionString.padEnd(8)} ${v.attributes.appVersionState ?? v.attributes.appStoreState}${v.relationships?.build?.data ? ' (build attached)' : ''}`);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue