File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -120,11 +120,19 @@ PLIST_PATH="${PROJECT_PATH}/ExportOptions.plist"
120120# 修改ExportOptions.plist
121121# 修改 io.agora.api.examples 的值
122122echo " start modify ExportOption.plist"
123- /usr/libexec/PlistBuddy -c " Set :provisioningProfiles:io.agora.api.examples io.agora.entfull" " $PLIST_PATH "
123+ # 先获取原始值
124+ value1=$( /usr/libexec/PlistBuddy -c " Print :provisioningProfiles:io.agora.api.examples" " $PLIST_PATH " )
125+ value2=$( /usr/libexec/PlistBuddy -c " Print :provisioningProfiles:io.agora.api.examples.Agora-ScreenShare-Extension" " $PLIST_PATH " )
124126
125- # 修改 io.agora.api.examples.Agora-ScreenShare-Extension 的值
126- /usr/libexec/PlistBuddy -c " Set :provisioningProfiles:io.agora.api.examples.Agora-ScreenShare-Extension io.agora.entfull.Agora-ScreenShare-Extension" " $PLIST_PATH "
127+ # 删除原始键
128+ /usr/libexec/PlistBuddy -c " Delete :provisioningProfiles:io.agora.api.examples" " $PLIST_PATH "
129+ /usr/libexec/PlistBuddy -c " Delete :provisioningProfiles:io.agora.api.examples.Agora-ScreenShare-Extension" " $PLIST_PATH "
127130
131+ # 添加新键和值
132+ /usr/libexec/PlistBuddy -c " Add :provisioningProfiles:io.agora.entfull string $value1 " " $PLIST_PATH "
133+ /usr/libexec/PlistBuddy -c " Add :provisioningProfiles:io.agora.entfull.Agora-ScreenShare-Extension string $value2 " " $PLIST_PATH "
134+
135+ # 打印修改后的 provisioningProfiles 值
128136echo " 修改后的 provisioningProfiles 值:"
129137/usr/libexec/PlistBuddy -c " Print :provisioningProfiles" " $PLIST_PATH "
130138
You can’t perform that action at this time.
0 commit comments