Updated Branches:
  refs/heads/master cb01eab02 -> 7d6d98597

CB-2725: Fix www deploy issues with symlinks

- Fixes issue when 'www' is a symlink
- Fixes issue with symlinks when deploying to an actual device


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

Branch: refs/heads/master
Commit: 7d6d9859742b26d754b0daecb522d7850f3e78fc
Parents: cb01eab
Author: James Jong <[email protected]>
Authored: Thu Mar 28 15:55:06 2013 -0400
Committer: James Jong <[email protected]>
Committed: Tue Apr 2 09:25:06 2013 -0400

----------------------------------------------------------------------
 .../project/__TESTING__.xcodeproj/project.pbxproj  |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/7d6d9859/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj 
b/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
index f5ed342..912ddd3 100755
--- a/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
+++ b/bin/templates/project/__TESTING__.xcodeproj/project.pbxproj
@@ -404,7 +404,7 @@
                        );
                        runOnlyForDeploymentPostprocessing = 0;
                        shellPath = /bin/sh;
-                       shellScript = 
"SRC_DIR=\"www\"\nDST_DIR=\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/www\"\nCOPY_HIDDEN=\nORIG_IFS=$IFS\nIFS=$(echo
 -en \"\\n\\b\")\n\nif [[ ! -e \"$SRC_DIR\" ]]; then\n  echo \"Path does not 
exist: $SRC_DIR\"\n  exit 1\nfi\n\nif [[ -n $COPY_HIDDEN ]]; then\n  alias 
do_find='find \"$SRC_DIR\"'\nelse\n  alias do_find='find \"$SRC_DIR\" -name 
\".*\" -prune -o'\nfi\n\ntime (\n# Code signing files must be removed or else 
there are\n# resource signing errors.\nrm -rf \"$DST_DIR\" \\\n       
\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/_CodeSignature\" \\\n       
\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/PkgInfo\" \\\n       
\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/embedded.mobileprovision\"\n\n# 
Directories\nfor p in $(do_find -type d -print); do\n  
subpath=\"${p#$SRC_DIR}\"\n  mkdir \"$DST_DIR$subpath\" || exit 1\ndone\n\n# 
Symlinks\nfor p in $(do_find -type l -print); do\n  subpath=\"${p#$SRC_DIR}\"\n 
 rsync -a \"$SRC_DIR$subpath\" \"$DST_DIR$subpath\" || exit 2\ndone\n\n# Fi
 les\nfor p in $(do_find -type f -print); do\n  subpath=\"${p#$SRC_DIR}\"\n  if 
! ln \"$SRC_DIR$subpath\" \"$DST_DIR$subpath\" 2>/dev/null; then\n    rsync -a 
\"$SRC_DIR$subpath\" \"$DST_DIR$subpath\" || exit 3\n  
fi\ndone\n\n)\nIFS=$ORIG_IFS";
+                       shellScript = 
"SRC_DIR=\"www/\"\nDST_DIR=\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/www\"\nCOPY_HIDDEN=\nORIG_IFS=$IFS\nIFS=$(echo
 -en \"\\n\\b\")\n\nif [[ ! -e \"$SRC_DIR\" ]]; then\n  echo \"Path does not 
exist: $SRC_DIR\"\n  exit 1\nfi\n\nif [[ -n $COPY_HIDDEN ]]; then\n  alias 
do_find='find \"$SRC_DIR\"'\nelse\n  alias do_find='find \"$SRC_DIR\" -name 
\".*\" -prune -o'\nfi\n\ntime (\n# Code signing files must be removed or else 
there are\n# resource signing errors.\nrm -rf \"$DST_DIR\" \\\n       
\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/_CodeSignature\" \\\n       
\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/PkgInfo\" \\\n       
\"$BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME/embedded.mobileprovision\"\n\n# 
Directories\nfor p in $(do_find -type d -print); do\n  
subpath=\"${p#$SRC_DIR}\"\n  mkdir \"$DST_DIR$subpath\" || exit 1\ndone\n\n# 
Symlinks\nfor p in $(do_find -type l -print); do\n  subpath=\"${p#$SRC_DIR}\"\n 
 source=$(readlink $SRC_DIR$subpath)\n  sourcetype=$(stat -f \"%HT%SY\" $s
 ource)\n  if [ \"$sourcetype\" = \"Directory\" ]; then\n    mkdir 
\"$DST_DIR$subpath\" || exit 2\n  else\n    rsync -a \"$source\" 
\"$DST_DIR$subpath\" || exit 3\n  fi\ndone\n\n# Files\nfor p in $(do_find -type 
f -print); do\n  subpath=\"${p#$SRC_DIR}\"\n  if ! ln \"$SRC_DIR$subpath\" 
\"$DST_DIR$subpath\" 2>/dev/null; then\n    rsync -a \"$SRC_DIR$subpath\" 
\"$DST_DIR$subpath\" || exit 4\n  fi\ndone\n\n)\nIFS=$ORIG_IFS";
                };
 /* End PBXShellScriptBuildPhase section */
 

Reply via email to