| 36 | const UUID_REGEX = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i; |
| 37 | |
| 38 | function inferPlatformFromSimulatorName(simulatorName: string): SimulatorPlatform | null { |
| 39 | const name = simulatorName.toLowerCase(); |
| 40 | |
| 41 | if (name.includes('watch')) return XcodePlatform.watchOSSimulator; |
| 42 | if (name.includes('apple tv') || name.includes('tvos')) return XcodePlatform.tvOSSimulator; |
| 43 | if ( |
| 44 | name.includes('apple vision') || |
| 45 | name.includes('vision pro') || |
| 46 | name.includes('visionos') || |
| 47 | name.includes('xros') |
| 48 | ) { |
| 49 | return XcodePlatform.visionOSSimulator; |
| 50 | } |
| 51 | if (name.includes('iphone') || name.includes('ipad') || name.includes('ipod')) { |
| 52 | return XcodePlatform.iOSSimulator; |
| 53 | } |
| 54 | |
| 55 | return null; |
| 56 | } |
| 57 | |
| 58 | function inferPlatformFromRuntime(runtime: string): SimulatorPlatform | null { |
| 59 | const value = runtime.toLowerCase(); |