changeset 441:592f0ef08d94

migrate from Eclipse to Android Studio
author Carl Byington <carl@five-ten-sg.com>
date Thu, 03 Dec 2015 12:13:52 -0800
parents 1e3789de6900
children ced663d2e957
files app/build.gradle
diffstat 1 files changed, 11 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/app/build.gradle	Thu Dec 03 11:47:24 2015 -0800
+++ b/app/build.gradle	Thu Dec 03 12:13:52 2015 -0800
@@ -44,13 +44,19 @@
     android.signingConfigs {
         create("signed") {
             def console = System.console()
-            if (!console) console = System.in
+            if (console) {
+                storePassword = new String(console.readPassword("\nkey store password: "))
+                keyPassword   = new String(console.readPassword("\nkey alias password: "))
+            }
+            else {
+                def read = System.in.newReader().&readLine
+                storePassword = read()
+                keyPassword   = read()
+            }
             storeFile = file("../510Connectbot.keystore")
-            storePassword = new String(console.readPassword("\n\$ Enter keystore password: "))
             storeType = "jks"
-            keyAlias = "510Connectbot"
-            keyPassword = new String(console.readPassword("\n\$ Enter key password: "))
-            signConf = it
+            keyAlias  = "510Connectbot"
+            signConf  = it
         }
     }