Pgyer internal test distribution service is a leading mobile application internal test distribution platform in China, dedicated to providing easy-to-use App internal test distribution services for mobile developers and test users.
Pgyer Developer Service Platform is committed to providing excellent upstream and downstream services for developers, addressing the various needs of developers throughout the developer life cycle.
Scan QR code to follow
Pgyer WeChat Official Account
Get the latest news, official benefits, promotions and other information
Pgyer document center
蒲公英的 iOS SDK 和 Android SDK,都支持自動版本更新的功能,本文說明了蒲公英 SDK 自動更新的機制。
閱讀本文,需要先明白 App 的版本號機制,以及蒲公英的自增 Build 版本號。建議大家首先閱讀 顯示正確的 Build 版本號 ,來明確 App 本身的版本號
、蒲公英的自增 Build 版本號
的基礎概念。
蒲公英 SDK 的更新機制,根據不同的版本有兩種不同的機制:
新版本蒲公英 SDK 的更新,是根據 本地 App 的 Version
和App 本身的 Build
來判定更新的。這兩個版本號中,任何一個檢查到線上版本大于本地版本,都會提示更新。
第一步:
如果本地 App 的 Version
小于蒲公英上的 Version
,則提示更新。(注意:iOS App 的本地版本號是指 CFBundleShortVersionString, Android 是指 VersionName)
第二步:
如果本地 App 的 Build
小于蒲公英上的 Build
,則提示更新。(注意:iOS App 的本地版本號是指 CFBundleVersion,Android 是指 VersionCode)
在這兩步中,任何一步如果判斷出有新版本,都會提示更新。否則不會提示。
舊版本蒲公英 SDK 的更新,是根據 App 本身的 Version
和蒲公英自增 Build 版本號
來判定更新的。這兩個版本號中,任何一個檢查到線上版本大于本地版本,都會提示更新。
具體判定順序是:
第一步:
如果本地 App 本身的 Version
小于蒲公英上的 Version
,則提示更新。(注意:iOS App 的本地版本號是指 CFBundleShortVersionString, Android 是指 VersionCode)
第二步:
如果本地 App 的蒲公英自增 Build 版本號
小于蒲公英上版本的自增 Build 號
,則提示更新。
在這兩步中,任何一步如果判斷出有新版本,都會提示更新。否則不會提示。
Android SDKV3.0.4 (2019.02.27)版本
更新強制更新功能。如若SDK設置中設置強制更新失效,請先檢查SDK版本。IOS SDK暫不支持強制更新功能。
因為蒲公英的自增 Build 版本號
是不寫入 App 內的。所以,對于手機上首次安裝 App 來說,無論安裝的是蒲公英上的哪個版本,SDK 都會認為該 App 本地的蒲公英自增 Build 版本號
是當前蒲公英上最新版本的自增 Build 版本號。
因此,在 SDK 第一次啟動時,會檢查本地是否存在 蒲公英自增 Build 版本號
,如果不存在,會調用蒲公英接口將最新的蒲公英自增 Build 版本號
寫入本地文件中,以便下次用于版本更新的判斷。
另外,需要注意的是,對于 iOS App,如果需要提交蘋果 App Store,建議將自動更新功能去掉(相關代碼和 SDK 也需要去掉),因為目前蘋果并不允許含有自動版本更新功能的 App 上架 App Store。
About Us
Product Services
Help
Your account information is under review and can not be used temporarily; you can:
Check out the help documentation for common ways to work on the Pgyer's platform;
Check Pgyer's App Auditing , which must be viewed before uploading.
Currently, the real-name authentication has not been completed, and the number of downloads for each version is limited to 5 times/day, After real-name authentication, it can be extended to 500 times/day
TestFlight is only available to Professional users.(Click understand pgyer's price plan)
支付成功
Pgyer VIP User Group
(Please open WeChat - Sweep and join the group chat)