You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Kevin Lot (JIRA)" <ji...@apache.org> on 2017/12/16 16:11:03 UTC
[jira] [Created] (CB-13684) Unable to sign apk with 6.4.0 and 7.0.0
Kevin Lot created CB-13684:
------------------------------
Summary: Unable to sign apk with 6.4.0 and 7.0.0
Key: CB-13684
URL: https://issues.apache.org/jira/browse/CB-13684
Project: Apache Cordova
Issue Type: Bug
Components: cordova-android
Reporter: Kevin Lot
Assignee: Joe Bowser
Since 6.4.0, sign APK without specify password in config file is unable.
Cause gradle 4.1.0 has this issue [#2826] - Use SwingBuilder in customize task on Android studio throw java.awt.HeadlessException. ([link|https://github.com/gradle/gradle/issues/2826]).
If you don't specify passwords in config file to sign your APK, compilation launches a window with SwingBuilder to promt passwords.
{quote}def doPromptForPassword(msg) {
if (System.console() == null) {
def ret = null
new SwingBuilder().edt {
dialog(modal: true, title: 'Enter password', alwaysOnTop: true, resizable: false, locationRelativeTo: null, pack: true, show: true) {
vbox {
label(text: msg)
def input = passwordField()
button(defaultButton: true, text: 'OK', actionPerformed: {
ret = input.password;
dispose();
})
}
}
}
if (!ret) {
throw new GradleException('User canceled build')
}
return new String(ret)
} else {
return System.console().readPassword('\n' + msg);
}
}{quote}
On my linuxmint, event in terminal System.console() return null and compilation crashes due to gradle issue.
Thanks for help.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org