我们总是必须将 versionCode 增加一些任意数字才能将其发布到 google play.
该值是否有限制,如果达到会发生什么情况?
We always have to increment versionCode by some arbitary number to publish it to google play.
Is there limit to that value and what will happen if it is reached?
defaultConfig {
applicationId "my.app"
minSdkVersion 15
targetSdkVersion 22
versionCode 65
versionName "1.05"
setProperty("archivesBaseName", "myapp-$versionCode")
}
更新 08/11/2016 (UTC):
Update 08/11/2016 (UTC):
docs 已更新.不是旧的 MAX_INT 值,也不是 2000000000.
The docs has been updated. Not the old MAX_INT value nor the 2000000000.
警告:Google Play 允许 versionCode 的最大值为 2100000000.
Warning: The greatest value Google Play allows for
versionCodeis 2100000000.
<小时>
在此处交叉发布以提高知名度.
Cross-post for visibility here.
Google 似乎最近发生了变化,使得 versionCode 的最大值仅达到 2000000000.
It seems there was a recent change in Google, making the maximum versionCode up to 2000000000 only.
参考帖子:Google Play 开发者控制台错误:您的 APK 版本代码过高,您可能无法更新 APK
PS:对于那些计划提供参考官方文档的人其中提到的最大值是 2147483647,请先阅读我引用的帖子中的答案.它提到截至当前日期(08/10/2016),它仍未更新.
PS: For those who are planning to provide reference to the official documentation where the mentioned max value is 2147483647, please read the answer first in the post I referenced. It mentions that as of current date (08/10/2016), its still not updated.
这篇关于版本码有最大值吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!
更新到 Android Build Tools 25.1.6 GCM/FCM 后出现 IncompIncompatibleClassChangeError after updating to Android Build Tools 25.1.6 GCM / FCM(更新到 Android Build Tools 25.1.6 GCM/FCM 后出现 Incompatible
如何在 gradle 中获取当前风味How to get current flavor in gradle(如何在 gradle 中获取当前风味)
如何修复“意外元素<查询>在“清单How to fix quot;unexpected element lt;queriesgt; found in lt;manifestgt;quot; error?(如何修复“意外元素lt;查询gt;在“清单中找到错误
基于 Android Gradle 中多风味库的多风味应用Multi flavor app based on multi flavor library in Android Gradle(基于 Android Gradle 中多风味库的多风味应用)
Android 依赖在编译和运行时有不同的版本Android dependency has different version for the compile and runtime(Android 依赖在编译和运行时有不同的版本)
本地 aar 库的传递依赖Transitive dependencies for local aar library(本地 aar 库的传递依赖)