Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

cnpm

cnpm14.9kMIT9.4.0TypeScript support: included

cnpm: npm client for cnpmjs.org

cnpm, npm, npminstall

readme

cnpm

NPM Version NPM Download NPM Quality GitHub Actions CI FOSSA Status

logo

cnpm: npm client for npmmirror.com

Requirements

| | Minimum | Recommended | |---------|---------|-------------| | Node.js | 14.18.0 | LTS |

Install

npm install cnpm -g

If you're in China, maybe you should install it from our China mirror:

npm install cnpm -g --registry=https://registry.npmmirror.com

Usage

Support all commands just like npm.

Sync packages from npm

cnpm sync [moduleName]

Open package document or git web url

cnpm doc [name]
cnpm doc -g [name] # open git web url directly

Build your own private registry npm cli

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.

cnpm i --by=npm react-native

License

MIT

Contributors


fengmk2


dead-horse


semantic-release-bot


alsotang


0xflotus


weakish


gemwuu


ibigbug


qiu8310


elrrrrrrr


fossabot


popomore


xieren58


xiaohuoni

This project follows the git-contributor spec, auto updated at Wed Dec 06 2023 21:42:25 GMT+0800.

FOSSA Status

changelog

Changelog

All notable changes to this project will be documented in this file. See standard-version for commit guidelines.

7.0.3 (2020-05-25)

Bug Fixes

  • detect path key based on correct environment (#133) (159e7e9)

7.0.2 (2020-04-04)

Bug Fixes

  • fix worker threads in Node >=11.10.0 (#132) (6c5b4f0)

7.0.1 (2019-10-07)

Bug Fixes

7.0.0 (2019-09-03)

⚠ BREAKING CHANGES

  • drop support for Node.js < 8

  • drop support for versions below Node.js 8 (#125) (16feb53)

6.0.5 (2018-03-02)

Bug Fixes

6.0.4 (2018-01-31)

Bug Fixes

  • fix paths being incorrectly normalized on unix (06ee3c6), closes #90

6.0.3 (2018-01-23)

6.0.2 (2018-01-23)

6.0.1 (2018-01-23)

6.0.0 (2018-01-23)

Bug Fixes

  • fix certain arguments not being correctly escaped or causing batch syntax error (900cf10), closes #82 #51
  • fix commands as posix relatixe paths not working correctly, e.g.: ./my-command (900cf10)
  • fix options argument being mutated (900cf10)
  • fix commands resolution when PATH was actually Path (900cf10)

Features

  • improve compliance with node's ENOENT errors (900cf10)
  • improve detection of node's shell option support (900cf10)

Chores

  • upgrade tooling
  • upgrate project to es6 (node v4)

BREAKING CHANGES

  • remove support for older nodejs versions, only node >= 4 is supported

5.1.0 (2017-02-26)

Bug Fixes

  • fix options.shell support for NodeJS v4.8

5.0.1 (2016-11-04)

Bug Fixes

  • fix options.shell support for NodeJS v7

5.0.0 (2016-10-30)

Features

  • add support for options.shell
  • improve parsing of shebangs by using shebang-command module

Chores

  • refactor some code to make it more clear
  • update README caveats