MCPcopy Index your code
hub / github.com/getsentry/XcodeBuildMCP / getDefaultDeviceIndex

Function getDefaultDeviceIndex

src/cli/commands/setup.ts:789–798  ·  view source on GitHub ↗
(devices: SetupDevice[], existingDeviceId?: string)

Source from the content-addressed store, hash-verified

787}
788
789function getDefaultDeviceIndex(devices: SetupDevice[], existingDeviceId?: string): number {
790 if (existingDeviceId != null) {
791 const existingIndex = devices.findIndex((device) => device.udid === existingDeviceId);
792 if (existingIndex >= 0) {
793 return existingIndex;
794 }
795 }
796
797 return 0;
798}
799
800async function selectDevice(opts: {
801 existingDeviceId?: string;

Callers 1

selectDeviceFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected