Cordova build -release Android Unsigned apk
Solution 1
Create a file called release-signing.properties
and put in APPFOLDER\platforms\android folder Cordova used to use ant.properties
but now ignores that file.
Contents of the file: edit after = for all except 2nd line
storeFile=C:/yourlocation/app.keystore
storeType=jks
keyAlias=aliasname
keyPassword=aliaspass
storePassword=password
Now running cordova build android --release
should produce a signed version.
Solution 2
If you have keystore file generated, this should work.
You may also need to remove console plugin if the same apk directly goes to production.
In cordova 6.2.0
cd cordova/ #change to root cordova folder
platforms/android/cordova/clean #clean if you want
cordova build android --release -- --keystore="/path/to/keystore" --storePassword=password --alias=alias_name #password will be prompted if you have any
Related videos on Youtube
vbotio
Been working with Front-end Development for about 7 years and I am very proud of never stopped learning.
Updated on September 16, 2022Comments
-
vbotio over 1 year
I'm trying to generate my release apk to deploy it on Play Store. I'm running this command
Sudo cordova build android --release
Which is generating me a file named Android-Release-Unsigned.apk
I tried many solutions, like creating keystore
keytool -genkey -v -keystore key-name.keystore -alias alias-name -keyalg RSA -keysize 2048 -validity 10000
or the trick of creating a Ant.properties file like here and none of them worked at all.
Any other possible solution for this ? Cordova version is 5.1.1
-
vbotio over 8 yearsI already tried this solution but it still generating "android-release-unsigned.apk"