// engine/doc-generator/mobile-distribution-ios.ts — SPEC-013 tech-debt criterion 15
// iOS/TestFlight distribution section builder.
// SRP: one responsibility — generate iOS store submission steps.
/**
 * Builds the iOS TestFlight & App Store submission section.
 */
export function buildIOSDistributionSection() {
    return {
        title: 'iOS — TestFlight & App Store Submission',
        level: 2,
        content: [
            '### Prerequisites',
            '- Active Apple Developer Program membership ($99/year)',
            '- App ID registered in App Store Connect',
            '- Distribution certificate and provisioning profile configured',
            '',
            '### Step 1: Build signed IPA',
            '```bash',
            '# Via Fastlane (recommended)',
            'fastlane gym --scheme MyApp --export_method app-store',
            '',
            '# Via Xcode CLI',
            'xcodebuild -project MyApp.xcodeproj -scheme MyApp \\',
            '  -archivePath build/MyApp.xcarchive archive',
            'xcodebuild -exportArchive -archivePath build/MyApp.xcarchive \\',
            '  -exportOptionsPlist ExportOptions.plist \\',
            '  -exportPath build/ipa',
            '```',
            '',
            '### Step 2: Upload to TestFlight (internal testing)',
            '```bash',
            '# Via Fastlane pilot',
            'fastlane pilot upload --ipa build/ipa/MyApp.ipa',
            '',
            '# Via xcrun altool',
            'xcrun altool --upload-app --type ios \\',
            '  --file build/ipa/MyApp.ipa \\',
            '  --apiKey <API_KEY> --apiIssuer <ISSUER_ID>',
            '```',
            '- Go to App Store Connect → TestFlight → Invite internal testers',
            '- Internal testers receive email; install via TestFlight app',
            '- External testing requires beta review (1-3 business days)',
            '',
            '### Step 3: Submit to App Store',
            '```bash',
            '# Via Fastlane deliver',
            'fastlane deliver --force',
            '```',
            '- Complete in App Store Connect: screenshots, App Privacy, Export Compliance',
            '- Add `PrivacyInfo.xcprivacy` if using required APIs',
            '- Submit for review — typical wait: 1-3 business days',
            '- Phased rollout: go to Pricing & Availability → Phased Release (7-day rollout)',
            '',
            '> **Verification:** Build appears in TestFlight. App Store Connect shows "In Review".',
        ].join('\n'),
    };
}
//# sourceMappingURL=mobile-distribution-ios.js.map