API to get a provisioning profile from Apple dev site

后端 未结 4 604
礼貌的吻别
礼貌的吻别 2021-02-04 17:50

I\'m wondering if it\'s possible to get the latest provisioning profile from Apple Developer Portal using API? I\'ve set up CI for iOS project but I have to update provisioning

4条回答
  •  情书的邮戳
    2021-02-04 18:33

    I came up with the following solution:

    • create a special repo which has only up to date profiles (I know there is still human factor but I have not found better solution at the moment)

    • checout the repo with profiles before a build and copy it to the /User/$USER/Library/Library/MobileDevice/Provisioning Profiles

    • grep to find a profile hash and pass the hash as a build option (e.g

    xcodebuild -target ${TargetName} -sdk "${TARGET_SDK}" -configuration "Ad Hoc" "CODE_SIGN_IDENTITY[sdk=iphoneos*]=${PROFILE_NAME}" "PROVISIONING_PROFILE=${grep results}"

    )

    The solution works for me but still has some issues.

提交回复
热议问题