npm: Upgrade to 1.2.2
authorisaacs <i@izs.me>
Fri, 18 Jan 2013 16:37:32 +0000 (08:37 -0800)
committerisaacs <i@izs.me>
Fri, 18 Jan 2013 16:37:32 +0000 (08:37 -0800)
125 files changed:
deps/npm/AUTHORS
deps/npm/html/api/bin.html
deps/npm/html/api/bugs.html
deps/npm/html/api/commands.html
deps/npm/html/api/config.html
deps/npm/html/api/deprecate.html
deps/npm/html/api/docs.html
deps/npm/html/api/edit.html
deps/npm/html/api/explore.html
deps/npm/html/api/help-search.html
deps/npm/html/api/init.html
deps/npm/html/api/install.html
deps/npm/html/api/link.html
deps/npm/html/api/load.html
deps/npm/html/api/ls.html
deps/npm/html/api/npm.html
deps/npm/html/api/outdated.html
deps/npm/html/api/owner.html
deps/npm/html/api/pack.html
deps/npm/html/api/prefix.html
deps/npm/html/api/prune.html
deps/npm/html/api/publish.html
deps/npm/html/api/rebuild.html
deps/npm/html/api/restart.html
deps/npm/html/api/root.html
deps/npm/html/api/run-script.html
deps/npm/html/api/search.html
deps/npm/html/api/shrinkwrap.html
deps/npm/html/api/start.html
deps/npm/html/api/stop.html
deps/npm/html/api/submodule.html
deps/npm/html/api/tag.html
deps/npm/html/api/test.html
deps/npm/html/api/uninstall.html
deps/npm/html/api/unpublish.html
deps/npm/html/api/update.html
deps/npm/html/api/version.html
deps/npm/html/api/view.html
deps/npm/html/api/whoami.html
deps/npm/html/doc/README.html
deps/npm/html/doc/adduser.html
deps/npm/html/doc/bin.html
deps/npm/html/doc/bugs.html
deps/npm/html/doc/build.html
deps/npm/html/doc/bundle.html
deps/npm/html/doc/cache.html
deps/npm/html/doc/changelog.html
deps/npm/html/doc/coding-style.html
deps/npm/html/doc/completion.html
deps/npm/html/doc/config.html
deps/npm/html/doc/dedupe.html
deps/npm/html/doc/deprecate.html
deps/npm/html/doc/developers.html
deps/npm/html/doc/disputes.html
deps/npm/html/doc/docs.html
deps/npm/html/doc/edit.html
deps/npm/html/doc/explore.html
deps/npm/html/doc/faq.html
deps/npm/html/doc/folders.html
deps/npm/html/doc/help-search.html
deps/npm/html/doc/help.html
deps/npm/html/doc/index.html
deps/npm/html/doc/init.html
deps/npm/html/doc/install.html
deps/npm/html/doc/json.html
deps/npm/html/doc/link.html
deps/npm/html/doc/ls.html
deps/npm/html/doc/npm.html
deps/npm/html/doc/outdated.html
deps/npm/html/doc/owner.html
deps/npm/html/doc/pack.html
deps/npm/html/doc/prefix.html
deps/npm/html/doc/prune.html
deps/npm/html/doc/publish.html
deps/npm/html/doc/rebuild.html
deps/npm/html/doc/registry.html
deps/npm/html/doc/removing-npm.html
deps/npm/html/doc/restart.html
deps/npm/html/doc/root.html
deps/npm/html/doc/run-script.html
deps/npm/html/doc/scripts.html
deps/npm/html/doc/search.html
deps/npm/html/doc/semver.html
deps/npm/html/doc/shrinkwrap.html
deps/npm/html/doc/star.html
deps/npm/html/doc/start.html
deps/npm/html/doc/stop.html
deps/npm/html/doc/submodule.html
deps/npm/html/doc/tag.html
deps/npm/html/doc/test.html
deps/npm/html/doc/uninstall.html
deps/npm/html/doc/unpublish.html
deps/npm/html/doc/update.html
deps/npm/html/doc/version.html
deps/npm/html/doc/view.html
deps/npm/html/doc/whoami.html
deps/npm/lib/cache.js
deps/npm/lib/install.js
deps/npm/lib/ls.js
deps/npm/lib/npm.js
deps/npm/lib/publish.js
deps/npm/lib/utils/exec.js
deps/npm/lib/utils/lifecycle.js
deps/npm/lib/utils/tar.js
deps/npm/man/man1/ls.1
deps/npm/man/man1/npm.1
deps/npm/man/man3/npm.3
deps/npm/node_modules/abbrev/lib/abbrev.js
deps/npm/node_modules/abbrev/package.json
deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/LICENSE [new file with mode: 0644]
deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/package.json
deps/npm/node_modules/fstream-npm/package.json
deps/npm/node_modules/nopt/.npmignore
deps/npm/node_modules/nopt/bin/nopt.js
deps/npm/node_modules/nopt/lib/nopt.js
deps/npm/node_modules/nopt/package.json
deps/npm/node_modules/npmconf/package.json
deps/npm/package.json
deps/npm/test/packages/npm-test-peer-deps-invalid/npm-ls.json
deps/npm/test/packages/npm-test-peer-deps-invalid/test.js
deps/npm/test/packages/npm-test-peer-deps/npm-ls.json
deps/npm/test/packages/npm-test-peer-deps/test.js
deps/npm/test/packages/npm-test-shrinkwrap/npm-shrinkwrap.json
deps/npm/test/packages/npm-test-shrinkwrap/test.js
deps/npm/test/packages/npm-test-url-dep/package.json

index bba64f0..4a5f1ef 100644 (file)
@@ -71,10 +71,20 @@ Domenic Denicola <domenic@domenicdenicola.com>
 James Halliday <mail@substack.net>
 Jeremy Cantrell <jmcantrell@gmail.com>
 Ribettes <patlogan29@gmail.com>
+Einar Otto Stangvik <einaros@gmail.com>
 Don Park <donpark@docuverse.com>
 Kei Son <heyacct@gmail.com>
 Nicolas Morel <marsup@gmail.com>
 Mark Dube <markisdee@gmail.com>
+Nathan Rajlich <nathan@tootallnate.net>
 Maxim Bogushevich <boga1@mail.ru>
 Justin Beckwith <justbe@microsoft.com>
 Meaglin <Meaglin.wasabi@gmail.com>
+Ben Evans <ben@bensbit.co.uk>
+Nathan Zadoks <nathan@nathan7.eu>
+Brian White <mscdex@gmail.com>
+Jed Schmidt <tr@nslator.jp>
+Ian Livingstone <ianl@cs.dal.ca>
+Patrick Pfeiffer <patrick@buzzle.at>
+Paul Miller <paul@paulmillr.com>
+seebees <seebees@gmail.com>
index 73eb5c1..15168f2 100644 (file)
@@ -19,7 +19,7 @@
 <p>This function should not be used programmatically.  Instead, just refer
 to the <code>npm.bin</code> member.</p>
 </div>
-<p id="footer">bin &mdash; npm@1.2.0</p>
+<p id="footer">bin &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 6c69e53..3ed4011 100644 (file)
@@ -25,7 +25,7 @@ optional version number.</p>
 <p>This command will launch a browser, so this command may not be the most
 friendly for programmatic use.</p>
 </div>
-<p id="footer">bugs &mdash; npm@1.2.0</p>
+<p id="footer">bugs &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 14d9dcc..789ea04 100644 (file)
@@ -28,7 +28,7 @@ usage, or <code>man 3 npm-&lt;command&gt;</code> for programmatic usage.</p>
 
 <ul><li><a href="../doc/index.html">index(1)</a></li></ul>
 </div>
-<p id="footer">commands &mdash; npm@1.2.0</p>
+<p id="footer">commands &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 1158156..62f256f 100644 (file)
@@ -33,7 +33,7 @@ functions instead.</p>
 
 <ul><li><a href="../api/npm.html">npm(3)</a></li></ul>
 </div>
-<p id="footer">config &mdash; npm@1.2.0</p>
+<p id="footer">config &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 80bd8f0..c3b0244 100644 (file)
@@ -32,7 +32,7 @@ install the package.</p></li></ul>
 
 <ul><li><a href="../api/publish.html">publish(3)</a></li><li><a href="../api/unpublish.html">unpublish(3)</a></li><li><a href="../doc/registry.html">registry(1)</a></li></ul>
 </div>
-<p id="footer">deprecate &mdash; npm@1.2.0</p>
+<p id="footer">deprecate &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index b0f9203..1a13aaf 100644 (file)
@@ -25,7 +25,7 @@ optional version number.</p>
 <p>This command will launch a browser, so this command may not be the most
 friendly for programmatic use.</p>
 </div>
-<p id="footer">docs &mdash; npm@1.2.0</p>
+<p id="footer">docs &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index eaf876c..1f1d178 100644 (file)
@@ -30,7 +30,7 @@ to open. The package can optionally have a version number attached.</p>
 <p>Since this command opens an editor in a new process, be careful about where
 and how this is used.</p>
 </div>
-<p id="footer">edit &mdash; npm@1.2.0</p>
+<p id="footer">edit &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index d96d021..77e5b8e 100644 (file)
@@ -24,7 +24,7 @@ sure to use <code>npm rebuild &lt;pkg&gt;</code> if you make any changes.</p>
 
 <p>The first element in the &#39;args&#39; parameter must be a package name.  After that is the optional command, which can be any number of strings. All of the strings will be combined into one, space-delimited command.</p>
 </div>
-<p id="footer">explore &mdash; npm@1.2.0</p>
+<p id="footer">explore &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index f363d0b..a2f3c70 100644 (file)
@@ -32,7 +32,7 @@ Name of the file that matched</li></ul>
 
 <p>The silent parameter is not neccessary not used, but it may in the future.</p>
 </div>
-<p id="footer">help-search &mdash; npm@1.2.0</p>
+<p id="footer">help-search &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 8e3ee9a..39dc68d 100644 (file)
@@ -35,7 +35,7 @@ then go ahead and use this programmatically.</p>
 
 <p><a href="../doc/json.html">json(1)</a></p>
 </div>
-<p id="footer">init &mdash; npm@1.2.0</p>
+<p id="footer">init &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 88faffd..3ad0f7a 100644 (file)
@@ -25,7 +25,7 @@ the name of a package to be installed.</p>
 <p>Finally, &#39;callback&#39; is a function that will be called when all packages have been
 installed or when an error has been encountered.</p>
 </div>
