mobileprovision shell 读取
mobileprovision_file=mmcapp_develop.mobileprovision
mobileprovision_teamname=`/usr/libexec/PlistBuddy -c "Print TeamName" /dev/stdin <<< $(security cms -D -i $mobileprovision_file)`
echo $mobileprovision_teamname
CODE_SIGN_IDENTITY="iPhone Distribution: $mobileprovision_teamname"
echo "$CODE_SIGN_IDENTITY"
PROVISIONING_PROFILE_SPECIFIER=`/usr/libexec/PlistBuddy -c "Print AppIDName" /dev/stdin <<< $(security cms -D -i $mobileprovision_file)`
echo "AppIDName:"$PROVISIONING_PROFILE_SPECIFIER
UUID=`/usr/libexec/PlistBuddy -c "Print UUID" /dev/stdin <<< $(security cms -D -i $mobileprovision_file)`
echo "UUID:"$UUID
Name=`/usr/libexec/PlistBuddy -c "Print Name" /dev/stdin <<< $(security cms -D -i $mobileprovision_file)`
echo "Name:"$Name
TeamIdentifier=`/usr/libexec/PlistBuddy -c "Print TeamIdentifier:0" /dev/stdin <<< $(security cms -D -i $mobileprovision_file)`
echo "TeamIdentifier:"$TeamIdentifier
ApplicationIdentifierPrefix=`/usr/libexec/PlistBuddy -c "Print ApplicationIdentifierPrefix:0" /dev/stdin <<< $(security cms -D -i $mobileprovision_file)`
echo "ApplicationIdentifierPrefix:"${ApplicationIdentifierPrefix}
PROVISIONING_PROFILE_SPECIFIER=`/usr/libexec/PlistBuddy -c "Print Entitlements:application-identifier" /dev/stdin <<< $(security cms -D -i $mobileprovision_file)`
echo "AppID:"${PROVISIONING_PROFILE_SPECIFIER}
//bundleId:
echo "bundleId:"${PROVISIONING_PROFILE_SPECIFIER#*${ApplicationIdentifierPrefix}.}
网友评论