Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/coderofsalvation/npm-collect

automatically update package.json according to installed/linked modules in node_modules
https://github.com/coderofsalvation/npm-collect

Last synced: 12 days ago
JSON representation

automatically update package.json according to installed/linked modules in node_modules

Awesome Lists containing this project

README

        

# Useful when

* updating/developing several npm modules in parallel (especially using `npm link`)
* creating an package.json file after installing modules

# Usage

npm install -g npm-collect

then:

$ npm-collect --help
Usage: npm-collect
Options:
--devDependencies process dev-dependencies instead of dependencies
--new include modules which are not found in package.json, but are installed
--save write changes to package.json
-v verboselevel (0=silent,1=normal,2=debug)

# Examples

Just see differences without writing to package.json

$ npm-collect
[email protected] -> 0.2.0
[email protected] -> 0.3.0

update your package.json

$ npm-collect --save
[email protected] -> 0.2.0
[email protected] -> 0.3.0

update package.json with newly discovered modules in node_modules

$ npm-collect --new --save
querystring@(unsaved) -> 0.2.0
ohmypgrah@(unsaved) -> 0.2.0