npm: upgrade to v1.4.14
[platform/upstream/nodejs.git] / deps / npm / man / man1 / npm-cache.1
1 .\" Generated with Ronnjs 0.3.8
2 .\" http://github.com/kapouer/ronnjs/
3 .
4 .TH "NPM\-CACHE" "1" "June 2014" "" ""
5 .
6 .SH "NAME"
7 \fBnpm-cache\fR \-\- Manipulates packages cache
8 .
9 .SH "SYNOPSIS"
10 .
11 .nf
12 npm cache add <tarball file>
13 npm cache add <folder>
14 npm cache add <tarball url>
15 npm cache add <name>@<version>
16 npm cache ls [<path>]
17 npm cache clean [<path>]
18 .
19 .fi
20 .
21 .SH "DESCRIPTION"
22 Used to add, list, or clear the npm cache folder\.
23 .
24 .IP "\(bu" 4
25 add:
26 Add the specified package to the local cache\.  This command is primarily
27 intended to be used internally by npm, but it can provide a way to
28 add data to the local installation cache explicitly\.
29 .
30 .IP "\(bu" 4
31 ls:
32 Show the data in the cache\.  Argument is a path to show in the cache
33 folder\.  Works a bit like the \fBfind\fR program, but limited by the \fBdepth\fR config\.
34 .
35 .IP "\(bu" 4
36 clean:
37 Delete data out of the cache folder\.  If an argument is provided, then
38 it specifies a subpath to delete\.  If no argument is provided, then
39 the entire cache is cleared\.
40 .
41 .IP "" 0
42 .
43 .SH "DETAILS"
44 npm stores cache data in the directory specified in \fBnpm config get cache\fR\|\.
45 For each package that is added to the cache, three pieces of information are
46 stored in \fB{cache}/{name}/{version}\fR:
47 .
48 .IP "\(bu" 4
49 \|\.\.\./package/package\.json:
50 The package\.json file, as npm sees it\.
51 .
52 .IP "\(bu" 4
53 \|\.\.\./package\.tgz:
54 The tarball for that version\.
55 .
56 .IP "" 0
57 .
58 .P
59 Additionally, whenever a registry request is made, a \fB\|\.cache\.json\fR file
60 is placed at the corresponding URI, to store the ETag and the requested
61 data\.  This is stored in \fB{cache}/{hostname}/{path}/\.cache\.json\fR\|\.
62 .
63 .P
64 Commands that make non\-essential registry requests (such as \fBsearch\fR and \fBview\fR, or the completion scripts) generally specify a minimum timeout\.
65 If the \fB\|\.cache\.json\fR file is younger than the specified timeout, then
66 they do not make an HTTP request to the registry\.
67 .
68 .SH "CONFIGURATION"
69 .
70 .SS "cache"
71 Default: \fB~/\.npm\fR on Posix, or \fB%AppData%/npm\-cache\fR on Windows\.
72 .
73 .P
74 The root cache folder\.
75 .
76 .SH "SEE ALSO"
77 .
78 .IP "\(bu" 4
79 npm help  folders
80 .
81 .IP "\(bu" 4
82 npm help config
83 .
84 .IP "\(bu" 4
85 npm help  config
86 .
87 .IP "\(bu" 4
88 npm help  npmrc
89 .
90 .IP "\(bu" 4
91 npm help install
92 .
93 .IP "\(bu" 4
94 npm help publish
95 .
96 .IP "\(bu" 4
97 npm help pack
98 .
99 .IP "" 0
100