Ionic Android build not same commands as cordova Android build


We use to build with cordova using Angular1.

  1. In Cordova building a production app you can do it on the commandline.
    cordova run android --release – --keystore=…/my-release-key.keystore --storePassword=password --alias=alias_name --password=password.

That same command but with ionic infront doesn’t seem to work. The only solution I have found so far is putting the passwords in some file. Any way to build Ionic release from command line?

  1. Also before when I built I had a build-extras.gradle file to change the name of dev output from app-debug.apk to some file name with the packageName. I have put this build-extras.gradle file in the platforms/android folder. My output it still app-debug.apk.
    Not sure how to debug that. Gradle 4.01



Figured out the second part. My build-extras.gradle was looking for android-debug.apk. Ionic does app-debug.apk. So that is why it wasn’t changing the file.