{"name":"is-npm","version":"2.0.0","description":"Check if your code is running as an npm script","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/is-npm.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"sindresorhus.com"},"engines":{"node":">=6"},"scripts":{"test":"xo && ava"},"files":["index.js"],"keywords":["npm","is","check","detect","env","environment","run","script"],"devDependencies":{"ava":"*","xo":"*"},"gitHead":"2daa4ad780c5a07d73eb5c317a5b9e68f7a78473","bugs":{"url":"https://github.com/sindresorhus/is-npm/issues"},"homepage":"https://github.com/sindresorhus/is-npm#readme","_id":"is-npm@2.0.0","_npmVersion":"5.6.0","_nodeVersion":"8.9.4","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"integrity":"sha512-QQf2fxA0YpblpHS0FbtAk+BtNwj6ywTCyehGS8jpTLEUKFjh4sWZ+gIWaqLCDgtKrbdqB2umjGAqlTDIMiLM8A==","shasum":"d8449be037d3cf146ead95c67d84b76396fbdb32","tarball":"http://registry-npm.ywwl.com/is-npm/download/is-npm-2.0.0.tgz","fileCount":4,"unpackedSize":2328,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGJXxA1TO2DkPq6be941XfClZWkS4usU9uB/K6zvl5j8AiEA9yW7Kczh2BuW4z873Esp/ZfiDE1swsRXeDEFFZ8z0lY="}],"size":1446,"noattachment":false,"key":"/is-npm/-/is-npm-2.0.0.tgz"},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-npm_2.0.0_1521731162192_0.38421678949459337"},"_hasShrinkwrap":false,"readme":"# is-npm\n\n> Check if your code is running as an [npm](https://docs.npmjs.com/misc/scripts) or [yarn](https://yarnpkg.com/lang/en/docs/cli/run/) script\n\n## Install\n\n```sh\nnpm install is-npm\n```\n\n## Usage\n\n```js\nimport {isNpmOrYarn, isNpm, isYarn} from 'is-npm';\n\nconsole.table({isNpmOrYarn, isNpm, isYarn});\n```\n\n```sh\n$ node foo.js\n# ┌─────────────┬────────┐\n# │   (index)   │ Values │\n# ├─────────────┼────────┤\n# │ isNpmOrYarn │ false  │\n# │    isNpm    │ false  │\n# │   isYarn    │ false  │\n# └─────────────┴────────┘\n$ npm run foo\n# ┌─────────────┬────────┐\n# │   (index)   │ Values │\n# ├─────────────┼────────┤\n# │ isNpmOrYarn │  true  │\n# │    isNpm    │  true  │\n# │   isYarn    │ false  │\n# └─────────────┴────────┘\n$ yarn run foo\n# ┌─────────────┬────────┐\n# │   (index)   │ Values │\n# ├─────────────┼────────┤\n# │ isNpmOrYarn │  true  │\n# │    isNpm    │ false  │\n# │   isYarn    │  true  │\n# └─────────────┴────────┘\n```\n\n## Related\n\n- [is-npm-cli](https://github.com/sindresorhus/is-npm-cli) - CLI for this module\n\n---\n\n<div align=\"center\">\n\t<b>\n\t\t<a href=\"https://tidelift.com/subscription/pkg/npm-is-npm?utm_source=npm-is-npm&utm_medium=referral&utm_campaign=readme\">Get professional support for this package with a Tidelift subscription</a>\n\t</b>\n\t<br>\n\t<sub>\n\t\tTidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.\n\t</sub>\n</div>\n","publish_time":1521731162269,"_cnpm_publish_time":1521731162269,"dist-tags":{"latest":"6.1.0"}}