You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by pu...@apache.org on 2016/10/20 20:36:13 UTC

cordova-lib git commit: CB-11979 added deprecation warning for subdirectories

Repository: cordova-lib
Updated Branches:
  refs/heads/master 35e9ead5b -> 328980c2a


CB-11979 added deprecation warning for subdirectories


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

Branch: refs/heads/master
Commit: 328980c2a91dada8049f1e4f27103df67ba07532
Parents: 35e9ead
Author: Sterling <st...@gmail.com>
Authored: Tue Oct 18 15:29:09 2016 -0700
Committer: Jesse MacFadyen <pu...@gmail.com>
Committed: Thu Oct 20 13:34:36 2016 -0700

----------------------------------------------------------------------
 cordova-lib/src/plugman/fetch.js | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-lib/blob/328980c2/cordova-lib/src/plugman/fetch.js
----------------------------------------------------------------------
diff --git a/cordova-lib/src/plugman/fetch.js b/cordova-lib/src/plugman/fetch.js
index d33e460..036558e 100644
--- a/cordova-lib/src/plugman/fetch.js
+++ b/cordova-lib/src/plugman/fetch.js
@@ -68,8 +68,12 @@ function fetchPlugin(plugin_src, plugins_dir, options) {
             if (result[2])
                 options.subdir = result[2];
             //if --fetch was used, throw error for subdirectories
-            if (result[2] && options.fetch) {
-                return Q.reject(new CordovaError('--fetch does not support subdirectories'));
+
+            if(options.subdir) {
+                events.emit('warn', 'support for subdirectories is deprecated and will be removed in Cordova@7');
+                if (options.fetch) {
+                    return Q.reject(new CordovaError('--fetch does not support subdirectories'));
+                }
             }
 
             // Recurse and exit with the new options and truncated URL.


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