npm-utils

Async NPM shell commands

npm install npm-utils
2 downloads in the last day
3 downloads in the last week
56 downloads in the last month

npm-utils

Async NPM shell commands: install, test, etc.

NPM info

Build dependencies devDependencies endorse

API

path() // returns immediately path to npm command
install({
    name: string,
    version: string (optional),
    prefix: string (optional), // folder path prefix
    passThroughData: obj (optional)
})

returns a promise
version() // returns a promise, resolved with version string
test() // spawns npm test command
registryUrl(); // returns a promise
// same as `npm config get registry`

Small print

Author: Gleb Bahmutov @ 2013 @bahmutov

License: MIT - do anything with the code, but don't blame me if it does not work.

npm loves you