From a1f7d3309ff6e5d044bd41f54c33468ec9406e8b Mon Sep 17 00:00:00 2001 From: Mathieu Poumeyrol Date: Wed, 10 Apr 2024 08:54:47 +0200 Subject: [PATCH] only warn if xcrun is missing --- dinghy-lib/src/apple/mod.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/dinghy-lib/src/apple/mod.rs b/dinghy-lib/src/apple/mod.rs index 8dbdcae6..af5a9d37 100644 --- a/dinghy-lib/src/apple/mod.rs +++ b/dinghy-lib/src/apple/mod.rs @@ -240,6 +240,10 @@ fn simulators(sim_type: AppleSimulatorType) -> Result>> { fn devices() -> Result>> { let mut devices: HashMap = Default::default(); + if which::which("xcrun").is_err() { + log::warn!("xcrun not found. Apple devices support disabled. Consider installing XCode and its command line tools."); + return Ok(vec!()) + } devices_from_devicectl(&mut devices)?; devices_from_ios_deploy(&mut devices)?; Ok(devices