Update npm to 1.1.2
This commit is contained in:
Родитель
e004721b48
Коммит
ca0986fbd1
|
@ -52,3 +52,5 @@ Gautham Pai <buzypi@gmail.com>
|
|||
David Trejo <david.daniel.trejo@gmail.com>
|
||||
Paul Vorbach <paul@vorb.de>
|
||||
George Ornbo <george@shapeshed.com>
|
||||
Tim Oxley <secoif@gmail.com>
|
||||
Tyler Green <tyler.green2@gmail.com>
|
||||
|
|
|
@ -49,6 +49,13 @@ if (conf.version) {
|
|||
return
|
||||
}
|
||||
|
||||
if (conf.versions) {
|
||||
var v = process.versions
|
||||
v.npm = npm.version
|
||||
console.log(v)
|
||||
return
|
||||
}
|
||||
|
||||
log.info("npm@"+npm.version, "using")
|
||||
log.info("node@"+process.version, "using")
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
:: Created by npm, please don't edit manually.
|
||||
@IF EXIST "%~dp0"\"node.exe" (
|
||||
"%~dp0"\"node.exe" "%~dp0\.\node_modules\npm\bin\npm-cli.js" %*
|
||||
@IF EXIST "%~dp0\node.exe" (
|
||||
"%~dp0\node.exe" "%~dp0\.\node_modules\npm\bin\npm-cli.js" %*
|
||||
) ELSE (
|
||||
node "%~dp0\.\node_modules\npm\bin\npm-cli.js" %*
|
||||
)
|
||||
node "%~dp0\.\node_modules\npm\bin\npm-cli.js" %*
|
||||
)
|
||||
|
|
|
@ -21,6 +21,12 @@ It will print out extraneous, missing, and invalid packages.
|
|||
If the silent parameter is set to true, nothing will be output to the screen,
|
||||
but the data will still be returned.
|
||||
|
||||
Callback is provided an error if one occurred, the full data about which
|
||||
packages are installed and which dependencies they will receive, and a
|
||||
"lite" data object which just shows which versions are installed where.
|
||||
Note that the full data object is a circular structure, so care must be
|
||||
taken if it is serialized to JSON.
|
||||
|
||||
## CONFIGURATION
|
||||
|
||||
### long
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
npm-shrinkwrap(3) -- programmatically generate package shrinkwrap file
|
||||
====================================================
|
||||
|
||||
## SYNOPSIS
|
||||
|
||||
npm.commands.shrinkwrap(args, [silent,] callback)
|
||||
|
||||
## DESCRIPTION
|
||||
|
||||
This acts much the same ways as shrinkwrapping on the command-line.
|
||||
|
||||
This command does not take any arguments, but 'args' must be defined.
|
||||
Beyond that, if any arguments are passed in, npm will politely warn that it
|
||||
does not take positional arguments.
|
||||
|
||||
If the 'silent' parameter is set to true, nothing will be output to the screen,
|
||||
but the shrinkwrap file will still be written.
|
||||
|
||||
Finally, 'callback' is a function that will be called when the shrinkwrap has
|
||||
been saved.
|
|
@ -372,6 +372,17 @@ The value `npm init` should use by default for the package author's email.
|
|||
|
||||
The value `npm init` should use by default for the package author's homepage.
|
||||
|
||||
### json
|
||||
|
||||
* Default: false
|
||||
* Type: Boolean
|
||||
|
||||
Whether or not to output JSON data, rather than the normal output.
|
||||
|
||||
This feature is currently experimental, and the output data structures
|
||||
for many commands is either not implemented in JSON yet, or subject to
|
||||
change. Only the output from `npm ls --json` is currently valid.
|
||||
|
||||
### link
|
||||
|
||||
* Default: false
|
||||
|
@ -682,6 +693,16 @@ If true, output the npm version and exit successfully.
|
|||
|
||||
Only relevant when specified explicitly on the command line.
|
||||
|
||||
### versions
|
||||
|
||||
* Default: false
|
||||
* Type: boolean
|
||||
|
||||
If true, output the npm version as well as node's `process.versions`
|
||||
hash, and exit successfully.
|
||||
|
||||
Only relevant when specified explicitly on the command line.
|
||||
|
||||
### viewer
|
||||
|
||||
* Default: "man" on Posix, "browser" on Windows
|
||||
|
|
|
@ -170,6 +170,10 @@ npm-index(1) -- Index of all npm documentation
|
|||
|
||||
The semantic versioner for npm
|
||||
|
||||
## npm-shrinkwrap(1)
|
||||
|
||||
Lock down dependency versions
|
||||
|
||||
## npm-star(1)
|
||||
|
||||
Mark your favorite packages
|
||||
|
@ -323,6 +327,10 @@ npm-index(1) -- Index of all npm documentation
|
|||
|
||||
Search for packages
|
||||
|
||||
## npm-shrinkwrap(3)
|
||||
|
||||
programmatically generate package shrinkwrap file
|
||||
|
||||
## npm-start(3)
|
||||
|
||||
Start a package
|
||||
|
|
|
@ -14,7 +14,9 @@ npm-install(1) -- Install a package
|
|||
|
||||
## DESCRIPTION
|
||||
|
||||
This command installs a package, and any packages that it depends on.
|
||||
This command installs a package, and any packages that it depends on. If the
|
||||
package has a shrinkwrap file, the installation of dependencies will be driven
|
||||
by that. See npm-shrinkwrap(1).
|
||||
|
||||
A `package` is:
|
||||
|
||||
|
@ -199,3 +201,4 @@ affects a real use-case, it will be investigated.
|
|||
* npm-folders(1)
|
||||
* npm-tag(1)
|
||||
* npm-rm(1)
|
||||
* npm-shrinkwrap(1)
|
||||
|
|
|
@ -22,6 +22,13 @@ When run as `ll` or `la`, it shows extended information by default.
|
|||
|
||||
## CONFIGURATION
|
||||
|
||||
### json
|
||||
|
||||
* Default: false
|
||||
* Type: Boolean
|
||||
|
||||
Show information in JSON format.
|
||||
|
||||
### long
|
||||
|
||||
* Default: false
|
||||
|
|
|
@ -0,0 +1,171 @@
|
|||
npm-shrinkwrap(1) -- Lock down dependency versions
|
||||
=====================================================
|
||||
|
||||
## SYNOPSIS
|
||||
|
||||
npm shrinkwrap
|
||||
|
||||
## DESCRIPTION
|
||||
|
||||
This command locks down the versions of a package's dependencies so that you can
|
||||
control exactly which versions of each dependency will be used when your package
|
||||
is installed.
|
||||
|
||||
By default, "npm install" recursively installs the target's dependencies (as
|
||||
specified in package.json), choosing the latest available version that satisfies
|
||||
the dependency's semver pattern. In some situations, particularly when shipping
|
||||
software where each change is tightly managed, it's desirable to fully specify
|
||||
each version of each dependency recursively so that subsequent builds and
|
||||
deploys do not inadvertently pick up newer versions of a dependency that satisfy
|
||||
the semver pattern. Specifying specific semver patterns in each dependency's
|
||||
package.json would facilitate this, but that's not always possible or desirable,
|
||||
as when another author owns the npm package. It's also possible to check
|
||||
dependencies directly into source control, but that may be undesirable for other
|
||||
reasons.
|
||||
|
||||
As an example, consider package A:
|
||||
|
||||
{
|
||||
"name": "A",
|
||||
"version": "0.1.0",
|
||||
"dependencies": {
|
||||
"B": "<0.1.0"
|
||||
}
|
||||
}
|
||||
|
||||
package B:
|
||||
|
||||
{
|
||||
"name": "B",
|
||||
"version": "0.0.1",
|
||||
"dependencies": {
|
||||
"C": "<0.1.0"
|
||||
}
|
||||
}
|
||||
|
||||
and package C:
|
||||
|
||||
{
|
||||
"name": "C,
|
||||
"version": "0.0.1"
|
||||
}
|
||||
|
||||
If these are the only versions of A, B, and C available in the registry, then
|
||||
a normal "npm install A" will install:
|
||||
|
||||
A@0.1.0
|
||||
`-- B@0.0.1
|
||||
`-- C@0.0.1
|
||||
|
||||
However, if B@0.0.2 is published, then a fresh "npm install A" will install:
|
||||
|
||||
A@0.1.0
|
||||
`-- B@0.0.2
|
||||
`-- C@0.0.1
|
||||
|
||||
assuming the new version did not modify B's dependencies. Of course, the new
|
||||
version of B could include a new version of C and any number of new
|
||||
dependencies. If such changes are undesirable, the author of A could specify a
|
||||
dependency on B@0.0.1. However, if A's author and B's author are not the same
|
||||
person, there's no way for A's author to say that he or she does not want to
|
||||
pull in newly published versions of C when B hasn't changed at all.
|
||||
|
||||
In this case, A's author can run
|
||||
|
||||
npm shrinkwrap
|
||||
|
||||
This generates npm-shrinkwrap.json, which will look something like this:
|
||||
|
||||
{
|
||||
"name": "A",
|
||||
"version": "0.1.0",
|
||||
"dependencies": {
|
||||
"B": {
|
||||
"version": "0.0.1",
|
||||
"dependencies": {
|
||||
"C": {
|
||||
"version": "0.1.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
The shrinkwrap command has locked down the dependencies based on what's
|
||||
currently installed in node_modules. When "npm install" installs a package with
|
||||
a npm-shrinkwrap.json file in the package root, the shrinkwrap file (rather than
|
||||
package.json files) completely drives the installation of that package and all
|
||||
of its dependencies (recursively). So now the author publishes A@0.1.0, and
|
||||
subsequent installs of this package will use B@0.0.1 and C@0.1.0, regardless the
|
||||
dependencies and versions listed in A's, B's, and C's package.json files.
|
||||
|
||||
|
||||
### Using shrinkwrapped packages
|
||||
|
||||
Using a shrinkwrapped package is no different than using any other package: you
|
||||
can "npm install" it by hand, or add a dependency to your package.json file and
|
||||
"npm install" it.
|
||||
|
||||
### Building shrinkwrapped packages
|
||||
|
||||
To shrinkwrap an existing package:
|
||||
|
||||
1. Run "npm install" in the package root to install the current versions of all
|
||||
dependencies.
|
||||
2. Validate that the package works as expected with these versions.
|
||||
3. Run "npm shrinkwrap", add npm-shrinkwrap.json to git, and publish your
|
||||
package.
|
||||
|
||||
To add or update a dependency in a shrinkwrapped package:
|
||||
|
||||
1. Run "npm install" in the package root to install the current versions of all
|
||||
dependencies.
|
||||
2. Add or update dependencies. "npm install" each new or updated package
|
||||
individually and then update package.json. Note that they must be
|
||||
explicitly named in order to be installed: running `npm install` with
|
||||
no arguments will merely reproduce the existing shrinkwrap.
|
||||
3. Validate that the package works as expected with the new dependencies.
|
||||
4. Run "npm shrinkwrap", commit the new npm-shrinkwrap.json, and publish your
|
||||
package.
|
||||
|
||||
You can use npm-outdated(1) to view dependencies with newer versions available.
|
||||
|
||||
### Other Notes
|
||||
|
||||
Since "npm shrinkwrap" uses the locally installed packages to construct the
|
||||
shrinkwrap file, devDependencies will be included if and only if you've
|
||||
installed them already when you make the shrinkwrap.
|
||||
|
||||
A shrinkwrap file must be consistent with the package's package.json file. "npm
|
||||
shrinkwrap" will fail if required dependencies are not already installed, since
|
||||
that would result in a shrinkwrap that wouldn't actually work. Similarly, the
|
||||
command will fail if there are extraneous packages (not referenced by
|
||||
package.json), since that would indicate that package.json is not correct.
|
||||
|
||||
If shrinkwrapped package A depends on shrinkwrapped package B, B's shrinkwrap
|
||||
will not be used as part of the installation of A. However, because A's
|
||||
shrinkwrap is constructed from a valid installation of B and recursively
|
||||
specifies all dependencies, the contents of B's shrinkwrap will implicitly be
|
||||
included in A's shrinkwrap.
|
||||
|
||||
### Caveats
|
||||
|
||||
Shrinkwrap files only lock down package versions, not actual package contents.
|
||||
While discouraged, a package author can republish an existing version of a
|
||||
package, causing shrinkwrapped packages using that version to pick up different
|
||||
code than they were before. If you want to avoid any risk that a byzantine
|
||||
author replaces a package you're using with code that breaks your application,
|
||||
you could modify the shrinkwrap file to use git URL references rather than
|
||||
version numbers so that npm always fetches all packages from git.
|
||||
|
||||
If you wish to lock down the specific bytes included in a package, for
|
||||
example to have 100% confidence in being able to reproduce a deployment
|
||||
or build, then you ought to check your dependencies into source control,
|
||||
or pursue some other mechanism that can verify contents rather than
|
||||
versions.
|
||||
|
||||
## SEE ALSO
|
||||
|
||||
* npm-install(1)
|
||||
* npm-json(1)
|
||||
* npm-list(1)
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">bin — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">bugs — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -28,7 +28,7 @@ usage, or <code>man 3 npm-<command></code> for programmatic usage.</p>
|
|||
|
||||
<ul><li><a href="../doc/index.html">index(1)</a></li></ul>
|
||||
</div>
|
||||
<p id="footer">commands — npm@1.1.1</p>
|
||||
<p id="footer">commands — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -33,7 +33,7 @@ functions instead.</p>
|
|||
|
||||
<ul><li><a href="../api/npm.html">npm(3)</a></li></ul>
|
||||
</div>
|
||||
<p id="footer">config — npm@1.1.1</p>
|
||||
<p id="footer">config — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -30,7 +30,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 — npm@1.1.1</p>
|
||||
<p id="footer">deprecate — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">docs — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">edit — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -24,7 +24,7 @@ sure to use <code>npm rebuild <pkg></code> if you make any changes.</p>
|
|||
|
||||
<p>The first element in the 'args' 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 — npm@1.1.1</p>
|
||||
<p id="footer">explore — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">help-search — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">init — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -25,7 +25,7 @@ the name of a package to be installed.</p>
|
|||
<p>Finally, 'callback' 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 — npm@1.1.1</p>
|
||||
<p id="footer">install — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -39,7 +39,7 @@ npm.commands.link('redis', 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 — npm@1.1.1</p>
|
||||
<p id="footer">link — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">load — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -28,6 +28,12 @@ like with any other command, such as <code>global</code> to list global packages
|
|||
<p>If the silent parameter is set to true, nothing will be output to the screen,
|
||||
but the data will still be returned.</p>
|
||||
|
||||
<p>Callback is provided an error if one occurred, the full data about which
|
||||
packages are installed and which dependencies they will receive, and a
|
||||
"lite" data object which just shows which versions are installed where.
|
||||
Note that the full data object is a circular structure, so care must be
|
||||
taken if it is serialized to JSON.</p>
|
||||
|
||||
<h2 id="CONFIGURATION">CONFIGURATION</h2>
|
||||
|
||||
<h3 id="long">long</h3>
|
||||
|
@ -53,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 — npm@1.1.1</p>
|
||||
<p id="footer">ls — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -24,7 +24,7 @@ npm.load(configObject, function (er, npm) {
|
|||
|
||||
<h2 id="VERSION">VERSION</h2>
|
||||
|
||||
<p>1.1.1</p>
|
||||
<p>1.1.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("unp") // cmd === "unpublish"</code></pre>
|
||||
</div>
|
||||
<p id="footer">npm — npm@1.1.1</p>
|
||||
<p id="footer">npm — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -19,7 +19,7 @@ currently outdated.</p>
|
|||
|
||||
<p>If the 'packages' parameter is left out, npm will check all packages.</p>
|
||||
</div>
|
||||
<p id="footer">outdated — npm@1.1.1</p>
|
||||
<p id="footer">outdated — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">owner — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">pack — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
<p>This function is not useful programmatically</p>
|
||||
</div>
|
||||
<p id="footer">prefix — npm@1.1.1</p>
|
||||
<p id="footer">prefix — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
<p>Extraneous packages are packages that are not listed on the parent
|
||||
package's dependencies list.</p>
|
||||
</div>
|
||||
<p id="footer">prune — npm@1.1.1</p>
|
||||
<p id="footer">prune — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -32,7 +32,7 @@ the registry. Overwrites when the "force" environment variable 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="../api/owner.html">owner(3)</a></li></ul>
|
||||
</div>
|
||||
<p id="footer">publish — npm@1.1.1</p>
|
||||
<p id="footer">publish — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -22,7 +22,7 @@ the new binary. If no 'packages' parameter is specify, every package will be reb
|
|||
|
||||
<p>See <code>npm help build</code></p>
|
||||
</div>
|
||||
<p id="footer">rebuild — npm@1.1.1</p>
|
||||
<p id="footer">rebuild — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">restart — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
<p>This function is not useful programmatically.</p>
|
||||
</div>
|
||||
<p id="footer">root — npm@1.1.1</p>
|
||||
<p id="footer">root — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">run-script — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -32,7 +32,7 @@ excluded term (the "searchexclude" config). The search is case insensitive
|
|||
and doesn't try to read your mind (it doesn't do any verb tense matching or the
|
||||
like).</p>
|
||||
</div>
|
||||
<p id="footer">search — npm@1.1.1</p>
|
||||
<p id="footer">search — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -0,0 +1,61 @@
|
|||
<!doctype html>
|
||||
<html>
|
||||
<title>shrinkwrap</title>
|
||||
<meta http-equiv="content-type" value="text/html;utf-8">
|
||||
<link rel="stylesheet" type="text/css" href="./style.css">
|
||||
|
||||
<body>
|
||||
<div id="wrapper">
|
||||
<h1><a href="../api/shrinkwrap.html">shrinkwrap</a></h1> <p>programmatically generate package shrinkwrap file</p>
|
||||
|
||||
<h2 id="SYNOPSIS">SYNOPSIS</h2>
|
||||
|
||||
<pre><code>npm.commands.shrinkwrap(args, [silent,] callback)</code></pre>
|
||||
|
||||
<h2 id="DESCRIPTION">DESCRIPTION</h2>
|
||||
|
||||
<p>This acts much the same ways as shrinkwrapping on the command-line.</p>
|
||||
|
||||
<p>This command does not take any arguments, but 'args' must be defined.
|
||||
Beyond that, if any arguments are passed in, npm will politely warn that it
|
||||
does not take positional arguments.</p>
|
||||
|
||||
<p>If the 'silent' parameter is set to true, nothing will be output to the screen,
|
||||
but the shrinkwrap file will still be written.</p>
|
||||
|
||||
<p>Finally, 'callback' is a function that will be called when the shrinkwrap has
|
||||
been saved.</p>
|
||||
</div>
|
||||
<p id="footer">shrinkwrap — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
var els = Array.prototype.slice.call(wrapper.getElementsByTagName("*"), 0)
|
||||
.filter(function (el) {
|
||||
return el.parentNode === wrapper
|
||||
&& el.tagName.match(/H[1-6]/)
|
||||
&& el.id
|
||||
})
|
||||
var l = 2
|
||||
, toc = document.createElement("ul")
|
||||
toc.innerHTML = els.map(function (el) {
|
||||
var i = el.tagName.charAt(1)
|
||||
, out = ""
|
||||
while (i > l) {
|
||||
out += "<ul>"
|
||||
l ++
|
||||
}
|
||||
while (i < l) {
|
||||
out += "</ul>"
|
||||
l --
|
||||
}
|
||||
out += "<li><a href='#" + el.id + "'>" +
|
||||
( el.innerText || el.text || el.innerHTML)
|
||||
+ "</a>"
|
||||
return out
|
||||
}).join("\n")
|
||||
toc.id = "toc"
|
||||
document.body.appendChild(toc)
|
||||
})()
|
||||
</script>
|
||||
</body></html>
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">start — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">stop — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">submodule — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">tag — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">test — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -22,7 +22,7 @@ the name of a package to be uninstalled.</p>
|
|||
<p>Finally, 'callback' 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 — npm@1.1.1</p>
|
||||
<p id="footer">uninstall — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">unpublish — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
<p>The 'packages' argument is an array of packages to update. The 'callback' parameter will be called when done or when an error occurs.</p>
|
||||
</div>
|
||||
<p id="footer">update — npm@1.1.1</p>
|
||||
<p id="footer">update — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">version — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -99,7 +99,7 @@ the field name.</p>
|
|||
|
||||
<p>corresponding to the list of fields selected.</p>
|
||||
</div>
|
||||
<p id="footer">view — npm@1.1.1</p>
|
||||
<p id="footer">view — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
<p>This function is not useful programmatically</p>
|
||||
</div>
|
||||
<p id="footer">whoami — npm@1.1.1</p>
|
||||
<p id="footer">whoami — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -267,7 +267,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> — npm@1.1.1</p>
|
||||
<p id="footer"><a href="../doc/README.html">README</a> — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">adduser — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">bin — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">bugs — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">build — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">bundle — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">cache — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -34,7 +34,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 — npm@1.1.1</p>
|
||||
<p id="footer">changelog — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -191,7 +191,7 @@ set to anything."</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 — npm@1.1.1</p>
|
||||
<p id="footer">coding-style — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">completion — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -331,6 +331,16 @@ from packages when building tarballs.</p>
|
|||
|
||||
<p>The value <code>npm init</code> should use by default for the package author's homepage.</p>
|
||||
|
||||
<h3 id="json">json</h3>
|
||||
|
||||
<ul><li>Default: false</li><li>Type: Boolean</li></ul>
|
||||
|
||||
<p>Whether or not to output JSON data, rather than the normal output.</p>
|
||||
|
||||
<p>This feature is currently experimental, and the output data structures
|
||||
for many commands is either not implemented in JSON yet, or subject to
|
||||
change. Only the output from <code>npm ls --json</code> is currently valid.</p>
|
||||
|
||||
<h3 id="link">link</h3>
|
||||
|
||||
<ul><li>Default: false</li><li>Type: Boolean</li></ul>
|
||||
|
@ -601,6 +611,15 @@ this value. Thus, the defaults are <code>0755</code> and <code>0644</code> resp
|
|||
|
||||
<p>Only relevant when specified explicitly on the command line.</p>
|
||||
|
||||
<h3 id="versions">versions</h3>
|
||||
|
||||
<ul><li>Default: false</li><li>Type: boolean</li></ul>
|
||||
|
||||
<p>If true, output the npm version as well as node's <code>process.versions</code>
|
||||
hash, and exit successfully.</p>
|
||||
|
||||
<p>Only relevant when specified explicitly on the command line.</p>
|
||||
|
||||
<h3 id="viewer">viewer</h3>
|
||||
|
||||
<ul><li>Default: "man" on Posix, "browser" on Windows</li><li>Type: path</li></ul>
|
||||
|
@ -623,7 +642,7 @@ then answer "no" 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 — npm@1.1.1</p>
|
||||
<p id="footer">config — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -29,7 +29,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 — npm@1.1.1</p>
|
||||
<p id="footer">deprecate — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -150,7 +150,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 — npm@1.1.1</p>
|
||||
<p id="footer">developers — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -80,7 +80,7 @@ license statement)</li><li>Illegal content.</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 — npm@1.1.1</p>
|
||||
<p id="footer">disputes — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">docs — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -37,7 +37,7 @@ or <code>"notepad"</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 — npm@1.1.1</p>
|
||||
<p id="footer">edit — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">explore — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -241,7 +241,7 @@ We'll have someone kick it or something.</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 — npm@1.1.1</p>
|
||||
<p id="footer">faq — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">folders — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">help-search — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">help — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -178,6 +178,10 @@
|
|||
|
||||
<p> The semantic versioner for npm</p>
|
||||
|
||||
<h2 id="npm-shrinkwrap-1"><a href="../doc/shrinkwrap.html">shrinkwrap(1)</a></h2>
|
||||
|
||||
<p> Lock down dependency versions</p>
|
||||
|
||||
<h2 id="npm-star-1"><a href="../doc/star.html">star(1)</a></h2>
|
||||
|
||||
<p> Mark your favorite packages</p>
|
||||
|
@ -332,6 +336,10 @@
|
|||
|
||||
<p> Search for packages</p>
|
||||
|
||||
<h2 id="npm-shrinkwrap-3"><a href="../api/shrinkwrap.html">shrinkwrap(3)</a></h2>
|
||||
|
||||
<p> programmatically generate package shrinkwrap file</p>
|
||||
|
||||
<h2 id="npm-start-3"><a href="../api/start.html">start(3)</a></h2>
|
||||
|
||||
<p> Start a package</p>
|
||||
|
@ -376,7 +384,7 @@
|
|||
|
||||
<p> Display npm username</p>
|
||||
</div>
|
||||
<p id="footer">index — npm@1.1.1</p>
|
||||
<p id="footer">index — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -29,7 +29,7 @@ without a really good reason to do so.</p>
|
|||
|
||||
<ul><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 — npm@1.1.1</p>
|
||||
<p id="footer">init — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -21,7 +21,9 @@ npm install <name>@<version range></code></pre>
|
|||
|
||||
<h2 id="DESCRIPTION">DESCRIPTION</h2>
|
||||
|
||||
<p>This command installs a package, and any packages that it depends on.</p>
|
||||
<p>This command installs a package, and any packages that it depends on. If the
|
||||
package has a shrinkwrap file, the installation of dependencies will be driven
|
||||
by that. See <a href="../doc/shrinkwrap.html">shrinkwrap(1)</a>.</p>
|
||||
|
||||
<p>A <code>package</code> is:</p>
|
||||
|
||||
|
@ -132,9 +134,9 @@ affects a real use-case, it will be investigated.</p>
|
|||
|
||||
<h2 id="SEE-ALSO">SEE ALSO</h2>
|
||||
|
||||
<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></ul>
|
||||
<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 — npm@1.1.1</p>
|
||||
<p id="footer">install — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -436,7 +436,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 — npm@1.1.1</p>
|
||||
<p id="footer">json — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -58,7 +58,7 @@ installation target into your project'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 — npm@1.1.1</p>
|
||||
<p id="footer">link — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -29,6 +29,12 @@ like with any other command, such as <code>-g</code> to list global packages.</p
|
|||
|
||||
<h2 id="CONFIGURATION">CONFIGURATION</h2>
|
||||
|
||||
<h3 id="json">json</h3>
|
||||
|
||||
<ul><li>Default: false</li><li>Type: Boolean</li></ul>
|
||||
|
||||
<p>Show information in JSON format.</p>
|
||||
|
||||
<h3 id="long">long</h3>
|
||||
|
||||
<ul><li>Default: false</li><li>Type: Boolean</li></ul>
|
||||
|
@ -52,7 +58,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">list — npm@1.1.1</p>
|
||||
<p id="footer">list — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
|
||||
<h2 id="VERSION">VERSION</h2>
|
||||
|
||||
<p>1.1.1</p>
|
||||
<p>1.1.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 — npm@1.1.1</p>
|
||||
<p id="footer">npm — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">outdated — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">owner — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">pack — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">prefix — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -25,7 +25,7 @@ package'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 — npm@1.1.1</p>
|
||||
<p id="footer">prune — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -29,7 +29,7 @@ the registry. Overwrites when the "--force" 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 — npm@1.1.1</p>
|
||||
<p id="footer">publish — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">rebuild — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -97,7 +97,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 — npm@1.1.1</p>
|
||||
<p id="footer">registry — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">removing-npm — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -24,7 +24,7 @@ the "start" 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 — npm@1.1.1</p>
|
||||
<p id="footer">restart — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">root — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">run-script — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -164,7 +164,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 — npm@1.1.1</p>
|
||||
<p id="footer">scripts — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">search — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">semver — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -0,0 +1,204 @@
|
|||
<!doctype html>
|
||||
<html>
|
||||
<title>shrinkwrap</title>
|
||||
<meta http-equiv="content-type" value="text/html;utf-8">
|
||||
<link rel="stylesheet" type="text/css" href="./style.css">
|
||||
|
||||
<body>
|
||||
<div id="wrapper">
|
||||
<h1><a href="../doc/shrinkwrap.html">shrinkwrap</a></h1> <p>Lock down dependency versions</p>
|
||||
|
||||
<h2 id="SYNOPSIS">SYNOPSIS</h2>
|
||||
|
||||
<pre><code>npm shrinkwrap</code></pre>
|
||||
|
||||
<h2 id="DESCRIPTION">DESCRIPTION</h2>
|
||||
|
||||
<p>This command locks down the versions of a package's dependencies so that you can
|
||||
control exactly which versions of each dependency will be used when your package
|
||||
is installed.</p>
|
||||
|
||||
<p>By default, "npm install" recursively installs the target's dependencies (as
|
||||
specified in package.json), choosing the latest available version that satisfies
|
||||
the dependency's semver pattern. In some situations, particularly when shipping
|
||||
software where each change is tightly managed, it's desirable to fully specify
|
||||
each version of each dependency recursively so that subsequent builds and
|
||||
deploys do not inadvertently pick up newer versions of a dependency that satisfy
|
||||
the semver pattern. Specifying specific semver patterns in each dependency's
|
||||
package.json would facilitate this, but that's not always possible or desirable,
|
||||
as when another author owns the npm package. It's also possible to check
|
||||
dependencies directly into source control, but that may be undesirable for other
|
||||
reasons.</p>
|
||||
|
||||
<p>As an example, consider package A:</p>
|
||||
|
||||
<pre><code>{
|
||||
"name": "A",
|
||||
"version": "0.1.0",
|
||||
"dependencies": {
|
||||
"B": "<0.1.0"
|
||||
}
|
||||
}</code></pre>
|
||||
|
||||
<p>package B:</p>
|
||||
|
||||
<pre><code>{
|
||||
"name": "B",
|
||||
"version": "0.0.1",
|
||||
"dependencies": {
|
||||
"C": "<0.1.0"
|
||||
}
|
||||
}</code></pre>
|
||||
|
||||
<p>and package C:</p>
|
||||
|
||||
<pre><code>{
|
||||
"name": "C,
|
||||
"version": "0.0.1"
|
||||
}</code></pre>
|
||||
|
||||
<p>If these are the only versions of A, B, and C available in the registry, then
|
||||
a normal "npm install A" will install:</p>
|
||||
|
||||
<pre><code>A@0.1.0
|
||||
`-- B@0.0.1
|
||||
`-- C@0.0.1</code></pre>
|
||||
|
||||
<p>However, if B@0.0.2 is published, then a fresh "npm install A" will install:</p>
|
||||
|
||||
<pre><code>A@0.1.0
|
||||
`-- B@0.0.2
|
||||
`-- C@0.0.1</code></pre>
|
||||
|
||||
<p>assuming the new version did not modify B's dependencies. Of course, the new
|
||||
version of B could include a new version of C and any number of new
|
||||
dependencies. If such changes are undesirable, the author of A could specify a
|
||||
dependency on B@0.0.1. However, if A's author and B's author are not the same
|
||||
person, there's no way for A's author to say that he or she does not want to
|
||||
pull in newly published versions of C when B hasn't changed at all.</p>
|
||||
|
||||
<p>In this case, A's author can run</p>
|
||||
|
||||
<pre><code>npm shrinkwrap</code></pre>
|
||||
|
||||
<p>This generates npm-shrinkwrap.json, which will look something like this:</p>
|
||||
|
||||
<pre><code>{
|
||||
"name": "A",
|
||||
"version": "0.1.0",
|
||||
"dependencies": {
|
||||
"B": {
|
||||
"version": "0.0.1",
|
||||
"dependencies": {
|
||||
"C": {
|
||||
"version": "0.1.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}</code></pre>
|
||||
|
||||
<p>The shrinkwrap command has locked down the dependencies based on what's
|
||||
currently installed in node_modules. When "npm install" installs a package with
|
||||
a npm-shrinkwrap.json file in the package root, the shrinkwrap file (rather than
|
||||
package.json files) completely drives the installation of that package and all
|
||||
of its dependencies (recursively). So now the author publishes A@0.1.0, and
|
||||
subsequent installs of this package will use B@0.0.1 and C@0.1.0, regardless the
|
||||
dependencies and versions listed in A's, B's, and C's package.json files.</p>
|
||||
|
||||
<h3 id="Using-shrinkwrapped-packages">Using shrinkwrapped packages</h3>
|
||||
|
||||
<p>Using a shrinkwrapped package is no different than using any other package: you
|
||||
can "npm install" it by hand, or add a dependency to your package.json file and
|
||||
"npm install" it.</p>
|
||||
|
||||
<h3 id="Building-shrinkwrapped-packages">Building shrinkwrapped packages</h3>
|
||||
|
||||
<p>To shrinkwrap an existing package:</p>
|
||||
|
||||
<ol><li>Run "npm install" in the package root to install the current versions of all
|
||||
dependencies.</li><li>Validate that the package works as expected with these versions.</li><li>Run "npm shrinkwrap", add npm-shrinkwrap.json to git, and publish your
|
||||
package.</li></ol>
|
||||
|
||||
<p>To add or update a dependency in a shrinkwrapped package:</p>
|
||||
|
||||
<ol><li>Run "npm install" in the package root to install the current versions of all
|
||||
dependencies.</li><li>Add or update dependencies. "npm install" each new or updated package
|
||||
individually and then update package.json. Note that they must be
|
||||
explicitly named in order to be installed: running <code>npm install</code> with
|
||||
no arguments will merely reproduce the existing shrinkwrap.</li><li>Validate that the package works as expected with the new dependencies.</li><li>Run "npm shrinkwrap", commit the new npm-shrinkwrap.json, and publish your
|
||||
package.</li></ol>
|
||||
|
||||
<p>You can use <a href="../doc/outdated.html">outdated(1)</a> to view dependencies with newer versions available.</p>
|
||||
|
||||
<h3 id="Other-Notes">Other Notes</h3>
|
||||
|
||||
<p>Since "npm shrinkwrap" uses the locally installed packages to construct the
|
||||
shrinkwrap file, devDependencies will be included if and only if you've
|
||||
installed them already when you make the shrinkwrap.</p>
|
||||
|
||||
<p>A shrinkwrap file must be consistent with the package's package.json file. "npm
|
||||
shrinkwrap" will fail if required dependencies are not already installed, since
|
||||
that would result in a shrinkwrap that wouldn't actually work. Similarly, the
|
||||
command will fail if there are extraneous packages (not referenced by
|
||||
package.json), since that would indicate that package.json is not correct.</p>
|
||||
|
||||
<p>If shrinkwrapped package A depends on shrinkwrapped package B, B's shrinkwrap
|
||||
will not be used as part of the installation of A. However, because A's
|
||||
shrinkwrap is constructed from a valid installation of B and recursively
|
||||
specifies all dependencies, the contents of B's shrinkwrap will implicitly be
|
||||
included in A's shrinkwrap.</p>
|
||||
|
||||
<h3 id="Caveats">Caveats</h3>
|
||||
|
||||
<p>Shrinkwrap files only lock down package versions, not actual package contents.
|
||||
While discouraged, a package author can republish an existing version of a
|
||||
package, causing shrinkwrapped packages using that version to pick up different
|
||||
code than they were before. If you want to avoid any risk that a byzantine
|
||||
author replaces a package you're using with code that breaks your application,
|
||||
you could modify the shrinkwrap file to use git URL references rather than
|
||||
version numbers so that npm always fetches all packages from git.</p>
|
||||
|
||||
<p>If you wish to lock down the specific bytes included in a package, for
|
||||
example to have 100% confidence in being able to reproduce a deployment
|
||||
or build, then you ought to check your dependencies into source control,
|
||||
or pursue some other mechanism that can verify contents rather than
|
||||
versions.</p>
|
||||
|
||||
<h2 id="SEE-ALSO">SEE ALSO</h2>
|
||||
|
||||
<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 — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
var els = Array.prototype.slice.call(wrapper.getElementsByTagName("*"), 0)
|
||||
.filter(function (el) {
|
||||
return el.parentNode === wrapper
|
||||
&& el.tagName.match(/H[1-6]/)
|
||||
&& el.id
|
||||
})
|
||||
var l = 2
|
||||
, toc = document.createElement("ul")
|
||||
toc.innerHTML = els.map(function (el) {
|
||||
var i = el.tagName.charAt(1)
|
||||
, out = ""
|
||||
while (i > l) {
|
||||
out += "<ul>"
|
||||
l ++
|
||||
}
|
||||
while (i < l) {
|
||||
out += "</ul>"
|
||||
l --
|
||||
}
|
||||
out += "<li><a href='#" + el.id + "'>" +
|
||||
( el.innerText || el.text || el.innerHTML)
|
||||
+ "</a>"
|
||||
return out
|
||||
}).join("\n")
|
||||
toc.id = "toc"
|
||||
document.body.appendChild(toc)
|
||||
})()
|
||||
</script>
|
||||
</body></html>
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">star — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">start — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">stop — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">submodule — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">tag — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">test — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">uninstall — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
|
@ -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 — npm@1.1.1</p>
|
||||
<p id="footer">unpublish — npm@1.1.2</p>
|
||||
<script>
|
||||
;(function () {
|
||||
var wrapper = document.getElementById("wrapper")
|
||||
|
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче