简体   繁体   中英

Sign .apk file without password prompting on local phonegap


Hi there
I am trying to sign my unsigned .apk file without prompting the password.
The android build is local on phonegap/cordova via cmd/powershell.
The signing-step should be done with jarsigner via cmd too.Unfortunately there is no official option to do it without prompting the password or i just cant find it.
Does anybody know how to do it?
Thanks in advance :-)

You can use a build.json file, cordova will pick it automatically when you build your app

{
     "android": {
         "debug": {
             "keystore": "keyStoreName.keystore",
             "storePassword": "keystorePassword",
             "alias": "aliasName",
             "password" : "aliasPassword",
             "keystoreType": ""
         },
         "release": {
             "keystore": "keyStoreName.keystore",
             "storePassword": "keystorePassword",
             "alias": "aliasName",
             "password" : "aliasPassword",
             "keystoreType": ""
         }
     }
 }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM