cross-store text: other platforms named in App Store text (2.3.10: Android, Google Play, ...) or Play text (Metadata: iOS, App Store, Game Center, ...) are refused by every text write (apple / play listing, play release / upload notes, listing set, whats-new, storebound edit, desktop editor), blockers in check / validate, scan other-platforms / play-other-platforms; listing.allowPlatformMentions for the owner's functional mentions; whats-new splits [apple] / [play] lines per store; storebound api --yes without a TTY is refused (exit 1, stderr) instead of a silent dry run; pitfalls 77, 78

This commit is contained in:
CRTkafa 2026-10-20 02:57:25 +07:00
parent 3e4015b686
commit edabbec874
32 changed files with 613 additions and 53 deletions

View file

@ -0,0 +1,18 @@
// Other platforms named in the local listing files of both stores (pitfall 77): the blockers `check` and `validate`
// report. Reads store/appstore.md and store/listing.md (or the config's listing paths).
import { existsSync, readFileSync } from 'node:fs';
import { relative } from 'node:path';
import type { Loaded } from './config';
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[] {
const { config, resolve, root } = loaded;
const allow = config.listing?.allowPlatformMentions;
const out: PlatformHit[] = [];
const files: ['apple' | 'play', string | null][] = [
['apple', stores.apple && config.apple ? resolve(config.apple.listing ?? 'store/appstore.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));
return out;
}