How to change versionCode with cordova?
Cordova / PhoneGap / Ionic all accept arguments to the build
command
# ionicionic build --release android -- --versionCode=3# phonegapphonegap build --release android -- --versionCode=3# plain cordovacordova build --release android -- --versionCode=3
You can see this command line arg being referenced in the source in cordova/lib/build.js
:
if (options.argv.versionCode) ret.extraArgs.push('-PcdvVersionCode=' + options.argv.versionCode);
(Me: using Cordova version 6.1.1, ionic version 1.7.16)