-<p id="footer">install &mdash; npm@1.2.0</p>
+<p id="footer">install &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 744b7a0..4209687 100644 (file)
@@ -39,7 +39,7 @@ npm.commands.link(&#39;redis&#39;, cb)  # link-install the package</code></pre>
 <p>Now, any changes to the redis package will be reflected in
 the package in the current working directory</p>
 </div>
-<p id="footer">link &mdash; npm@1.2.0</p>
+<p id="footer">link &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 4ed5d1b..02d20ad 100644 (file)
@@ -32,7 +32,7 @@ config object.</p>
 
 <p>For a list of all the available command-line configs, see <code>npm help config</code></p>
 </div>
-<p id="footer">load &mdash; npm@1.2.0</p>
+<p id="footer">load &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 58b7e77..3029db2 100644 (file)
@@ -59,7 +59,7 @@ project.</p>
 This means that if a submodule a same dependency as a parent module, then the
 dependency will only be output once.</p>
 </div>
-<p id="footer">ls &mdash; npm@1.2.0</p>
+<p id="footer">ls &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index ca4482c..b761b6f 100644 (file)
@@ -24,7 +24,7 @@ npm.load(configObject, function (er, npm) {
 
 <h2 id="VERSION">VERSION</h2>
 
-<p>1.2.0</p>
+<p>1.2.2</p>
 
 <h2 id="DESCRIPTION">DESCRIPTION</h2>
 
@@ -91,7 +91,7 @@ method names.  Use the <code>npm.deref</code> method to find the real name.</p>
 
 <pre><code>var cmd = npm.deref(&quot;unp&quot;) // cmd === &quot;unpublish&quot;</code></pre>
 </div>
-<p id="footer">npm &mdash; npm@1.2.0</p>
+<p id="footer">npm &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 3c8427a..b27dd86 100644 (file)
@@ -19,7 +19,7 @@ currently outdated.</p>
 
 <p>If the &#39;packages&#39; parameter is left out, npm will check all packages.</p>
 </div>
-<p id="footer">outdated &mdash; npm@1.2.0</p>
+<p id="footer">outdated &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index f92a60b..eedbed3 100644 (file)
@@ -34,7 +34,7 @@ that is not implemented at this time.</p>
 
 <ul><li><a href="../api/publish.html">publish(3)</a></li><li><a href="../doc/registry.html">registry(1)</a></li></ul>
 </div>
-<p id="footer">owner &mdash; npm@1.2.0</p>
+<p id="footer">owner &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index ec3cea8..6f60696 100644 (file)
@@ -25,7 +25,7 @@ overwritten the second time.</p>
 
 <p>If no arguments are supplied, then npm packs the current package folder.</p>
 </div>
-<p id="footer">pack &mdash; npm@1.2.0</p>
+<p id="footer">pack &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 9856363..9bfb96e 100644 (file)
@@ -21,7 +21,7 @@
 
 <p>This function is not useful programmatically</p>
 </div>
-<p id="footer">prefix &mdash; npm@1.2.0</p>
+<p id="footer">prefix &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 82faeeb..cf0f067 100644 (file)
@@ -23,7 +23,7 @@
 <p>Extraneous packages are packages that are not listed on the parent
 package&#39;s dependencies list.</p>
 </div>
-<p id="footer">prune &mdash; npm@1.2.0</p>
+<p id="footer">prune &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index cbda587..71e9060 100644 (file)
@@ -32,7 +32,7 @@ the registry.  Overwrites when the &quot;force&quot; environment variable is set
 
 <ul><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/adduser.html">adduser(1)</a></li><li><a href="../api/owner.html">owner(3)</a></li></ul>
 </div>
-<p id="footer">publish &mdash; npm@1.2.0</p>
+<p id="footer">publish &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 6ff81e6..e9b6e61 100644 (file)
@@ -22,7 +22,7 @@ the new binary. If no &#39;packages&#39; parameter is specify, every package wil
 
 <p>See <code>npm help build</code></p>
 </div>
-<p id="footer">rebuild &mdash; npm@1.2.0</p>
+<p id="footer">rebuild &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index c244dd6..54801f1 100644 (file)
@@ -27,7 +27,7 @@ in the <code>packages</code> parameter.</p>
 
 <ul><li><a href="../api/start.html">start(3)</a></li><li><a href="../api/stop.html">stop(3)</a></li></ul>
 </div>
-<p id="footer">restart &mdash; npm@1.2.0</p>
+<p id="footer">restart &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 08a978e..c88eac9 100644 (file)
@@ -21,7 +21,7 @@
 
 <p>This function is not useful programmatically.</p>
 </div>
-<p id="footer">root &mdash; npm@1.2.0</p>
+<p id="footer">root &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 772f5fb..6551e50 100644 (file)
@@ -29,7 +29,7 @@ assumed to be the command to run. All other elements are ignored.</p>
 
 <ul><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../api/test.html">test(3)</a></li><li><a href="../api/start.html">start(3)</a></li><li><a href="../api/restart.html">restart(3)</a></li><li><a href="../api/stop.html">stop(3)</a></li></ul>
 </div>
-<p id="footer">run-script &mdash; npm@1.2.0</p>
+<p id="footer">run-script &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index f50f0ee..811b2f8 100644 (file)
@@ -32,7 +32,7 @@ excluded term (the &quot;searchexclude&quot; config). The search is case insensi
 and doesn&#39;t try to read your mind (it doesn&#39;t do any verb tense matching or the
 like).</p>
 </div>
-<p id="footer">search &mdash; npm@1.2.0</p>
+<p id="footer">search &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index da628cd..7267240 100644 (file)
@@ -26,7 +26,7 @@ but the shrinkwrap file will still be written.</p>
 <p>Finally, &#39;callback&#39; is a function that will be called when the shrinkwrap has
 been saved.</p>
 </div>
-<p id="footer">shrinkwrap &mdash; npm@1.2.0</p>
+<p id="footer">shrinkwrap &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index e98032b..5b3aafe 100644 (file)
@@ -19,7 +19,7 @@
 <p>npm can run tests on multiple packages. Just specify multiple packages
 in the <code>packages</code> parameter.</p>
 </div>
-<p id="footer">start &mdash; npm@1.2.0</p>
+<p id="footer">start &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 5f3841b..b95ef54 100644 (file)
@@ -19,7 +19,7 @@
 <p>npm can run stop on multiple packages. Just specify multiple packages
 in the <code>packages</code> parameter.</p>
 </div>
-<p id="footer">stop &mdash; npm@1.2.0</p>
+<p id="footer">stop &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index ab64b5c..cf2fda8 100644 (file)
@@ -33,7 +33,7 @@ dependencies into the submodule folder.</p>
 
 <ul><li>npm help json</li><li>git help submodule</li></ul>
 </div>
-<p id="footer">submodule &mdash; npm@1.2.0</p>
+<p id="footer">submodule &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 84748d8..3ce716e 100644 (file)
@@ -29,7 +29,7 @@ parameter is missing or falsey (empty), the default froom the config will be
 used. For more information about how to set this config, check
 <code>man 3 npm-config</code> for programmatic usage or <code>man npm-config</code> for cli usage.</p>
 </div>
-<p id="footer">tag &mdash; npm@1.2.0</p>
+<p id="footer">tag &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 49add1e..b4c41ca 100644 (file)
@@ -22,7 +22,7 @@ true.</p>
 <p>npm can run tests on multiple packages. Just specify multiple packages
 in the <code>packages</code> parameter.</p>
 </div>
-<p id="footer">test &mdash; npm@1.2.0</p>
+<p id="footer">test &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index ef8cf4a..7c86d6b 100644 (file)
@@ -22,7 +22,7 @@ the name of a package to be uninstalled.</p>
 <p>Finally, &#39;callback&#39; is a function that will be called when all packages have been
 uninstalled or when an error has been encountered.</p>
 </div>
-<p id="footer">uninstall &mdash; npm@1.2.0</p>
+<p id="footer">uninstall &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 0f3c11f..7a9a507 100644 (file)
@@ -26,7 +26,7 @@ is what is meant.</p>
 <p>If no version is specified, or if all versions are removed then
 the root package entry is removed from the registry entirely.</p>
 </div>
-<p id="footer">unpublish &mdash; npm@1.2.0</p>
+<p id="footer">unpublish &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 52a4830..52894e6 100644 (file)
@@ -18,7 +18,7 @@
 
 <p>The &#39;packages&#39; argument is an array of packages to update. The &#39;callback&#39; parameter will be called when done or when an error occurs.</p>
 </div>
-<p id="footer">update &mdash; npm@1.2.0</p>
+<p id="footer">update &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 2ff314a..717950b 100644 (file)
@@ -24,7 +24,7 @@ fail if the repo is not clean.</p>
 parameter. The difference, however, is this function will fail if it does
 not have exactly one element. The only element should be a version number.</p>
 </div>
-<p id="footer">version &mdash; npm@1.2.0</p>
+<p id="footer">version &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index d76d31b..c8547f2 100644 (file)
@@ -99,7 +99,7 @@ the field name.</p>
 
 <p>corresponding to the list of fields selected.</p>
 </div>
-<p id="footer">view &mdash; npm@1.2.0</p>
+<p id="footer">view &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 09ec779..5110105 100644 (file)
@@ -21,7 +21,7 @@
 
 <p>This function is not useful programmatically</p>
 </div>
-<p id="footer">whoami &mdash; npm@1.2.0</p>
+<p id="footer">whoami &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index c3378e8..87960d4 100644 (file)
@@ -240,7 +240,7 @@ will no doubt tell you to put the output in a gist or email.</p>
 
 <ul><li><a href="../doc/npm.html">npm(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/help.html">help(1)</a></li><li><a href="../doc/index.html">index(1)</a></li></ul>
 </div>
-<p id="footer"><a href="../doc/README.html">README</a> &mdash; npm@1.2.0</p>
+<p id="footer"><a href="../doc/README.html">README</a> &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 28e31d3..701242c 100644 (file)
@@ -39,7 +39,7 @@ authorize on a new machine.</p>
 
 <ul><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/owner.html">owner(1)</a></li><li><a href="../doc/whoami.html">whoami(1)</a></li></ul>
 </div>
-<p id="footer">adduser &mdash; npm@1.2.0</p>
+<p id="footer">adduser &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index dd507cb..247a8f2 100644 (file)
@@ -20,7 +20,7 @@
 
 <ul><li><a href="../doc/prefix.html">prefix(1)</a></li><li><a href="../doc/root.html">root(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">bin &mdash; npm@1.2.0</p>
+<p id="footer">bin &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index e12e004..ee0c256 100644 (file)
@@ -36,7 +36,7 @@ config param.</p>
 
 <ul><li><a href="../doc/docs.html">docs(1)</a></li><li><a href="../doc/view.html">view(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/json.html">json(1)</a></li></ul>
 </div>
-<p id="footer">bugs &mdash; npm@1.2.0</p>
+<p id="footer">bugs &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 4f5af87..46ae979 100644 (file)
@@ -25,7 +25,7 @@ A folder containing a <code>package.json</code> file in its root.</li></ul>
 
 <ul><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/link.html">link(1)</a></li><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/json.html">json(1)</a></li></ul>
 </div>
-<p id="footer">build &mdash; npm@1.2.0</p>
+<p id="footer">build &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 61163b2..fa6a05d 100644 (file)
@@ -20,7 +20,7 @@ install packages into the local space.</p>
 
 <ul><li><a href="../doc/install.html">install(1)</a></li></ul>
 </div>
-<p id="footer">bundle &mdash; npm@1.2.0</p>
+<p id="footer">bundle &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index fc9a1c0..5e2cf71 100644 (file)
@@ -66,7 +66,7 @@ they do not make an HTTP request to the registry.</p>
 
 <ul><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/pack.html">pack(1)</a></li></ul>
 </div>
-<p id="footer">cache &mdash; npm@1.2.0</p>
+<p id="footer">cache &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index a55851f..0b0c1ae 100644 (file)
@@ -65,7 +65,7 @@
 
 <ul><li><a href="../doc/npm.html">npm(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li></ul>
 </div>
-<p id="footer">changelog &mdash; npm@1.2.0</p>
+<p id="footer">changelog &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 1718203..dc1e30b 100644 (file)
@@ -182,7 +182,7 @@ set to anything.&quot;</p>
 
 <ul><li><a href="../doc/developers.html">developers(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/npm.html">npm(1)</a></li></ul>
 </div>
-<p id="footer">coding-style &mdash; npm@1.2.0</p>
+<p id="footer">coding-style &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index a2ae76b..23b5318 100644 (file)
@@ -33,7 +33,7 @@ completions based on the arguments.</p>
 
 <ul><li><a href="../doc/developers.html">developers(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/npm.html">npm(1)</a></li></ul>
 </div>
-<p id="footer">completion &mdash; npm@1.2.0</p>
+<p id="footer">completion &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 8442267..43604e1 100644 (file)
@@ -756,7 +756,7 @@ then answer &quot;no&quot; to any prompt.</p>
 
 <ul><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/npm.html">npm(1)</a></li></ul>
 </div>
-<p id="footer">config &mdash; npm@1.2.0</p>
+<p id="footer">config &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 8acbf61..a921cd6 100644 (file)
@@ -57,7 +57,7 @@ registry.</p>
 
 <ul><li><a href="../doc/ls.html">ls(1)</a></li><li><a href="../doc/update.html">update(1)</a></li><li><a href="../doc/install.html">install(1)</a></li></ul>
 </div>
-<p id="footer">dedupe &mdash; npm@1.2.0</p>
+<p id="footer">dedupe &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 9fcb58b..c461327 100644 (file)
@@ -31,7 +31,7 @@ something like this:</p>
 
 <ul><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li></ul>
 </div>
-<p id="footer">deprecate &mdash; npm@1.2.0</p>
+<p id="footer">deprecate &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index aaae81b..450ddca 100644 (file)
@@ -160,7 +160,7 @@ from a fresh checkout.</p>
 
 <ul><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/npm.html">npm(1)</a></li><li><a href="../doc/init.html">init(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/adduser.html">adduser(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li></ul>
 </div>
-<p id="footer">developers &mdash; npm@1.2.0</p>
+<p id="footer">developers &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index d5c8bb2..43a9da1 100644 (file)
@@ -86,7 +86,7 @@ an empty tarball, you&#39;re going to be evicted.</li></ol>
 
 <ul><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/owner.html">owner(1)</a></li></ul>
 </div>
-<p id="footer">disputes &mdash; npm@1.2.0</p>
+<p id="footer">disputes &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index ad7e8a7..02663c0 100644 (file)
@@ -37,7 +37,7 @@ config param.</p>
 
 <ul><li><a href="../doc/view.html">view(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/json.html">json(1)</a></li></ul>
 </div>
-<p id="footer">docs &mdash; npm@1.2.0</p>
+<p id="footer">docs &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index a2c6120..9a89749 100644 (file)
@@ -37,7 +37,7 @@ or <code>&quot;notepad&quot;</code> on Windows.</li><li>Type: path</li></ul>
 
 <ul><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/explore.html">explore(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">edit &mdash; npm@1.2.0</p>
+<p id="footer">edit &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 8366909..0b7f3ef 100644 (file)
@@ -40,7 +40,7 @@ Windows</li><li>Type: path</li></ul>
 
 <ul><li><a href="../doc/submodule.html">submodule(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/edit.html">edit(1)</a></li><li><a href="../doc/rebuild.html">rebuild(1)</a></li><li><a href="../doc/build.html">build(1)</a></li><li><a href="../doc/install.html">install(1)</a></li></ul>
 </div>
-<p id="footer">explore &mdash; npm@1.2.0</p>
+<p id="footer">explore &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index d991025..4cc7000 100644 (file)
@@ -250,7 +250,7 @@ There is not sufficient need to impose namespace rules on everyone.</p>
 
 <ul><li><a href="../doc/npm.html">npm(1)</a></li><li><a href="../doc/developers.html">developers(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li></ul>
 </div>
-<p id="footer">faq &mdash; npm@1.2.0</p>
+<p id="footer">faq &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 03ee379..7868c2f 100644 (file)
@@ -205,7 +205,7 @@ cannot be found elsewhere.  See <code><a href="../doc/json.html">json(1)</a></co
 
 <ul><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/pack.html">pack(1)</a></li><li><a href="../doc/cache.html">cache(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li></ul>
 </div>
-<p id="footer">folders &mdash; npm@1.2.0</p>
+<p id="footer">folders &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 5d991e4..2866c45 100644 (file)
@@ -38,7 +38,7 @@ where the terms were found in the documentation.</p>
 
 <ul><li><a href="../doc/npm.html">npm(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/help.html">help(1)</a></li></ul>
 </div>
-<p id="footer">help-search &mdash; npm@1.2.0</p>
+<p id="footer">help-search &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 291b82b..e07da58 100644 (file)
@@ -36,7 +36,7 @@ matches are equivalent to specifying a topic name.</p>
 
 <ul><li><a href="../doc/npm.html">npm(1)</a></li><li><a href="../doc/README.html">README</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/help-search.html">help-search(1)</a></li><li><a href="../doc/index.html">index(1)</a></li></ul>
 </div>
-<p id="footer">help &mdash; npm@1.2.0</p>
+<p id="footer">help &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index cb3f9ee..a9edf49 100644 (file)
 
 <p> Display npm username</p>
 </div>
-<p id="footer">index &mdash; npm@1.2.0</p>
+<p id="footer">index &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 39979b5..37664a6 100644 (file)
@@ -29,7 +29,7 @@ without a really good reason to do so.</p>
 
 <ul><li><a href="https://github.com/isaacs/init-package-json">https://github.com/isaacs/init-package-json</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/version.html">version(1)</a></li></ul>
 </div>
-<p id="footer">init &mdash; npm@1.2.0</p>
+<p id="footer">init &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 5e196c4..534ba26 100644 (file)
@@ -133,7 +133,7 @@ affects a real use-case, it will be investigated.</p>
 
 <ul><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/update.html">update(1)</a></li><li><a href="../doc/link.html">link(1)</a></li><li><a href="../doc/rebuild.html">rebuild(1)</a></li><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/build.html">build(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/tag.html">tag(1)</a></li><li><a href="../doc/rm.html">rm(1)</a></li><li><a href="../doc/shrinkwrap.html">shrinkwrap(1)</a></li></ul>
 </div>
-<p id="footer">install &mdash; npm@1.2.0</p>
+<p id="footer">install &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index eaac020..1ea27fc 100644 (file)
@@ -525,7 +525,7 @@ overridden.</p>
 
 <ul><li><a href="../doc/semver.html">semver(1)</a></li><li><a href="../doc/init.html">init(1)</a></li><li><a href="../doc/version.html">version(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/help.html">help(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/rm.html">rm(1)</a></li></ul>
 </div>
-<p id="footer">json &mdash; npm@1.2.0</p>
+<p id="footer">json &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index ba73fc7..1107004 100644 (file)
@@ -58,7 +58,7 @@ installation target into your project&#39;s <code>node_modules</code> folder.</p
 
 <ul><li><a href="../doc/developers.html">developers(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">link &mdash; npm@1.2.0</p>
+<p id="footer">link &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 38ea227..2930a94 100644 (file)
@@ -25,7 +25,7 @@ limit the results to only the paths to the packages named.  Note that
 nested packages will <em>also</em> show the paths to the specified packages.
 For example, running <code>npm ls promzard</code> in npm&#39;s source tree will show:</p>
 
-<pre><code>npm@1.2.0 /path/to/npm
+<pre><code>npm@1.2.2 /path/to/npm
 â””─┬ init-package-json@0.0.4
   â””── promzard@0.1.5</code></pre>
 
@@ -64,7 +64,7 @@ project.</p>
 
 <ul><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/link.html">link(1)</a></li><li><a href="../doc/prune.html">prune(1)</a></li><li><a href="../doc/outdated.html">outdated(1)</a></li><li><a href="../doc/update.html">update(1)</a></li></ul>
 </div>
-<p id="footer">ls &mdash; npm@1.2.0</p>
+<p id="footer">ls &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 5855f36..9eb30a9 100644 (file)
@@ -14,7 +14,7 @@
 
 <h2 id="VERSION">VERSION</h2>
 
-<p>1.2.0</p>
+<p>1.2.2</p>
 
 <h2 id="DESCRIPTION">DESCRIPTION</h2>
 
@@ -135,7 +135,7 @@ will no doubt tell you to put the output in a gist or email.</p>
 
 <ul><li><a href="../doc/help.html">help(1)</a></li><li><a href="../doc/faq.html">faq(1)</a></li><li><a href="../doc/README.html">README</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/index.html">index(1)</a></li><li><a href="../api/npm.html">npm(3)</a></li></ul>
 </div>
-<p id="footer">npm &mdash; npm@1.2.0</p>
+<p id="footer">npm &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 139afe3..b3c1606 100644 (file)
@@ -21,7 +21,7 @@ packages are currently outdated.</p>
 
 <ul><li><a href="../doc/update.html">update(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li></ul>
 </div>
-<p id="footer">outdated &mdash; npm@1.2.0</p>
+<p id="footer">outdated &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 0ac94e8..8228fb0 100644 (file)
@@ -34,7 +34,7 @@ that is not implemented at this time.</p>
 
 <ul><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/adduser.html">adduser(1)</a></li><li><a href="../doc/disputes.html">disputes(1)</a></li></ul>
 </div>
-<p id="footer">owner &mdash; npm@1.2.0</p>
+<p id="footer">owner &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index ddebcc2..3dc318d 100644 (file)
@@ -29,7 +29,7 @@ overwritten the second time.</p>
 
 <ul><li><a href="../doc/cache.html">cache(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">pack &mdash; npm@1.2.0</p>
+<p id="footer">pack &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index af3da4c..bdde2a5 100644 (file)
@@ -20,7 +20,7 @@
 
 <ul><li><a href="../doc/root.html">root(1)</a></li><li><a href="../doc/bin.html">bin(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">prefix &mdash; npm@1.2.0</p>
+<p id="footer">prefix &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 2411551..bc97027 100644 (file)
@@ -25,7 +25,7 @@ package&#39;s dependencies list.</p>
 
 <ul><li><a href="../doc/rm.html">rm(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/list.html">list(1)</a></li></ul>
 </div>
-<p id="footer">prune &mdash; npm@1.2.0</p>
+<p id="footer">prune &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index a73e074..a24ca2d 100644 (file)
@@ -29,7 +29,7 @@ the registry.  Overwrites when the &quot;--force&quot; flag is set.</p>
 
 <ul><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/adduser.html">adduser(1)</a></li><li><a href="../doc/owner.html">owner(1)</a></li><li><a href="../doc/deprecate.html">deprecate(1)</a></li><li><a href="../doc/tag.html">tag(1)</a></li></ul>
 </div>
-<p id="footer">publish &mdash; npm@1.2.0</p>
+<p id="footer">publish &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 3f2b6ec..2c6a4e1 100644 (file)
@@ -25,7 +25,7 @@ the new binary.</p>
 
 <ul><li><a href="../doc/build.html">build(1)</a></li><li><a href="../doc/install.html">install(1)</a></li></ul>
 </div>
-<p id="footer">rebuild &mdash; npm@1.2.0</p>
+<p id="footer">rebuild &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index bf54497..7e618b7 100644 (file)
@@ -95,7 +95,7 @@ ask for help on the <a href="mailto:npm-@googlegroups.com">npm-@googlegroups.com
 
 <ul><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/developers.html">developers(1)</a></li><li><a href="../doc/disputes.html">disputes(1)</a></li></ul>
 </div>
-<p id="footer">registry &mdash; npm@1.2.0</p>
+<p id="footer">registry &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 246f4de..36f1c62 100644 (file)
@@ -58,7 +58,7 @@ modules.  To track those down, you can do the following:</p>
 
 <ul><li><a href="../doc/README.html">README</a></li><li><a href="../doc/rm.html">rm(1)</a></li><li><a href="../doc/prune.html">prune(1)</a></li></ul>
 </div>
-<p id="footer">removing-npm &mdash; npm@1.2.0</p>
+<p id="footer">removing-npm &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 37e3124..fd21f56 100644 (file)
@@ -24,7 +24,7 @@ the &quot;start&quot; script.</p>
 
 <ul><li><a href="../doc/run-script.html">run-script(1)</a></li><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/test.html">test(1)</a></li><li><a href="../doc/start.html">start(1)</a></li><li><a href="../doc/stop.html">stop(1)</a></li></ul>
 </div>
-<p id="footer">restart &mdash; npm@1.2.0</p>
+<p id="footer">restart &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 2124ad2..0973dd8 100644 (file)
@@ -20,7 +20,7 @@
 
 <ul><li><a href="../doc/prefix.html">prefix(1)</a></li><li><a href="../doc/bin.html">bin(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">root &mdash; npm@1.2.0</p>
+<p id="footer">root &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 90c6809..b353786 100644 (file)
@@ -23,7 +23,7 @@ called directly, as well.</p>
 
 <ul><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/test.html">test(1)</a></li><li><a href="../doc/start.html">start(1)</a></li><li><a href="../doc/restart.html">restart(1)</a></li><li><a href="../doc/stop.html">stop(1)</a></li></ul>
 </div>
-<p id="footer">run-script &mdash; npm@1.2.0</p>
+<p id="footer">run-script &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 24913f3..d6beacf 100644 (file)
@@ -218,7 +218,7 @@ will sudo the npm command in question.</li></ul>
 
 <ul><li><a href="../doc/run-script.html">run-script(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/developers.html">developers(1)</a></li><li><a href="../doc/install.html">install(1)</a></li></ul>
 </div>
-<p id="footer">scripts &mdash; npm@1.2.0</p>
+<p id="footer">scripts &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index e072a01..0554e40 100644 (file)
@@ -24,7 +24,7 @@ expression characters must be escaped or quoted in most shells.)</p>
 
 <ul><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/view.html">view(1)</a></li></ul>
 </div>
-<p id="footer">search &mdash; npm@1.2.0</p>
+<p id="footer">search &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 9dddfc5..c0206e1 100644 (file)
@@ -104,7 +104,7 @@ that satisfies the range, or null if none of them do.</li></ul>
 
 <ul><li><a href="../doc/json.html">json(1)</a></li></ul>
 </div>
-<p id="footer">semver &mdash; npm@1.2.0</p>
+<p id="footer">semver &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 99b10e9..7389ebf 100644 (file)
@@ -169,7 +169,7 @@ versions.</p>
 
 <ul><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/list.html">list(1)</a></li></ul>
 </div>
-<p id="footer">shrinkwrap &mdash; npm@1.2.0</p>
+<p id="footer">shrinkwrap &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index df1736f..b896fae 100644 (file)
@@ -26,7 +26,7 @@ a vaguely positive way to show that you care.</p>
 
 <ul><li><a href="../doc/view.html">view(1)</a></li><li><a href="../doc/whoami.html">whoami(1)</a></li><li><a href="../doc/adduser.html">adduser(1)</a></li></ul>
 </div>
-<p id="footer">star &mdash; npm@1.2.0</p>
+<p id="footer">star &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 52bfefe..bcc3dbb 100644 (file)
@@ -20,7 +20,7 @@
 
 <ul><li><a href="../doc/run-script.html">run-script(1)</a></li><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/test.html">test(1)</a></li><li><a href="../doc/restart.html">restart(1)</a></li><li><a href="../doc/stop.html">stop(1)</a></li></ul>
 </div>
-<p id="footer">start &mdash; npm@1.2.0</p>
+<p id="footer">start &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 77001af..59a3a3f 100644 (file)
@@ -20,7 +20,7 @@
 
 <ul><li><a href="../doc/run-script.html">run-script(1)</a></li><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/test.html">test(1)</a></li><li><a href="../doc/start.html">start(1)</a></li><li><a href="../doc/restart.html">restart(1)</a></li></ul>
 </div>
-<p id="footer">stop &mdash; npm@1.2.0</p>
+<p id="footer">stop &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 3b9411c..9eadc8b 100644 (file)
@@ -33,7 +33,7 @@ dependencies into the submodule folder.</p>
 
 <ul><li><a href="../doc/json.html">json(1)</a></li><li>git help submodule</li></ul>
 </div>
-<p id="footer">submodule &mdash; npm@1.2.0</p>
+<p id="footer">submodule &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 0247e51..8ff5d51 100644 (file)
@@ -21,7 +21,7 @@
 
 <ul><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">tag &mdash; npm@1.2.0</p>
+<p id="footer">tag &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index d16aad6..ee09bfe 100644 (file)
@@ -23,7 +23,7 @@ true.</p>
 
 <ul><li><a href="../doc/run-script.html">run-script(1)</a></li><li><a href="../doc/scripts.html">scripts(1)</a></li><li><a href="../doc/start.html">start(1)</a></li><li><a href="../doc/restart.html">restart(1)</a></li><li><a href="../doc/stop.html">stop(1)</a></li></ul>
 </div>
-<p id="footer">test &mdash; npm@1.2.0</p>
+<p id="footer">test &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 25bd0b4..de8dc5f 100644 (file)
@@ -22,7 +22,7 @@ on its behalf.</p>
 
 <ul><li><a href="../doc/prune.html">prune(1)</a></li><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/config.html">config(1)</a></li></ul>
 </div>
-<p id="footer">uninstall &mdash; npm@1.2.0</p>
+<p id="footer">uninstall &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index f2c38c0..8766a0a 100644 (file)
@@ -34,7 +34,7 @@ the root package entry is removed from the registry entirely.</p>
 
 <ul><li><a href="../doc/deprecate.html">deprecate(1)</a></li><li><a href="../doc/publish.html">publish(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/adduser.html">adduser(1)</a></li><li><a href="../doc/owner.html">owner(1)</a></li></ul>
 </div>
-<p id="footer">unpublish &mdash; npm@1.2.0</p>
+<p id="footer">unpublish &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 65daa90..bec6bcb 100644 (file)
@@ -23,7 +23,7 @@
 
 <ul><li><a href="../doc/install.html">install(1)</a></li><li><a href="../doc/outdated.html">outdated(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/folders.html">folders(1)</a></li><li><a href="../doc/list.html">list(1)</a></li></ul>
 </div>
-<p id="footer">update &mdash; npm@1.2.0</p>
+<p id="footer">update &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 1712c2c..c1d13a2 100644 (file)
@@ -40,7 +40,7 @@ in your git config for this to work properly.</p>
 
 <ul><li><a href="../doc/init.html">init(1)</a></li><li><a href="../doc/json.html">json(1)</a></li><li><a href="../doc/semver.html">semver(1)</a></li></ul>
 </div>
-<p id="footer">version &mdash; npm@1.2.0</p>
+<p id="footer">version &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 2b988f3..0fcc49c 100644 (file)
@@ -90,7 +90,7 @@ the field name.</p>
 
 <ul><li><a href="../doc/search.html">search(1)</a></li><li><a href="../doc/registry.html">registry(1)</a></li><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/docs.html">docs(1)</a></li></ul>
 </div>
-<p id="footer">view &mdash; npm@1.2.0</p>
+<p id="footer">view &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 33a3ca9..a0ee7b9 100644 (file)
@@ -20,7 +20,7 @@
 
 <ul><li><a href="../doc/config.html">config(1)</a></li><li><a href="../doc/adduser.html">adduser(1)</a></li></ul>
 </div>
-<p id="footer">whoami &mdash; npm@1.2.0</p>
+<p id="footer">whoami &mdash; npm@1.2.2</p>
 <script>
 ;(function () {
 var wrapper = document.getElementById("wrapper")
index 07f4d3e..7b83350 100644 (file)
@@ -51,14 +51,16 @@ adding a local tarball:
 */
 
 exports = module.exports = cache
-exports.read = read
-exports.clean = clean
-exports.unpack = unpack
-exports.lock = lock
-exports.unlock = unlock
+cache.read = read
+cache.clean = clean
+cache.unpack = unpack
+cache.lock = lock
+cache.unlock = unlock
 
 var mkdir = require("mkdirp")
   , exec = require("./utils/exec.js")
+  , spawn = require("child_process").spawn
+  , once = require("once")
   , fetch = require("./utils/fetch.js")
   , npm = require("./npm.js")
   , fs = require("graceful-fs")
@@ -77,6 +79,7 @@ var mkdir = require("mkdirp")
   , lockFile = require("lockfile")
   , crypto = require("crypto")
   , retry = require("retry")
+  , zlib = require("zlib")
 
 cache.usage = "npm cache add <tarball file>"
             + "\nnpm cache add <folder>"
@@ -151,7 +154,7 @@ function ls (args, cb) {
   if (0 === prefix.indexOf(process.env.HOME)) {
     prefix = "~" + prefix.substr(process.env.HOME.length)
   }
-  ls_(args, npm.config.get("depth"), function(er, files) {
+  ls_(args, npm.config.get("depth"), function (er, files) {
     console.log(files.map(function (f) {
       return path.join(prefix, f)
     }).join("\n").trim())
@@ -188,7 +191,7 @@ function clean (args, cb) {
 // npm cache add <pkg> <ver>
 // npm cache add <tarball>
 // npm cache add <folder>
-exports.add = function (pkg, ver, scrub, cb) {
+cache.add = function (pkg, ver, scrub, cb) {
   if (typeof cb !== "function") cb = scrub, scrub = false
   if (typeof cb !== "function") cb = ver, ver = null
   if (scrub) {
@@ -230,7 +233,7 @@ function add (args, cb) {
     spec = args[0]
   }
 
-  log.silly("cache add", "name=%j spec=%j args=%j", name, spec, args)
+  log.verbose("cache add", "name=%j spec=%j args=%j", name, spec, args)
 
 
   if (!name && !spec) return cb(usage)
@@ -298,6 +301,10 @@ function addRemoteTarball (u, shasum, name, cb_) {
   if (iF.length > 1) return
 
   function cb (er, data) {
+    if (data) {
+      data._from = u
+      data._resolved = u
+    }
     unlock(u, function () {
       var c
       while (c = iF.shift()) c(er, data)
@@ -305,46 +312,55 @@ function addRemoteTarball (u, shasum, name, cb_) {
     })
   }
 
+  var tmp = path.join(npm.tmp, Date.now()+"-"+Math.random(), "tmp.tgz")
+
   lock(u, function (er) {
     if (er) return cb(er)
 
     log.verbose("addRemoteTarball", [u, shasum])
-    var tmp = path.join(npm.tmp, Date.now()+"-"+Math.random(), "tmp.tgz")
     mkdir(path.dirname(tmp), function (er) {
       if (er) return cb(er)
-      // Tuned to spread 3 attempts over about a minute.
-      // See formula at <https://github.com/tim-kos/node-retry>.
-      var operation = retry.operation
-        ( { retries: npm.config.get("fetch-retries")
-          , factor: npm.config.get("fetch-retry-factor")
-          , minTimeout: npm.config.get("fetch-retry-mintimeout")
-          , maxTimeout: npm.config.get("fetch-retry-maxtimeout") })
-
-      operation.attempt(function (currentAttempt) {
-        log.info("retry", "fetch attempt " + currentAttempt
-          + " at " + (new Date()).toLocaleTimeString())
-        fetchAndShaCheck(u, tmp, shasum, function (er, response) {
-          // Only retry on 408, 5xx or no `response`.
-          var statusCode = response && response.statusCode
-          var statusRetry = !statusCode || (statusCode === 408 || statusCode >= 500)
-          if (er && statusRetry && operation.retry(er)) {
-            log.info("retry", "will retry, error on last attempt: " + er)
-            return
-          }
-          done(er)
-        })
-      })
+      addRemoteTarball_(u, tmp, shasum, done)
+    })
+  })
+
+  function done (er) {
+    if (er) return cb(er)
+    addLocalTarball(tmp, name, cb)
+  }
+}
+
+function addRemoteTarball_(u, tmp, shasum, cb) {
+  // Tuned to spread 3 attempts over about a minute.
+  // See formula at <https://github.com/tim-kos/node-retry>.
+  var operation = retry.operation
+    ( { retries: npm.config.get("fetch-retries")
+      , factor: npm.config.get("fetch-retry-factor")
+      , minTimeout: npm.config.get("fetch-retry-mintimeout")
+      , maxTimeout: npm.config.get("fetch-retry-maxtimeout") })
+
+  operation.attempt(function (currentAttempt) {
+    log.info("retry", "fetch attempt " + currentAttempt
+      + " at " + (new Date()).toLocaleTimeString())
+    fetchAndShaCheck(u, tmp, shasum, function (er, response) {
+      // Only retry on 408, 5xx or no `response`.
+      var sc = response && response.statusCode
+      var statusRetry = !sc || (sc === 408 || sc >= 500)
+      if (er && statusRetry && operation.retry(er)) {
+        log.info("retry", "will retry, error on last attempt: " + er)
+        return
+      }
+      cb(er)
     })
-    function done (er) {
-      if (er) return cb(er)
-      addLocalTarball(tmp, name, cb)
-    }
   })
 }
 
-// For now, this is kind of dumb.  Just basically treat git as
-// yet another "fetch and scrub" kind of thing.
-// Clone to temp folder, then proceed with the addLocal stuff.
+// 1. cacheDir = path.join(cache,'_git-remotes',sha1(u))
+// 2. checkGitDir(cacheDir) ? 4. : 3. (rm cacheDir if necessary)
+// 3. git clone --mirror u cacheDir
+// 4. cd cacheDir && git fetch -a origin
+// 5. git archive /tmp/random.tgz
+// 6. addLocalTarball(/tmp/random.tgz) <gitref> --format=tar --prefix=package/
 function addRemoteGit (u, parsed, name, cb_) {
   if (typeof cb_ !== "function") cb_ = name, name = null
 
@@ -361,6 +377,8 @@ function addRemoteGit (u, parsed, name, cb_) {
     })
   }
 
+  var p, co // cachePath, git-ref we want to check out
+
   lock(u, function (er) {
     if (er) return cb(er)
 
@@ -379,34 +397,125 @@ function addRemoteGit (u, parsed, name, cb_) {
       u = u.replace(/^ssh:\/\//, "")
     }
 
+    var v = crypto.createHash("sha1").update(u).digest("hex").slice(0, 8)
+    v = u.replace(/[^a-zA-Z0-9]+/g, '-') + '-' + v
+
     log.verbose("addRemoteGit", [u, co])
 
-    var tmp = path.join(npm.tmp, Date.now()+"-"+Math.random())
-    mkdir(path.dirname(tmp), function (er) {
+    p = path.join(npm.config.get("cache"), "_git-remotes", v)
+
+    checkGitDir(p, u, co, cb)
+  })
+}
+
+function checkGitDir (p, u, co, cb) {
+  fs.stat(p, function (er, s) {
+    if (er) return cloneGitRemote(p, u, co, cb)
+    if (!s.isDirectory()) return rm(p, function (er){
       if (er) return cb(er)
-      exec( npm.config.get("git"), ["clone", u, tmp], gitEnv(), false
-          , function (er, code, stdout, stderr) {
-        stdout = (stdout + "\n" + stderr).trim()
-        if (er) {
-          log.error("git clone " + u, stdout)
-          return cb(er)
-        }
-        log.verbose("git clone "+u, stdout)
-        exec( npm.config.get("git"), ["checkout", co], gitEnv(), false, tmp
-            , function (er, code, stdout, stderr) {
-          stdout = (stdout + "\n" + stderr).trim()
-          if (er) {
-            log.error("git checkout " + co, stdout)
-            return cb(er)
-          }
-          log.verbose("git checkout " + co, stdout)
-          addLocalDirectory(tmp, cb)
+      cloneGitRemote(p, u, co, cb)
+    })
+
+    var git = npm.config.get("git")
+    var args = ["config", "--get", "remote.origin.url"]
+    var env = gitEnv()
+
+    exec(git, args, env, false, p, function (er, code, stdout, stderr) {
+      stdoutTrimmed = (stdout + "\n" + stderr).trim()
+      if (er || u !== stdout.trim()) {
+        log.warn( "`git config --get remote.origin.url` returned "
+                + "wrong result ("+u+")", stdoutTrimmed )
+        return rm(p, function (er){
+          if (er) return cb(er)
+          cloneGitRemote(p, u, co, cb)
         })
-      })
+      }
+      log.verbose("git remote.origin.url", stdoutTrimmed)
+      archiveGitRemote(p, u, co, cb)
+    })
+  })
+}
+
+function cloneGitRemote (p, u, co, cb) {
+  mkdir(p, function (er) {
+    if (er) return cb(er)
+    exec( npm.config.get("git"), ["clone", "--mirror", u, p], gitEnv(), false
+        , function (er, code, stdout, stderr) {
+      stdout = (stdout + "\n" + stderr).trim()
+      if (er) {
+        log.error("git clone " + u, stdout)
+        return cb(er)
+      }
+      log.verbose("git clone " + u, stdout)
+      archiveGitRemote(p, u, co, cb)
     })
   })
 }
 
+function archiveGitRemote (p, u, co, cb) {
+  var git = npm.config.get("git")
+  var archive = ["fetch", "-a", "origin"]
+  var resolve = ["rev-list", "-n1", co]
+  var env = gitEnv()
+
+  var errState = null
+  var n = 0
+  var resolved = null
+  var tmp
+
+  exec(git, archive, env, false, p, function (er, code, stdout, stderr) {
+    stdout = (stdout + "\n" + stderr).trim()
+    if (er) {
+      log.error("git fetch -a origin ("+u+")", stdout)
+      return next(er)
+    }
+    log.verbose("git fetch -a origin ("+u+")", stdout)
+    tmp = path.join(npm.tmp, Date.now()+"-"+Math.random(), "tmp.tgz")
+    next()
+  })
+
+  exec(git, resolve, env, false, p, function (er, code, stdout, stderr) {
+    stdout = (stdout + "\n" + stderr).trim()
+    if (er) {
+      log.error("Failed resolving git HEAD (" + u + ")", stderr)
+      return next(er)
+    }
+    log.verbose("git rev-list -n1 " + co, stdout)
+    var parsed = url.parse(u)
+    parsed.hash = stdout
+    resolved = url.format(parsed)
+    next()
+  })
+
+  function next (er) {
+    if (errState) return
+    if (er) return cb(errState = er)
+
+    if (++n < 2) return
+
+    mkdir(path.dirname(tmp), function (er) {
+      if (er) return cb(er)
+      var gzip = zlib.createGzip({ level: 9 })
+      var git = npm.config.get("git")
+      var args = ["archive", co, "--format=tar", "--prefix=package/"]
+      var out = fs.createWriteStream(tmp)
+      var env = gitEnv()
+      cb = once(cb)
+      var cp = spawn(git, args, { env: env, cwd: p })
+      cp.on("error", cb)
+      cp.stderr.on("data", function(chunk) {
+        log.silly(chunk.toString(), "git archive")
+      })
+
+      cp.stdout.pipe(gzip).pipe(out).on("close", function() {
+        addLocalTarball(tmp, function(er, data) {
+          if (data) data._resolved = resolved
+          cb(er, data)
+        })
+      })
+    })
+  }
+}
 
 var gitEnv_
 function gitEnv () {
@@ -436,6 +545,7 @@ function addNamed (name, x, data, cb_) {
   if (iF.length > 1) return
 
   function cb (er, data) {
+    if (data && !data._fromGithub) data._from = k
     unlock(k, function () {
       var c
       while (c = iF.shift()) c(er, data)
@@ -643,6 +753,7 @@ function addLocal (p, name, cb_) {
         log.error("addLocal", "Could not install %s", p)
         return cb_(er)
       }
+      if (data && !data._fromGithub) data._from = p
       return cb_(er, data)
     })
   }
@@ -666,31 +777,33 @@ function addLocal (p, name, cb_) {
 }
 
 function maybeGithub (p, name, er, cb) {
-  var u = "https://github.com/" + p
+  var u = "git://github.com/" + p
     , up = url.parse(u)
-  if (up.hash && up.hash[0] === "#")
-    up.hash = up.hash.slice(1)
-
-  var ref = encodeURIComponent(up.hash || "master")
-  up.pathname = path.join(up.pathname, "tarball", ref).replace(/\\/g, "/")
-  u = url.format(up)
   log.info("maybeGithub", "Attempting to fetch %s from %s", p, u)
-  return addRemoteTarball(u, null, name, function (er2, data) {
+
+  return addRemoteGit(u, up, name, function (er2, data) {
     if (er2) return cb(er)
+    data._from = u
+    data._fromGithub = true
     return cb(null, data)
   })
 }
 
-function addLocalTarball (p, name, cb) {
-  if (typeof cb !== "function") cb = name, name = ""
+function addLocalTarball (p, name, cb_) {
+  if (typeof cb_ !== "function") cb_ = name, name = ""
   // if it's a tar, and not in place,
   // then unzip to .tmp, add the tmp folder, and clean up tmp
-  if (p.indexOf(npm.tmp) === 0) return addTmpTarball(p, name, cb)
+  if (p.indexOf(npm.tmp) === 0) return addTmpTarball(p, name, cb_)
 
   if (p.indexOf(npm.cache) === 0) {
-    if (path.basename(p) !== "package.tgz") return cb(new Error(
+    if (path.basename(p) !== "package.tgz") return cb_(new Error(
       "Not a valid cache tarball name: "+p))
-    return addPlacedTarball(p, name, cb)
+    return addPlacedTarball(p, name, cb_)
+  }
+
+  function cb (er, data) {
+    if (data) data._resolved = p
+    return cb_(er, data)
   }
 
   // just copy it over and then add the temp tarball file.
index 4741c34..ef5ef14 100644 (file)
@@ -207,8 +207,7 @@ function readDependencies (context, where, opts, cb) {
       rv.dependencies = {}
       Object.keys(wrap).forEach(function (key) {
         log.verbose("from wrap", [key, wrap[key]])
-        var w = wrap[key]
-        rv.dependencies[key] = w.from || w.version
+        rv.dependencies[key] = readWrap(wrap[key])
       })
       log.verbose("readDependencies returned deps", rv.dependencies)
       return cb(null, rv, wrap)
@@ -235,8 +234,7 @@ function readDependencies (context, where, opts, cb) {
       })
       rv.dependencies = {}
       Object.keys(newwrap.dependencies || {}).forEach(function (key) {
-        var w = newwrap.dependencies[key]
-        rv.dependencies[key] = w.from || w.version
+        rv.dependencies[key] = readWrap(newwrap.dependencies[key])
       })
       log.verbose("readDependencies returned deps", rv.dependencies)
       return cb(null, rv, newwrap.dependencies)
@@ -244,6 +242,12 @@ function readDependencies (context, where, opts, cb) {
   })
 }
 
+function readWrap (w) {
+  return (w.resolved) ? w.resolved
+       : (w.from && url.parse(w.from).protocol) ? w.from
+       : w.version
+}
+
 // if the -S|--save option is specified, then write installed packages
 // as dependencies to a package.json file.
 // This is experimental.
@@ -301,6 +305,7 @@ function save (where, installed, tree, pretty, cb) {
       data.bundleDependencies = bundle
     }
 
+    log.verbose('saving', things)
     data[deps] = data[deps] || {}
     Object.keys(things).forEach(function (t) {
       data[deps][t] = things[t]
@@ -588,8 +593,7 @@ function targetResolver (where, context, deps) {
     if (wrap) {
       name = what.split(/@/).shift()
       if (wrap[name]) {
-        var wrapTarget = wrap[name].from || wrap[name].version
-        log.verbose("shrinkwrap", "resolving %s to %s", wrapTarget, what)
+        var wrapTarget = readWrap(wrap[name])
         what = name + "@" + wrapTarget
       } else {
         log.verbose("shrinkwrap", "skipping %s (not in shrinkwrap)", what)
@@ -615,7 +619,7 @@ function targetResolver (where, context, deps) {
         return cb(null, [])
       }
 
-      if (data) data._from = what
+      if (data && !data._from) data._from = what
 
       return cb(er, data)
     })
index 637064e..c1d2220 100644 (file)
@@ -95,14 +95,11 @@ function getLite (data, noname) {
                       + " " + (data.path || "") )
   }
 
-  if (data._from) {
-    var from = data._from
-    if (from.indexOf(data.name + "@") === 0) {
-      from = from.substr(data.name.length + 1)
-    }
-    var u = url.parse(from)
-    if (u.protocol) lite.from = from
-  }
+  if (data._from)
+    lite.from = data._from
+
+  if (data._resolved)
+    lite.resolved = data._resolved
 
   if (data.invalid) {
     lite.invalid = true
index f009607..da39eee 100644 (file)
@@ -97,6 +97,7 @@ var commandCache = {}
               , "se" : "search"
               , "author" : "owner"
               , "home" : "docs"
+              , "issues": "bugs"
               , "unstar": "star" // same function
               , "apihelp" : "help"
               , "login": "adduser"
index 027ea59..e22719f 100644 (file)
@@ -42,8 +42,13 @@ function publish (args, isRetry, cb) {
   })
 }
 
-function cacheAddPublish (arg, didPre, isRetry, cb) {
-  npm.commands.cache.add(arg, function (er, data) {
+// didPre in this case means that we already ran the prepublish script,
+// and that the "dir" is an actual directory, and not something silly
+// like a tarball or name@version thing.
+// That means that we can run publish/postpublish in the dir, rather than
+// in the cache dir.
+function cacheAddPublish (dir, didPre, isRetry, cb) {
+  npm.commands.cache.add(dir, function (er, data) {
     if (er) return cb(er)
     log.silly("publish", data)
     var cachedir = path.resolve( npm.cache
@@ -52,9 +57,9 @@ function cacheAddPublish (arg, didPre, isRetry, cb) {
                                , "package" )
     chain
       ( [ !didPre && [lifecycle, data, "prepublish", cachedir]
-        , [publish_, arg, data, isRetry, cachedir]
-        , [lifecycle, data, "publish", cachedir]
-        , [lifecycle, data, "postpublish", cachedir] ]
+        , [publish_, dir, data, isRetry, cachedir]
+        , [lifecycle, data, "publish", didPre ? dir : cachedir]
+        , [lifecycle, data, "postpublish", didPre ? dir : cachedir] ]
       , cb )
   })
 }
index 56d331a..70f0a13 100644 (file)
@@ -51,7 +51,7 @@ function exec (cmd, args, env, takeOver, cwd, uid, gid, cb) {
   cp.stderr && cp.stderr.on("data", function (chunk) {
     if (chunk) stderr += chunk
   })
-  cp.on("exit", function (code) {
+  cp.on("close", function (code) {
     var er = null
     if (code) er = new Error("`"+cmd
                             +(args.length ? " "
index 825edc9..ba5cee5 100644 (file)
@@ -70,6 +70,12 @@ function lifecycle_ (pkg, stage, wd, env, unsafe, failOk, cb) {
   var pathArr = []
     , p = wd.split("node_modules")
     , acc = path.resolve(p.shift())
+
+  // first add the directory containing the `node` executable currently
+  // running, so that any lifecycle script that invoke "node" will execute
+  // this same one.
+  pathArr.unshift(path.dirname(process.execPath))
+
   p.forEach(function (pp) {
     pathArr.unshift(path.join(acc, "node_modules", ".bin"))
     acc = path.join(acc, "node_modules", pp)
@@ -80,10 +86,6 @@ function lifecycle_ (pkg, stage, wd, env, unsafe, failOk, cb) {
   // the bundled one will be used for installing things.
   pathArr.unshift(path.join(__dirname, "..", "..", "bin", "node-gyp-bin"))
 
-  // add the directory containing the `node` executable currently running, so
-  // that any lifecycle script that invoke "node" will execute this same one.
-  pathArr.unshift(path.dirname(process.execPath))
-
   if (env[PATH]) pathArr.push(env[PATH])
   env[PATH] = pathArr.join(process.platform === "win32" ? ";" : ":")
 
index 5d738ba..3a84bbd 100644 (file)
@@ -36,7 +36,7 @@ function pack (targetTarball, folder, pkg, dfc, cb) {
 
   if (dfc) {
     // do fancy crap
-    return lifecycle(pkg, 'prepublish', folder, function (er) {
+    return lifecycle(pkg, "prepublish", folder, function (er) {
       if (er) return cb(er)
       pack_(targetTarball, folder, pkg, cb)
     })
@@ -191,7 +191,7 @@ function gunzTarPerm (tarball, target, dMode, fMode, uid, gid, cb_) {
     if (this.type.match(/^.*Link$/)) {
       log.warn( "excluding symbolic link"
               , this.path.substr(target.length + 1)
-              + ' -> ' + this.linkpath )
+              + " -> " + this.linkpath )
       return false
     }
     return true
index 0b3aeb6..272e451 100644 (file)
@@ -29,7 +29,7 @@ For example, running \fBnpm ls promzard\fR in npm\'s source tree will show:
 .IP "" 4
 .
 .nf
-npm@1.2.0 /path/to/npm
+npm@1.2.2 /path/to/npm
 â””─┬ init\-package\-json@0\.0\.4
   â””── promzard@0\.1\.5
 .
index a152584..93fc999 100644 (file)
@@ -14,7 +14,7 @@ npm <command> [args]
 .fi
 .
 .SH "VERSION"
-1.2.0
+1.2.2
 .
 .SH "DESCRIPTION"
 npm is the package manager for the Node JavaScript platform\.  It puts
index 69a7507..a02644c 100644 (file)
@@ -21,7 +21,7 @@ npm\.load(configObject, function (er, npm) {
 .fi
 .
 .SH "VERSION"
-1.2.0
+1.2.2
 .
 .SH "DESCRIPTION"
 This is the API documentation for npm\.
index 037de2d..bee4132 100644 (file)
@@ -4,8 +4,15 @@ module.exports = exports = abbrev.abbrev = abbrev
 abbrev.monkeyPatch = monkeyPatch
 
 function monkeyPatch () {
-  Array.prototype.abbrev = function () { return abbrev(this) }
-  Object.prototype.abbrev = function () { return abbrev(Object.keys(this)) }
+  Object.defineProperty(Array.prototype, 'abbrev', {
+    value: function () { return abbrev(this) },
+    enumerable: false, configurable: true, writable: true
+  })
+
+  Object.defineProperty(Object.prototype, 'abbrev', {
+    value: function () { return abbrev(Object.keys(this)) },
+    enumerable: false, configurable: true, writable: true
+  })
 }
 
 function abbrev (list) {
@@ -32,8 +39,7 @@ function abbrev (list) {
       var curChar = current.charAt(j)
       nextMatches = nextMatches && curChar === next.charAt(j)
       prevMatches = prevMatches && curChar === prev.charAt(j)
-      if (nextMatches || prevMatches) continue
-      else {
+      if (!nextMatches && !prevMatches) {
         j ++
         break
       }
@@ -60,19 +66,18 @@ function lexSort (a, b) {
 if (module === require.main) {
 
 var assert = require("assert")
-  , sys
-sys = require("util")
+var util = require("util")
 
 console.log("running tests")
 function test (list, expect) {
   var actual = abbrev(list)
   assert.deepEqual(actual, expect,
-    "abbrev("+sys.inspect(list)+") === " + sys.inspect(expect) + "\n"+
-    "actual: "+sys.inspect(actual))
+    "abbrev("+util.inspect(list)+") === " + util.inspect(expect) + "\n"+
+    "actual: "+util.inspect(actual))
   actual = abbrev.apply(exports, list)
   assert.deepEqual(abbrev.apply(exports, list), expect,
-    "abbrev("+list.map(JSON.stringify).join(",")+") === " + sys.inspect(expect) + "\n"+
-    "actual: "+sys.inspect(actual))
+    "abbrev("+list.map(JSON.stringify).join(",")+") === " + util.inspect(expect) + "\n"+
+    "actual: "+util.inspect(actual))
 }
 
 test([ "ruby", "ruby", "rules", "rules", "rules" ],
index 045cbd4..bea853e 100644 (file)
@@ -1,11 +1,25 @@
-{ "name" : "abbrev"
-, "version" : "1.0.3"
-, "description" : "Like ruby's abbrev module, but in js"
-, "author" : "Isaac Z. Schlueter <i@izs.me>"
-, "main" : "./lib/abbrev.js"
-, "scripts" : { "test" : "node lib/abbrev.js" }
-, "repository" : "http://github.com/isaacs/abbrev-js"
-, "license" :
-  { "type" : "MIT"
-  , "url" : "https://github.com/isaacs/abbrev-js/raw/master/LICENSE" }
+{
+  "name": "abbrev",
+  "version": "1.0.4",
+  "description": "Like ruby's abbrev module, but in js",
+  "author": {
+    "name": "Isaac Z. Schlueter",
+    "email": "i@izs.me"
+  },
+  "main": "./lib/abbrev.js",
+  "scripts": {
+    "test": "node lib/abbrev.js"
+  },
+  "repository": {
+    "type": "git",
+    "url": "http://github.com/isaacs/abbrev-js"
+  },
+  "license": {
+    "type": "MIT",
+    "url": "https://github.com/isaacs/abbrev-js/raw/master/LICENSE"
+  },
+  "readme": "# abbrev-js\n\nJust like [ruby's Abbrev](http://apidock.com/ruby/Abbrev).\n\nUsage:\n\n    var abbrev = require(\"abbrev\");\n    abbrev(\"foo\", \"fool\", \"folding\", \"flop\");\n    \n    // returns:\n    { fl: 'flop'\n    , flo: 'flop'\n    , flop: 'flop'\n    , fol: 'folding'\n    , fold: 'folding'\n    , foldi: 'folding'\n    , foldin: 'folding'\n    , folding: 'folding'\n    , foo: 'foo'\n    , fool: 'fool'\n    }\n\nThis is handy for command-line scripts, or other cases where you want to be able to accept shorthands.\n",
+  "readmeFilename": "README.md",
+  "_id": "abbrev@1.0.4",
+  "_from": "abbrev@latest"
 }
diff --git a/deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/LICENSE b/deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/LICENSE
new file mode 100644 (file)
index 0000000..0c44ae7
--- /dev/null
@@ -0,0 +1,27 @@
+Copyright (c) Isaac Z. Schlueter ("Author")
+All rights reserved.
+
+The BSD License
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+
+2. Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
index f1f95c4..fe8b93d 100644 (file)
@@ -6,7 +6,7 @@
   },
   "name": "fstream-ignore",
   "description": "A thing for ignoring files based on globs",
-  "version": "0.0.5",
+  "version": "0.0.6",
   "repository": {
     "type": "git",
     "url": "git://github.com/isaacs/fstream-ignore.git"
@@ -25,8 +25,9 @@
     "rimraf": "",
     "mkdirp": ""
   },
+  "license": "BSD",
   "readme": "# fstream-ignore\n\nA fstream DirReader that filters out files that match globs in `.ignore`\nfiles throughout the tree, like how git ignores files based on a\n`.gitignore` file.\n\nHere's an example:\n\n```javascript\nvar Ignore = require(\"fstream-ignore\")\nIgnore({ path: __dirname\n       , ignoreFiles: [\".ignore\", \".gitignore\"]\n       })\n  .on(\"child\", function (c) {\n    console.error(c.path.substr(c.root.path.length + 1))\n  })\n  .pipe(tar.Pack())\n  .pipe(fs.createWriteStream(\"foo.tar\"))\n```\n\nThis will tar up the files in __dirname into `foo.tar`, ignoring\nanything matched by the globs in any .iginore or .gitignore file.\n",
   "readmeFilename": "README.md",
-  "_id": "fstream-ignore@0.0.5",
+  "_id": "fstream-ignore@0.0.6",
   "_from": "fstream-ignore@~0.0.5"
 }
index 528197a..8805cb3 100644 (file)
@@ -20,5 +20,5 @@
   "readme": "# fstream-npm\n\nThis is an fstream DirReader class that will read a directory and filter\nthings according to the semantics of what goes in an npm package.\n\nFor example:\n\n```javascript\n// This will print out all the files that would be included\n// by 'npm publish' or 'npm install' of this directory.\n\nvar FN = require(\"fstream-npm\")\nFN({ path: \"./\" })\n  .on(\"child\", function (e) {\n    console.error(e.path.substr(e.root.path.length + 1))\n  })\n```\n\n",
   "readmeFilename": "README.md",
   "_id": "fstream-npm@0.1.3",
-  "_from": "fstream-npm@latest"
+  "_from": "fstream-npm@~0.1.3"
 }
index df90c72..30e9fdb 100755 (executable)
@@ -7,7 +7,11 @@ var nopt = require("../lib/nopt")
             , "num-list": [Number, Array]
             , "str-list": [String, Array]
             , "bool-list": [Boolean, Array]
-            , str: String }
+            , str: String
+            , clear: Boolean
+            , config: Boolean
+            , length: Number
+            }
   , shorthands = { s: [ "--str", "astring" ]
                  , b: [ "--bool" ]
                  , nb: [ "--no-bool" ]
@@ -15,7 +19,10 @@ var nopt = require("../lib/nopt")
                  , "?": ["--help"]
                  , h: ["--help"]
                  , H: ["--help"]
-                 , n: [ "--num", "125" ] }
+                 , n: [ "--num", "125" ]
+                 , c: ["--config"]
+                 , l: ["--length"]
+                 }
   , parsed = nopt( types
                  , shorthands
                  , process.argv
index 5763860..0e4ebc4 100644 (file)
@@ -50,7 +50,7 @@ function nopt (types, shorthands, args, slice) {
 function clean (data, types, typeDefs) {
   typeDefs = typeDefs || exports.typeDefs
   var remove = {}
-    , typeDefault = [false, true, null, String, Number]
+    , typeDefault = [false, true, null, String, Number, Array]
 
   Object.keys(data).forEach(function (k) {
     if (k === "argv") return
@@ -244,6 +244,7 @@ function parse (args, data, remain, types, shorthands) {
         v = v.join("=")
         args.splice.apply(args, [i, 1].concat([arg, v]))
       }
+
       // see if it's a shorthand
       // if so, splice and back up to re-parse it.
       var shRes = resolveShort(arg, shorthands, shortAbbr, abbrevs)
@@ -268,6 +269,13 @@ function parse (args, data, remain, types, shorthands) {
       var isArray = types[arg] === Array ||
         Array.isArray(types[arg]) && types[arg].indexOf(Array) !== -1
 
+      // allow unknown things to be arrays if specified multiple times.
+      if (!types.hasOwnProperty(arg) && data.hasOwnProperty(arg)) {
+        if (!Array.isArray(data[arg]))
+          data[arg] = [data[arg]]
+        isArray = true
+      }
+
       var val
         , la = args[i + 1]
 
@@ -341,32 +349,56 @@ function resolveShort (arg, shorthands, shortAbbr, abbrevs) {
   // all of the chars are single-char shorthands, and it's
   // not a match to some other abbrev.
   arg = arg.replace(/^-+/, '')
-  if (abbrevs[arg] && !shorthands[arg]) {
+
+  // if it's an exact known option, then don't go any further
+  if (abbrevs[arg] === arg)
     return null
+
+  // if it's an exact known shortopt, same deal
+  if (shorthands[arg]) {
+    // make it an array, if it's a list of words
+    if (shorthands[arg] && !Array.isArray(shorthands[arg]))
+      shorthands[arg] = shorthands[arg].split(/\s+/)
+
+    return shorthands[arg]
   }
-  if (shortAbbr[arg]) {
-    arg = shortAbbr[arg]
-  } else {
-    var singles = shorthands.___singles
-    if (!singles) {
-      singles = Object.keys(shorthands).filter(function (s) {
-        return s.length === 1
-      }).reduce(function (l,r) { l[r] = true ; return l }, {})
-      shorthands.___singles = singles
-    }
-    var chrs = arg.split("").filter(function (c) {
-      return singles[c]
-    })
-    if (chrs.join("") === arg) return chrs.map(function (c) {
-      return shorthands[c]
-    }).reduce(function (l, r) {
-      return l.concat(r)
-    }, [])
+
+  // first check to see if this arg is a set of single-char shorthands
+  var singles = shorthands.___singles
+  if (!singles) {
+    singles = Object.keys(shorthands).filter(function (s) {
+      return s.length === 1
+    }).reduce(function (l,r) {
+      l[r] = true
+      return l
+    }, {})
+    shorthands.___singles = singles
+    debug('shorthand singles', singles)
   }
 
-  if (shorthands[arg] && !Array.isArray(shorthands[arg])) {
+  var chrs = arg.split("").filter(function (c) {
+    return singles[c]
+  })
+
+  if (chrs.join("") === arg) return chrs.map(function (c) {
+    return shorthands[c]
+  }).reduce(function (l, r) {
+    return l.concat(r)
+  }, [])
+
+
+  // if it's an arg abbrev, and not a literal shorthand, then prefer the arg
+  if (abbrevs[arg] && !shorthands[arg])
+    return null
+
+  // if it's an abbr for a shorthand, then use that
+  if (shortAbbr[arg])
+    arg = shortAbbr[arg]
+
+  // make it an array, if it's a list of words
+  if (shorthands[arg] && !Array.isArray(shorthands[arg]))
     shorthands[arg] = shorthands[arg].split(/\s+/)
-  }
+
   return shorthands[arg]
 }
 
@@ -533,11 +565,26 @@ var assert = require("assert")
   ,["--date 2011-01-25"
    ,{date: new Date("2011-01-25")}
    ,[]]
+  ,["-cl 1"
+   ,{config: true, length: 1}
+   ,[]
+   ,{config: Boolean, length: Number, clear: Boolean}
+   ,{c: "--config", l: "--length"}]
+  ,["--acount bla"
+   ,{"acount":true}
+   ,["bla"]
+   ,{account: Boolean, credentials: Boolean, options: String}
+   ,{a:"--account", c:"--credentials",o:"--options"}]
+  ,["--clear"
+   ,{clear:true}
+   ,[]
+   ,{clear:Boolean,con:Boolean,len:Boolean,exp:Boolean,add:Boolean,rep:Boolean}
+   ,{c:"--con",l:"--len",e:"--exp",a:"--add",r:"--rep"}]
   ].forEach(function (test) {
     var argv = test[0].split(/\s+/)
       , opts = test[1]
       , rem = test[2]
-      , actual = nopt(types, shorthands, argv, 0)
+      , actual = nopt(test[3] || types, test[4] || shorthands, argv, 0)
       , parsed = actual.argv
     delete actual.argv
     console.log(util.inspect(actual, false, 2, true), parsed.remain)
index 4b09cb1..a605608 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "nopt",
-  "version": "2.0.0",
+  "version": "2.1.1",
   "description": "Option parsing for Node, supporting types, shorthands, etc. Used by npm.",
   "author": {
     "name": "Isaac Z. Schlueter",
@@ -26,6 +26,7 @@
     "abbrev": "1"
   },
   "readme": "If you want to write an option parser, and have it be good, there are\ntwo ways to do it.  The Right Way, and the Wrong Way.\n\nThe Wrong Way is to sit down and write an option parser.  We've all done\nthat.\n\nThe Right Way is to write some complex configurable program with so many\noptions that you go half-insane just trying to manage them all, and put\nit off with duct-tape solutions until you see exactly to the core of the\nproblem, and finally snap and write an awesome option parser.\n\nIf you want to write an option parser, don't write an option parser.\nWrite a package manager, or a source control system, or a service\nrestarter, or an operating system.  You probably won't end up with a\ngood one of those, but if you don't give up, and you are relentless and\ndiligent enough in your procrastination, you may just end up with a very\nnice option parser.\n\n## USAGE\n\n    // my-program.js\n    var nopt = require(\"nopt\")\n      , Stream = require(\"stream\").Stream\n      , path = require(\"path\")\n      , knownOpts = { \"foo\" : [String, null]\n                    , \"bar\" : [Stream, Number]\n                    , \"baz\" : path\n                    , \"bloo\" : [ \"big\", \"medium\", \"small\" ]\n                    , \"flag\" : Boolean\n                    , \"pick\" : Boolean\n                    , \"many\" : [String, Array]\n                    }\n      , shortHands = { \"foofoo\" : [\"--foo\", \"Mr. Foo\"]\n                     , \"b7\" : [\"--bar\", \"7\"]\n                     , \"m\" : [\"--bloo\", \"medium\"]\n                     , \"p\" : [\"--pick\"]\n                     , \"f\" : [\"--flag\"]\n                     }\n                 // everything is optional.\n                 // knownOpts and shorthands default to {}\n                 // arg list defaults to process.argv\n                 // slice defaults to 2\n      , parsed = nopt(knownOpts, shortHands, process.argv, 2)\n    console.log(parsed)\n\nThis would give you support for any of the following:\n\n```bash\n$ node my-program.js --foo \"blerp\" --no-flag\n{ \"foo\" : \"blerp\", \"flag\" : false }\n\n$ node my-program.js ---bar 7 --foo \"Mr. Hand\" --flag\n{ bar: 7, foo: \"Mr. Hand\", flag: true }\n\n$ node my-program.js --foo \"blerp\" -f -----p\n{ foo: \"blerp\", flag: true, pick: true }\n\n$ node my-program.js -fp --foofoo\n{ foo: \"Mr. Foo\", flag: true, pick: true }\n\n$ node my-program.js --foofoo -- -fp  # -- stops the flag parsing.\n{ foo: \"Mr. Foo\", argv: { remain: [\"-fp\"] } }\n\n$ node my-program.js --blatzk 1000 -fp # unknown opts are ok.\n{ blatzk: 1000, flag: true, pick: true }\n\n$ node my-program.js --blatzk true -fp # but they need a value\n{ blatzk: true, flag: true, pick: true }\n\n$ node my-program.js --no-blatzk -fp # unless they start with \"no-\"\n{ blatzk: false, flag: true, pick: true }\n\n$ node my-program.js --baz b/a/z # known paths are resolved.\n{ baz: \"/Users/isaacs/b/a/z\" }\n\n# if Array is one of the types, then it can take many\n# values, and will always be an array.  The other types provided\n# specify what types are allowed in the list.\n\n$ node my-program.js --many 1 --many null --many foo\n{ many: [\"1\", \"null\", \"foo\"] }\n\n$ node my-program.js --many foo\n{ many: [\"foo\"] }\n```\n\nRead the tests at the bottom of `lib/nopt.js` for more examples of\nwhat this puppy can do.\n\n## Types\n\nThe following types are supported, and defined on `nopt.typeDefs`\n\n* String: A normal string.  No parsing is done.\n* path: A file system path.  Gets resolved against cwd if not absolute.\n* url: A url.  If it doesn't parse, it isn't accepted.\n* Number: Must be numeric.\n* Date: Must parse as a date. If it does, and `Date` is one of the options,\n  then it will return a Date object, not a string.\n* Boolean: Must be either `true` or `false`.  If an option is a boolean,\n  then it does not need a value, and its presence will imply `true` as\n  the value.  To negate boolean flags, do `--no-whatever` or `--whatever\n  false`\n* NaN: Means that the option is strictly not allowed.  Any value will\n  fail.\n* Stream: An object matching the \"Stream\" class in node.  Valuable\n  for use when validating programmatically.  (npm uses this to let you\n  supply any WriteStream on the `outfd` and `logfd` config options.)\n* Array: If `Array` is specified as one of the types, then the value\n  will be parsed as a list of options.  This means that multiple values\n  can be specified, and that the value will always be an array.\n\nIf a type is an array of values not on this list, then those are\nconsidered valid values.  For instance, in the example above, the\n`--bloo` option can only be one of `\"big\"`, `\"medium\"`, or `\"small\"`,\nand any other value will be rejected.\n\nWhen parsing unknown fields, `\"true\"`, `\"false\"`, and `\"null\"` will be\ninterpreted as their JavaScript equivalents, and numeric values will be\ninterpreted as a number.\n\nYou can also mix types and values, or multiple types, in a list.  For\ninstance `{ blah: [Number, null] }` would allow a value to be set to\neither a Number or null.  When types are ordered, this implies a\npreference, and the first type that can be used to properly interpret\nthe value will be used.\n\nTo define a new type, add it to `nopt.typeDefs`.  Each item in that\nhash is an object with a `type` member and a `validate` method.  The\n`type` member is an object that matches what goes in the type list.  The\n`validate` method is a function that gets called with `validate(data,\nkey, val)`.  Validate methods should assign `data[key]` to the valid\nvalue of `val` if it can be handled properly, or return boolean\n`false` if it cannot.\n\nYou can also call `nopt.clean(data, types, typeDefs)` to clean up a\nconfig object and remove its invalid properties.\n\n## Error Handling\n\nBy default, nopt outputs a warning to standard error when invalid\noptions are found.  You can change this behavior by assigning a method\nto `nopt.invalidHandler`.  This method will be called with\nthe offending `nopt.invalidHandler(key, val, types)`.\n\nIf no `nopt.invalidHandler` is assigned, then it will console.error\nits whining.  If it is assigned to boolean `false` then the warning is\nsuppressed.\n\n## Abbreviations\n\nYes, they are supported.  If you define options like this:\n\n```javascript\n{ \"foolhardyelephants\" : Boolean\n, \"pileofmonkeys\" : Boolean }\n```\n\nThen this will work:\n\n```bash\nnode program.js --foolhar --pil\nnode program.js --no-f --pileofmon\n# etc.\n```\n\n## Shorthands\n\nShorthands are a hash of shorter option names to a snippet of args that\nthey expand to.\n\nIf multiple one-character shorthands are all combined, and the\ncombination does not unambiguously match any other option or shorthand,\nthen they will be broken up into their constituent parts.  For example:\n\n```json\n{ \"s\" : [\"--loglevel\", \"silent\"]\n, \"g\" : \"--global\"\n, \"f\" : \"--force\"\n, \"p\" : \"--parseable\"\n, \"l\" : \"--long\"\n}\n```\n\n```bash\nnpm ls -sgflp\n# just like doing this:\nnpm ls --loglevel silent --global --force --long --parseable\n```\n\n## The Rest of the args\n\nThe config object returned by nopt is given a special member called\n`argv`, which is an object with the following fields:\n\n* `remain`: The remaining args after all the parsing has occurred.\n* `original`: The args as they originally appeared.\n* `cooked`: The args after flags and shorthands are expanded.\n\n## Slicing\n\nNode programs are called with more or less the exact argv as it appears\nin C land, after the v8 and node-specific options have been plucked off.\nAs such, `argv[0]` is always `node` and `argv[1]` is always the\nJavaScript program being run.\n\nThat's usually not very useful to you.  So they're sliced off by\ndefault.  If you want them, then you can pass in `0` as the last\nargument, or any other number that you'd like to slice off the start of\nthe list.\n",
-  "_id": "nopt@2.0.0",
+  "readmeFilename": "README.md",
+  "_id": "nopt@2.1.1",
   "_from": "nopt@latest"
 }
index 8a0e4d5..65348d5 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "npmconf",
-  "version": "0.0.16",
+  "version": "0.0.17",
   "description": "The config thing npm uses",
   "main": "npmconf.js",
   "directories": {
@@ -12,7 +12,7 @@
     "once": "~1.1.1",
     "mkdirp": "~0.3.3",
     "osenv": "0.0.3",
-    "nopt": "~2.0.0"
+    "nopt": "2"
   },
   "devDependencies": {},
   "scripts": {
@@ -37,6 +37,6 @@
   "license": "BSD",
   "readme": "# npmconf\n\nThe config thing npm uses\n\nIf you are interested in interacting with the config settings that npm\nuses, then use this module.\n\nHowever, if you are writing a new Node.js program, and want\nconfiguration functionality similar to what npm has, but for your\nown thing, then I'd recommend using [rc](https://github.com/dominictarr/rc),\nwhich is probably what you want.\n\nIf I were to do it all over again, that's what I'd do for npm.  But,\nalas, there are many systems depending on many of the particulars of\nnpm's configuration setup, so it's not worth the cost of changing.\n\n## USAGE\n\n```javascript\nvar npmconf = require('npmconf')\n\n// pass in the cli options that you read from the cli\n// or whatever top-level configs you want npm to use for now.\nnpmconf.load({some:'configs'}, function (er, conf) {\n  // do stuff with conf\n  conf.get('some', 'cli') // 'configs'\n  conf.get('username') // 'joebobwhatevers'\n  conf.set('foo', 'bar', 'user')\n  conf.save('user', function (er) {\n    // foo = bar is now saved to ~/.npmrc or wherever\n  })\n})\n```\n",
   "readmeFilename": "README.md",
-  "_id": "npmconf@0.0.16",
-  "_from": "npmconf@0"
+  "_id": "npmconf@0.0.17",
+  "_from": "npmconf@latest"
 }
index a645da5..cd6b792 100644 (file)
@@ -1,5 +1,5 @@
 {
-  "version": "1.2.0",
+  "version": "1.2.2",
   "name": "npm",
   "publishConfig": {
     "proprietary-attribs": false
     "semver": "~1.1.2",
     "ini": "~1.0.5",
     "slide": "1",
-    "abbrev": "1",
+    "abbrev": "~1.0.4",
     "graceful-fs": "~1.1.1",
     "minimatch": "~0.2.8",
-    "nopt": "~2.0",
+    "nopt": "~2.1.1",
     "rimraf": "2",
     "request": "~2.9",
     "which": "1",
index 6b113ad..285bce7 100644 (file)
@@ -1,22 +1,21 @@
 {
-  "name": "npm-test-peer-deps-invalid",
-  "version": "0.0.0",
-  "dependencies": {
-    "npm-test-peer-deps-file": {
-      "version": "1.2.3",
-      "from": "https://raw.github.com/gist/3971128/3f6aa37b4fa1186c2f47da9b77dcc4ec496e3483/index.js",
-      "dependencies": {
-       "opener": {
-         "version": "1.3.0"
-       }
+  "npm-test-peer-deps-file": {
+    "version": "1.2.3",
+    "from": "https://raw.github.com/gist/3971128/3f6aa37b4fa1186c2f47da9b77dcc4ec496e3483/index.js",
+    "resolved": "https://raw.github.com/gist/3971128/3f6aa37b4fa1186c2f47da9b77dcc4ec496e3483/index.js",
+    "dependencies": {
+      "opener": {
+        "version": "1.3.0",
+        "from": "opener@1.3.0"
       }
-    },
-    "npm-test-peer-deps-file-invalid": {
-      "version": "1.2.3",
-      "from": "https://gist.github.com/raw/4303335/861f8d3213061826ab31591840c3cb0ac737f4fc/index.js"
-    },
-    "dict": {
-      "peerInvalid": true
     }
+  },
+  "npm-test-peer-deps-file-invalid": {
+    "version": "1.2.3",
+    "from": "https://gist.github.com/raw/4303335/861f8d3213061826ab31591840c3cb0ac737f4fc/index.js",
+    "resolved": "https://gist.github.com/raw/4303335/861f8d3213061826ab31591840c3cb0ac737f4fc/index.js"
+  },
+  "dict": {
+    "peerInvalid": true
   }
 }
index e452114..7046264 100644 (file)
@@ -12,7 +12,7 @@ require("child_process").exec(npm + " ls --json", {
     function (err, stdout, stderr) {
 
   var actual = JSON.parse(stdout).dependencies
-  var expected = require("./npm-ls.json").dependencies
+  var expected = require("./npm-ls.json")
 
   // Delete the "problems" entry because it contains system-specific path info,
   // so we can't compare it accurately and thus have deleted it from
@@ -23,7 +23,10 @@ require("child_process").exec(npm + " ls --json", {
   // this will be either version 1.1.0 or version 1.0.0
   var dictVer = actual.dict.version
   delete actual.dict.version
+  delete actual.dict.from
+  delete actual.dict.resolved
   assert(dictVer === "1.1.0" || dictVer === "1.0.0")
+  console.error(JSON.stringify(actual, null, 2))
   assert.deepEqual(actual, expected)
 
   assert.ok(err)
index 05dda41..25a3ce7 100644 (file)
@@ -1,18 +1,17 @@
 {
-  "name": "npm-test-peer-deps",
-  "version": "0.0.0",
-  "dependencies": {
-    "npm-test-peer-deps-file": {
-      "version": "1.2.3",
-      "from": "https://raw.github.com/gist/3971128/3f6aa37b4fa1186c2f47da9b77dcc4ec496e3483/index.js",
-      "dependencies": {
-        "opener": {
-          "version": "1.3.0"
-        }
+  "npm-test-peer-deps-file": {
+    "version": "1.2.3",
+    "from": "https://raw.github.com/gist/3971128/3f6aa37b4fa1186c2f47da9b77dcc4ec496e3483/index.js",
+    "resolved": "https://raw.github.com/gist/3971128/3f6aa37b4fa1186c2f47da9b77dcc4ec496e3483/index.js",
+    "dependencies": {
+      "opener": {
+        "version": "1.3.0",
+        "from": "opener@1.3.0"
       }
-    },
-    "dict": {
-      "version": "1.1.0"
     }
+  },
+  "dict": {
+    "version": "1.1.0",
+    "from": "dict@1.1.0"
   }
 }
index 9b316f2..98dbf5f 100644 (file)
@@ -14,7 +14,9 @@ require("child_process").exec(npm + " ls --json", {
   if (err) throw err
 
   var actual = JSON.parse(stdout).dependencies
-  var expected = require("./npm-ls.json").dependencies
+  var expected = require("./npm-ls.json")
+  console.error(JSON.stringify(actual, null, 2))
+  console.error(JSON.stringify(expected, null, 2))
 
   assert.deepEqual(actual, expected)
 })
index 27553c1..b0b8bd7 100644 (file)
@@ -4,38 +4,46 @@
   "dependencies": {
     "npm-test-single-file": {
       "version": "1.2.3",
-      "from": "https://raw.github.com/gist/1837112/index.js"
+      "from": "https://raw.github.com/gist/1837112/index.js",
+      "resolved": "https://raw.github.com/gist/1837112/index.js"
     },
     "glob": {
       "version": "3.1.5",
-      "from": "git://github.com/isaacs/node-glob.git#npm-test",
+      "from": "glob@git://github.com/isaacs/node-glob.git#npm-test",
+      "resolved": "git://github.com/isaacs/node-glob.git#67bda227fd7a559cca5620307c7d30a6732a792f",
       "dependencies": {
         "minimatch": {
           "version": "0.2.1",
           "dependencies": {
             "lru-cache": {
-              "version": "1.0.5"
+              "version": "1.0.5",
+              "from": "lru-cache@~1.0.5"
             }
           }
         },
         "graceful-fs": {
           "version": "1.1.5",
+          "from": "graceful-fs@1.1.5",
           "dependencies": {
             "fast-list": {
-              "version": "1.0.2"
+              "version": "1.0.2",
+              "from": "fast-list@1.0.2"
             }
           }
         },
         "inherits": {
-          "version": "1.0.0"
+          "version": "1.0.0",
+          "from": "inherits@1.0.0"
         }
       }
     },
     "minimatch": {
       "version": "0.1.5",
+      "from": "minimatch@0.1.5",
       "dependencies": {
         "lru-cache": {
-          "version": "1.0.5"
+          "version": "1.0.5",
+          "from": "lru-cache@1.0.5"
         }
       }
     }
index 4dc4b2b..f3fe8a4 100644 (file)
@@ -5,17 +5,31 @@ process.env.npm_config_prefix = process.cwd()
 delete process.env.npm_config_global
 delete process.env.npm_config_depth
 
-var npm = process.platform === "win32"
-        ? path.resolve(process.env.npm_config_prefix, "../../npm")
-        : path.resolve(process.env.npm_config_prefix, "../../../bin/npm")
+var npm = process.env.npm_execpath
 
 require("child_process").exec(npm + " ls --json", {
     stdio: "pipe", env: process.env, cwd: process.cwd() },
     function (err, stdout, stderr) {
   if (err) throw err
 
-  var actual = JSON.parse(stdout).dependencies
-  var expected = require("./npm-shrinkwrap.json").dependencies
+  var actual = JSON.parse(stdout)
+  var expected = require("./npm-shrinkwrap.json")
+  rmFrom(actual)
+  actual = actual.dependencies
+  rmFrom(expected)
+  expected = expected.dependencies
+  console.error(JSON.stringify(actual, null, 2))
+  console.error(JSON.stringify(expected, null, 2))
 
   assert.deepEqual(actual, expected)
 })
+
+function rmFrom (obj) {
+  for (var i in obj) {
+    if (i === "from")
+      delete obj[i]
+    else if (i === "dependencies")
+      for (var j in obj[i])
+        rmFrom(obj[i][j])
+  }
+}
index a35dc1c..f1949d8 100644 (file)
@@ -1,7 +1,7 @@
 { "name":"npm-test-url-dep"
 , "version" : "1.2.3"
 , "dependencies" :
-  { "dnode" : "https://github.com/substack/jsonify/tarball/master"
+  { "jsonify" : "https://github.com/substack/jsonify/tarball/master"
   , "sax": "isaacs/sax-js"
   , "canonical-host": "git://github.com/isaacs/canonical-host"
   } }