Repository: cordova-ios Updated Branches: refs/heads/4.3.x 4d70f5230 -> a675f9387
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 (cherry picked from commit 99219c1c4cd8d1000fb89a15449f2d25a57bef41) Project: http://git-wip-us.apache.org/repos/asf/cordova-ios/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-ios/commit/4871643d Tree: http://git-wip-us.apache.org/repos/asf/cordova-ios/tree/4871643d Diff: http://git-wip-us.apache.org/repos/asf/cordova-ios/diff/4871643d Branch: refs/heads/4.3.x Commit: 4871643d868f3d05fa97a7a4423140e73b48b130 Parents: 4d70f52 Author: Niels Leenheer <ni...@leenheer.nl> Authored: Thu Nov 10 15:27:43 2016 +0100 Committer: Kerri Shotts <ksho...@apache.org> Committed: Mon Nov 21 15:23:11 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/4871643d/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-unsubscr...@cordova.apache.org For additional commands, e-mail: commits-h...@cordova.apache.org