0

I did exactly as usual to publish my ionic app on the Play store. I updated all the version numbers in my config.xml to :

<widget android-versionCode="1830" id="com.XXXX" ios-CFBundleVersion="1830" 
ios-CFBundleVersionString="183" version="183" 
versionCode="10" xmlns="http://www.w3.org/ns/widgets" 
xmlns:cdv="http://cordova.apache.org/ns/1.0">

I then build using ionic package build android --release --profile profile_production. but I get an error message when I import the apk on the Play Store: The version code must be higher ...

enter image description here

I tried to add this android-versionCode="18308" as mentioned here but I get the same error.

Any ideas please ?

Community
  • 1
  • 1
Louis
  • 2,548
  • 10
  • 63
  • 120

1 Answers1

0

Have you tried Semantic Versioning ?

Rather than name it 1.0.8

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<widget id="com.XXXX" version="1.0.8" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">

Once you have completed make sure you do a build

ionic build android

then

cordova build --release android
LeRoy
  • 4,189
  • 2
  • 35
  • 46
  • Thanks but LeRoy, I am at version 183 ! So I can (UNFORTUNATELY) back version to 1.XXX. And I am building with ionic package. – Louis Mar 14 '17 at 13:50
  • @Louis I also noticed your not include release.... ionic package build PLATFORM_TAG --profile PROFILE_TAG --release – LeRoy Mar 14 '17 at 13:56