You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ni...@apache.org on 2016/03/08 07:48:43 UTC

ios commit: CB-10673 fixed conflicting plugin install issue with overlapped tag using --force option. This closes #199.

Repository: cordova-ios
Updated Branches:
  refs/heads/master fa3830de1 -> ef5eff4d3


CB-10673 fixed conflicting plugin install issue with overlapped <source-file> tag using --force option. This closes #199.


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

Branch: refs/heads/master
Commit: ef5eff4d3f849fd930d491e8e9f691c3d4fd10aa
Parents: fa3830d
Author: Byoungro So <by...@intel.com>
Authored: Fri Feb 26 22:33:54 2016 -0800
Committer: Nikhil Khandelwal <ni...@microsoft.com>
Committed: Mon Mar 7 22:48:04 2016 -0800

----------------------------------------------------------------------
 .../scripts/cordova/lib/plugman/pluginHandlers.js      | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/ef5eff4d/bin/templates/scripts/cordova/lib/plugman/pluginHandlers.js
----------------------------------------------------------------------
diff --git a/bin/templates/scripts/cordova/lib/plugman/pluginHandlers.js b/bin/templates/scripts/cordova/lib/plugman/pluginHandlers.js
index d60738b..173ce14 100644
--- a/bin/templates/scripts/cordova/lib/plugman/pluginHandlers.js
+++ b/bin/templates/scripts/cordova/lib/plugman/pluginHandlers.js
@@ -201,15 +201,22 @@ function installHelper(type, obj, plugin_dir, project_dir, plugin_id, options, p
     if (link) {
         var trueSrc = fs.realpathSync(srcFile);
         // Create a symlink in the expected place, so that uninstall can use it.
-        copyNewFile(plugin_dir, trueSrc, project_dir, destFile, link);
-
+        if (options && options.force) {
+            copyFile(plugin_dir, trueSrc, project_dir, destFile, link);
+        } else {
+            copyNewFile(plugin_dir, trueSrc, project_dir, destFile, link);
+        }
         // Xcode won't save changes to a file if there is a symlink involved.
         // Make the Xcode reference the file directly.
         // Note: Can't use path.join() here since it collapses 'Plugins/..', and xcode
         // library special-cases Plugins/ prefix.
         project_ref = 'Plugins/' + fixPathSep(path.relative(fs.realpathSync(project.plugins_dir), trueSrc));
     } else {
-        copyNewFile(plugin_dir, srcFile, project_dir, destFile, link);
+        if (options && options.force) {
+            copyFile(plugin_dir, srcFile, project_dir, destFile, link);
+        } else {
+            copyNewFile(plugin_dir, srcFile, project_dir, destFile, link);
+        }
         project_ref = 'Plugins/' + fixPathSep(path.relative(project.plugins_dir, destFile));
     }
 


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