You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ks...@apache.org on 2016/11/16 05:24:41 UTC

ios commit: CB-12130 - Launch storyboard images are not updated or cleaned

Repository: cordova-ios
Updated Branches:
  refs/heads/master 14508d67f -> 99219c1c4


CB-12130 - Launch storyboard images are not updated or cleaned

The platform project directory needs to be relative to the project

Launch screen images were not updated or cleaned in
`updateLaunchStoryboardImages()` or `cleanLaunchStoryboardImages()`
because the check for `Images.xcassets` in
`getLaunchStoryboardImagesDir()` failed.

The reason was that the `platformProjDir` and `projectRoot` were
joined, while both were relative to the root directory. So the
resulting directory was non-sensical. This changes makes
`platformProjDir` relative to `cordovaProject.root`, which matches the
same check in `updateSplashScreens()` and `updateIcons()`.

 This closes #276


Project: http://git-wip-us.apache.org/repos/asf/cordova-ios/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-ios/commit/99219c1c
Tree: http://git-wip-us.apache.org/repos/asf/cordova-ios/tree/99219c1c
Diff: http://git-wip-us.apache.org/repos/asf/cordova-ios/diff/99219c1c

Branch: refs/heads/master
Commit: 99219c1c4cd8d1000fb89a15449f2d25a57bef41
Parents: 14508d6
Author: Niels Leenheer <ni...@leenheer.nl>
Authored: Thu Nov 10 15:27:43 2016 +0100
Committer: Kerri Shotts <ks...@apache.org>
Committed: Tue Nov 15 23:22:13 2016 -0600

----------------------------------------------------------------------
 bin/templates/scripts/cordova/lib/prepare.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/99219c1c/bin/templates/scripts/cordova/lib/prepare.js
----------------------------------------------------------------------
diff --git a/bin/templates/scripts/cordova/lib/prepare.js b/bin/templates/scripts/cordova/lib/prepare.js
index 8d1cda9..02dd457 100644
--- a/bin/templates/scripts/cordova/lib/prepare.js
+++ b/bin/templates/scripts/cordova/lib/prepare.js
@@ -685,7 +685,7 @@ function getLaunchStoryboardImagesDir(projectRoot, platformProjDir) {
  */
 function updateLaunchStoryboardImages(cordovaProject, locations) {
     var splashScreens = cordovaProject.projectConfig.getSplashScreens('ios');
-    var platformProjDir = locations.xcodeCordovaProj;
+    var platformProjDir = path.relative(cordovaProject.root, locations.xcodeCordovaProj);
     var launchStoryboardImagesDir = getLaunchStoryboardImagesDir(cordovaProject.root, platformProjDir);
 
     if (launchStoryboardImagesDir) {
@@ -712,7 +712,7 @@ function updateLaunchStoryboardImages(cordovaProject, locations) {
  */
 function cleanLaunchStoryboardImages(projectRoot, projectConfig, locations) {
     var splashScreens = projectConfig.getSplashScreens('ios');
-    var platformProjDir = locations.xcodeCordovaProj;
+    var platformProjDir = path.relative(projectRoot, locations.xcodeCordovaProj);
     var launchStoryboardImagesDir = getLaunchStoryboardImagesDir(projectRoot, platformProjDir);
     if (launchStoryboardImagesDir) {
         var resourceMap = mapLaunchStoryboardResources(splashScreens, launchStoryboardImagesDir);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org