Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 8B7F4200AE4 for ; Thu, 26 May 2016 02:58:42 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 89D8C160A2E; Thu, 26 May 2016 00:58:42 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id D46B8160A29 for ; Thu, 26 May 2016 02:58:41 +0200 (CEST) Received: (qmail 22856 invoked by uid 500); 26 May 2016 00:58:36 -0000 Mailing-List: contact dev-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list dev@cordova.apache.org Received: (qmail 22843 invoked by uid 99); 26 May 2016 00:58:35 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 May 2016 00:58:35 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id AB4C6DFB38; Thu, 26 May 2016 00:58:35 +0000 (UTC) From: nikhilkh To: dev@cordova.apache.org Reply-To: dev@cordova.apache.org References: In-Reply-To: Subject: [GitHub] cordova-windows pull request: CB-11117: Optimize prepare for windo... Content-Type: text/plain Message-Id: <20160526005835.AB4C6DFB38@git1-us-west.apache.org> Date: Thu, 26 May 2016 00:58:35 +0000 (UTC) archived-at: Thu, 26 May 2016 00:58:42 -0000 Github user nikhilkh commented on a diff in the pull request: https://github.com/apache/cordova-windows/pull/174#discussion_r64677748 --- Diff: template/cordova/lib/prepare.js --- @@ -425,19 +451,39 @@ module.exports.prepare = function (cordovaProject) { AppxManifest.purgeCache(); // Update own www dir with project's www assets and plugins' assets and js-files - return Q.when(updateWwwFrom(cordovaProject, this.locations)) + return Q.when(updateWww(cordovaProject, this.locations)) .then(function () { // update project according to config.xml changes. return updateProjectAccordingTo(self._config, self.locations); }) .then(function () { - copyImages(cordovaProject.projectConfig, self.root); + copyImages(cordovaProject, self.locations); }) .then(function () { events.emit('verbose', 'Prepared windows project successfully'); }); }; +module.exports.clean = function (options) { + // A cordovaProject isn't passed into the clean() function, because it might have + // been called from the platform shell script rather than the CLI. Check for the + // noPrepare option passed in by the non-CLI clean script. If that's present, or if + // there's no config.xml found at the project root, then don't clean prepared files. + var projectRoot = path.resolve(this.root, '../..'); + var projectConfigFile = path.join(projectRoot, 'config.xml'); --- End diff -- I see you are invoking `getIcons('windows')` and this should do the right thing. Is there a reason why you do not use the config.xml in the platform directory? --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@cordova.apache.org For additional commands, e-mail: dev-help@cordova.apache.org