安装命令

1
2
3
npm install // 安装所有 package.json 中的包
npm install package_name
npm install -g package_name

查看安装的包

1
2
3
4
5
npm list // 查看项目包
npm list -g // 查看全局包
npm ls // 查看项目包
npm ls -g // 查看全局包
npm ls hexo // 查看指定包

查看服务器上的某个包

1
2
npm view jquery versions // 查看所有版本
npm view jquery version // 查看最新的版本

查看包的信息

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
$ npm info hexo

hexo@5.4.2 | MIT | deps: 22 | versions: 154
A fast, simple & powerful blog framework, powered by Node.js.
https://hexo.io/

keywords: website, blog, cms, framework, hexo

bin: hexo

dist
.tarball: https://registry.npmjs.org/hexo/-/hexo-5.4.2.tgz
.shasum: 7337b6adb0d495287051c03e944d84f66f64e356
.integrity: sha512-Af6mxKwx9byalaffKgiQ8/bZfbXPo2SGEn2Q9hFh++15g15/IulvOhu8lQkJdyZNzmj3hOuSrJdqoUvIr3K/qw==
.unpackedSize: 216.9 kB

dependencies:
abbrev: ^1.1.1
archy: ^1.0.0
bluebird: ^3.5.2
chalk: ^4.0.0
hexo-cli: ^4.0.0
hexo-front-matter: ^2.0.0
hexo-fs: ^3.1.0
hexo-i18n: ^1.0.0
hexo-log: ^2.0.0
hexo-util: ^2.4.0
js-yaml: ^3.14.1
micromatch: ^4.0.2
moment-timezone: ^0.5.21
moment: ^2.22.2
nunjucks: ^3.2.1
pretty-hrtime: ^1.0.3
resolve: ^1.8.1
strip-ansi: ^6.0.0
text-table: ^0.2.0
tildify: ^2.0.0
titlecase: ^1.1.2
warehouse: ^4.0.0

maintainers:
- ertrzyiks <mateusz.derks@gmail.com>
- abnerchou <hi@abnerchou.me>
- tommy351 <tommy351@gmail.com>
- hexobot <hexojs@gmail.com>
- jlhwung <i@jhuang.me>
- tomap <piartt@gmail.com>
- curben <bushedge@protonmail.com>
- yoshinorin <yoshinorin.net@outlook.com>

dist-tags:
latest: 5.4.2
legacy: 5.4.1

published 3 days ago by yoshinorin <yoshinorin.net@outlook.com>