diff --git a/tools/xcodeproj_shims/xcodeproj-installer.sh b/tools/xcodeproj_shims/xcodeproj-installer.sh index bbc249d23..5011f7374 100755 --- a/tools/xcodeproj_shims/xcodeproj-installer.sh +++ b/tools/xcodeproj_shims/xcodeproj-installer.sh @@ -71,7 +71,10 @@ chmod -R +w "${tmp_dest}" # if installing into the root of the workspace, remove the path entry entirely sed -i.bak -E -e 's|^([[:space:]]*path = )../../..;$|\1.;|g' "${tmp_dest}/project.pbxproj" # always trim three ../ from path, since that's "bazel-out/darwin-fastbuild/bin" -sed -i.bak -E -e 's|([ "])../../../|\1|g' "${tmp_dest}/project.pbxproj" + +# Parse repo_mappings file to get the worksapce name: +# Example: ,build_bazel_rules_ios,_main +sed -i.bak 's/BAZEL_BUILD_TARGET_WORKSPACE = _main;/BAZEL_BUILD_TARGET_WORKSPACE = build_bazel_rules_ios;/g' "${tmp_dest}/project.pbxproj" rm "${tmp_dest}/project.pbxproj.bak" if [[ -d $dest ]]; then