Return-Path: X-Original-To: apmail-cordova-commits-archive@www.apache.org Delivered-To: apmail-cordova-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 54E8B1073C for ; Tue, 13 Jan 2015 15:01:49 +0000 (UTC) Received: (qmail 87748 invoked by uid 500); 13 Jan 2015 15:01:51 -0000 Delivered-To: apmail-cordova-commits-archive@cordova.apache.org Received: (qmail 87719 invoked by uid 500); 13 Jan 2015 15:01:51 -0000 Mailing-List: contact commits-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list commits@cordova.apache.org Received: (qmail 87710 invoked by uid 99); 13 Jan 2015 15:01:50 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 13 Jan 2015 15:01:50 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 990BB92DEE6; Tue, 13 Jan 2015 15:01:50 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: agrieve@apache.org To: commits@cordova.apache.org Date: Tue, 13 Jan 2015 15:01:52 -0000 Message-Id: <64af628e705047c2922be6c6f0946589@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [3/6] android commit: CB-4914 Fix build whitespace issue CB-4914 Fix build whitespace issue Project: http://git-wip-us.apache.org/repos/asf/cordova-android/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-android/commit/8e5c93a3 Tree: http://git-wip-us.apache.org/repos/asf/cordova-android/tree/8e5c93a3 Diff: http://git-wip-us.apache.org/repos/asf/cordova-android/diff/8e5c93a3 Branch: refs/heads/master Commit: 8e5c93a31fb88108f1d97e933816584ecbbb939f Parents: 0e5d72d Author: Murat Sutunc Authored: Mon Jan 12 22:54:37 2015 -0800 Committer: Andrew Grieve Committed: Tue Jan 13 09:59:29 2015 -0500 ---------------------------------------------------------------------- bin/templates/cordova/lib/spawn.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-android/blob/8e5c93a3/bin/templates/cordova/lib/spawn.js ---------------------------------------------------------------------- diff --git a/bin/templates/cordova/lib/spawn.js b/bin/templates/cordova/lib/spawn.js index d5b0dce..3e500a0 100644 --- a/bin/templates/cordova/lib/spawn.js +++ b/bin/templates/cordova/lib/spawn.js @@ -26,13 +26,15 @@ var isWindows = process.platform.slice(0, 3) == 'win'; // Takes a command and optional current working directory. module.exports = function(cmd, args, opt_cwd) { var d = Q.defer(); + var opts = { cwd: opt_cwd, stdio: 'inherit' }; try { // Work around spawn not being able to find .bat files. if (isWindows) { - args.unshift('/s', '/c', cmd); - cmd = 'cmd'; + args = [['/s', '/c', '"' + [cmd].concat(args).map(function(a){if (/^[^"].* .*[^"]/.test(a)) return '"' + a + '"'; return a;}).join(' ')+'"'].join(' ')]; + cmd = 'cmd'; + opts.windowsVerbatimArguments = true; } - var child = child_process.spawn(cmd, args, {cwd: opt_cwd, stdio: 'inherit'}); + var child = child_process.spawn(cmd, args, opts); child.on('exit', function(code) { if (code) { d.reject('Error code ' + code + ' for command: ' + cmd + ' with args: ' + args); @@ -45,5 +47,4 @@ module.exports = function(cmd, args, opt_cwd) { d.reject(e); } return d.promise; -} - +}; --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org For additional commands, e-mail: commits-help@cordova.apache.org