From 984c78d0a68c1842bdf1c16f5fded53fc0d89abb Mon Sep 17 00:00:00 2001 From: fatme Date: Thu, 2 Oct 2014 07:47:27 +0300 Subject: [PATCH] Release build for android --- lib/options.ts | 6 +++++- lib/services/android-project-service.ts | 6 ++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/lib/options.ts b/lib/options.ts index 9104d42b8e..be8c066643 100644 --- a/lib/options.ts +++ b/lib/options.ts @@ -16,7 +16,11 @@ var knownOpts:any = { "device": Boolean, "emulator": Boolean, "version": Boolean, - "help": Boolean + "help": Boolean, + "keyStorePath": String, + "keyStorePassword": String, + "keyStoreAlias": String, + "keyStoreAliasPassword": String }, shorthands = { "v" : "verbose", diff --git a/lib/services/android-project-service.ts b/lib/services/android-project-service.ts index b930db40ce..ba9d2c7559 100644 --- a/lib/services/android-project-service.ts +++ b/lib/services/android-project-service.ts @@ -135,6 +135,12 @@ class AndroidProjectService implements IPlatformProjectService { private getAntArgs(configuration: string, projectRoot: string): string[] { var args = [configuration, "-f", path.join(projectRoot, "build.xml")]; + if(configuration === "release") { + args = args.concat(["-Dkey.store", options.keyStorePath, + "-Dkey.store.password", options.keyStorePassword, + "-Dkey.alias", options.keyStoreAlias, + "-Dkey.alias.password", options.keyStoreAliasPassword]); + } return args; }