cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agri...@apache.org
Subject git commit: Allow --searchpath to have a delimiter
Date Thu, 06 Mar 2014 15:12:17 GMT
Repository: cordova-plugman
Updated Branches:
  refs/heads/master 172a4dec2 -> e1b9a304c


Allow --searchpath to have a delimiter


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

Branch: refs/heads/master
Commit: e1b9a304ce47575ad51919e873f8400287f5c2b4
Parents: 172a4de
Author: Andrew Grieve <agrieve@chromium.org>
Authored: Thu Mar 6 10:11:43 2014 -0500
Committer: Andrew Grieve <agrieve@chromium.org>
Committed: Thu Mar 6 10:12:13 2014 -0500

----------------------------------------------------------------------
 doc/help.txt | 4 ++--
 src/fetch.js | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugman/blob/e1b9a304/doc/help.txt
----------------------------------------------------------------------
diff --git a/doc/help.txt b/doc/help.txt
index 9101404..a0da457 100644
--- a/doc/help.txt
+++ b/doc/help.txt
@@ -28,8 +28,8 @@ Optional parameters
 
  - www <directory>: www assets for the plugin will be installed into this directory.
Default is to install into the standard www directory for the platform specified
  - plugins_dir <directory>: a copy of the plugin will be stored in this directory.
Default is to install into the <project directory>/plugins folder
- - searchpath <directory>: a directory to look in for a plugin with the provided ID
before looking on http://plugins.cordova.io
-   Use the searchpath flag multiple times to specify several directories (searched in order).
The search is not recursive and will only look one level down.
+ - searchpath <directory>: when looking up plugins by ID, look in this directory and
each of its subdirectories for the plugin before hitting the registry.
+   Multiple search paths can be used by either specifying the flag multiple times, or by
separating paths with a delimiter (: on 'nix, ; on Windows).
 
 Optional flags
 --------------

http://git-wip-us.apache.org/repos/asf/cordova-plugman/blob/e1b9a304/src/fetch.js
----------------------------------------------------------------------
diff --git a/src/fetch.js b/src/fetch.js
index 9d07946..a3adb3e 100644
--- a/src/fetch.js
+++ b/src/fetch.js
@@ -18,7 +18,7 @@ module.exports = function fetchPlugin(plugin_src, plugins_dir, options)
{
     options.subdir = options.subdir || '.';
     options.searchpath = options.searchpath || [];
     if ( typeof options.searchpath === 'string' ) {
-        options.searchpath = [ options.searchpath ];
+        options.searchpath = options.searchpath.split(path.delimiter);
     }
 
     // clone from git repository


Mime
View raw message