Reputation: 11373
This is not a duplicate because the other similar questions are very incomplete. So I am asking for the gaps in information.
I just added an update to my app. I followed examples on this site that said to update the code like this adding the versionCode and versionName. The instructions said to increment the code by 1, and the version to whatever I want it called. So I have this.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="juangallardo.emofortunecookie"
android:versionCode="2"
android:versionName="1.1.0">
Then I hit Build --> Clean. Then build --> Generate Signed APK
then chose release
Then I uploaded what was generated. I did check to make sure that the file was just recently modified to ensure that I was not uploading a previous file. But I got this error.
Upvotes: 1
Views: 1125
Reputation: 3962
You do not need to specify the version information in the manifest manually for an Android Studio project and you instead have to modify the Gradle build file.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="juangallardo.emofortunecookie">
defaultConfig {
applicationId "juangallardo.emofortunecookie"
[..]
versionCode 2
versionName "1.1.0"
}
Upvotes: 2
Reputation: 1142
It seems you're using Android Studio. You'll have to edit your build.gradle
which may be overiding your manifest settings.
android {
...
defaultConfig {
versionCode 2
versionName "1.1.0"
...
}
Upvotes: 2