cnpm
cnpm: npm client for cnpmjs.org.
Requirements
Minimum | Recommended |
---|---|
:--- | :--- |
Node.js | 14.0.0 |
Install
- ``` shell
- npm install cnpm -g
- ```
If you're in China, maybe you should install it from our China mirror :
- ``` shell
- npm install cnpm -g --registry=https://registry.npmmirror.com
- ```
Usage
Support all commands just like npm.
Sync packages from npm
- ``` shell
- cnpm sync [moduleName]
- ```
Open package document or git web url
- ``` shell
- cnpm doc [name]
- cnpm doc -g [name] # open git web url directly
- ```
Build your own private registry npm cli
- ``` shell
- $ npm install cnpm -g
- # then alias it
- $ alias mynpm='cnpm --registry=https://registry.npm.example.com \
- --registryweb=https://npm.example.com \
- --userconfig=$HOME/.mynpmrc'
- ```
Install with original npm cli
cnpm using npminstall by default. If you don't like symlink mode for node_modules, you can change the installer to original npm. But you will lose the fastest install speed.
- ``` shell
- cnpm i --by=npm react-native
- ```
License
MIT
Contributors
This project follows the git-contributor spec , auto updated at Sat May 14 2022 18:18:46 GMT+0800.