Skip to content

Commit ef21ed9

Browse files
authored
fix(cli): iOS build crashing when development team has spaces (#12290)
Even though I couldn't even get the build to succeed when using the team name as the "developmentTeam" configuration (instead of the team ID), I've received reports that our processing of that value is broken and only works when it is escaped using `\"`.
1 parent cd1d026 commit ef21ed9

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"tauri-cli": patch:bug
3+
"@tauri-apps/cli": patch:bug
4+
---
5+
6+
Fix iOS build failing when the development team contains spaces.

crates/tauri-cli/src/mobile/ios/mod.rs

+5-3
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,8 @@ pub fn synchronize_project_config(
452452
}
453453

454454
if let Some(team) = config.development_team() {
455-
pbxproj.set_build_settings(&build_configuration_ref.id, "DEVELOPMENT_TEAM", team);
455+
let team = format!("\"{team}\"");
456+
pbxproj.set_build_settings(&build_configuration_ref.id, "DEVELOPMENT_TEAM", &team);
456457
}
457458

458459
pbxproj.set_build_settings(
@@ -472,11 +473,12 @@ pub fn synchronize_project_config(
472473
}
473474

474475
if let Some(id) = &project_config.team_id {
475-
pbxproj.set_build_settings(&build_configuration_ref.id, "DEVELOPMENT_TEAM", id);
476+
let id = format!("\"{id}\"");
477+
pbxproj.set_build_settings(&build_configuration_ref.id, "DEVELOPMENT_TEAM", &id);
476478
pbxproj.set_build_settings(
477479
&build_configuration_ref.id,
478480
"\"DEVELOPMENT_TEAM[sdk=iphoneos*]\"",
479-
id,
481+
&id,
480482
);
481483
}
482484

0 commit comments

Comments
 (0)