apple submit/resubmit --platform macos: apple.macos.noIap leaves IAPs out, no Game Center switch without apple.macos.gameCenter; pitfalls #128

This commit is contained in:
CRTkafa 2026-11-06 21:07:22 +07:00
parent 36ef9c2c5c
commit d05294ebcd
6 changed files with 875 additions and 2 deletions

View file

@ -1161,6 +1161,14 @@ export const appleName = (c: Pick<ShipConfig, 'app' | 'apple'>): string => c.app
export const platformsOf = (c: Pick<ShipConfig, 'app' | 'apple' | 'play'>): Platform[] =>
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. */
export const sellsOn = (c: Pick<ShipConfig, 'app' | 'apple' | 'play'>, item: { platforms?: Platform[] }, store: 'apple' | 'play'): boolean => {
const p: Platform = store === 'apple' ? 'ios' : 'android';