pnpm
Version:
Fast, disk space efficient package manager
142 lines (141 loc) • 8.68 kB
JSON
{
"_args": [
[
{
"raw": "dependencies-hierarchy@5.0.5",
"scope": null,
"escapedName": "dependencies-hierarchy",
"name": "dependencies-hierarchy",
"rawSpec": "5.0.5",
"spec": "5.0.5",
"type": "version"
},
"/home/zoltan/src/pnpm/pnpm/packages/pnpm/node_modules/@pnpm/list"
]
],
"_from": "dependencies-hierarchy@5.0.5",
"_hasShrinkwrap": false,
"_id": "dependencies-hierarchy@5.0.5",
"_location": "/dependencies-hierarchy",
"_nodeVersion": "10.12.0",
"_npmOperationalInternal": {
"host": "s3://npm-registry-packages",
"tmp": "tmp/dependencies-hierarchy_5.0.5_1556137019767_0.70675225555288"
},
"_npmUser": {
"name": "zkochan",
"email": "z@kochan.io"
},
"_npmVersion": "6.9.0",
"_phantomChildren": {},
"_requested": {
"raw": "dependencies-hierarchy@5.0.5",
"scope": null,
"escapedName": "dependencies-hierarchy",
"name": "dependencies-hierarchy",
"rawSpec": "5.0.5",
"spec": "5.0.5",
"type": "version"
},
"_requiredBy": [
"/@pnpm/list"
],
"_resolved": "https://registry.npmjs.org/dependencies-hierarchy/-/dependencies-hierarchy-5.0.5.tgz",
"_shasum": "aaa7641422a0f9bcdfa5f04cb943a6626dff5db6",
"_shrinkwrap": null,
"_spec": "dependencies-hierarchy@5.0.5",
"_where": "/home/zoltan/src/pnpm/pnpm/packages/pnpm/node_modules/@pnpm/list",
"author": {
"name": "Zoltan Kochan",
"email": "z@kochan.io",
"url": "https://www.kochan.io/"
},
"bugs": {
"url": "https://github.com/pnpm/pnpm/issues"
},
"dependencies": {
"@pnpm/lockfile-file": "1.0.4",
"@pnpm/modules-yaml": "3.0.2",
"@pnpm/read-modules-dir": "2.0.0",
"@pnpm/types": "3.2.0",
"@pnpm/utils": "0.10.4",
"@types/node": "*",
"@types/semver": "6.0.0",
"dependency-path": "3.0.4",
"normalize-path": "3.0.0",
"resolve-link-target": "1.0.1",
"semver": "6.0.0"
},
"description": "Creates a dependencies hierarchy for a symlinked `node_modules`",
"devDependencies": {
"@pnpm/constants": "1.0.0",
"@pnpm/logger": "2.1.0",
"@pnpm/tslint-config": "0.0.0",
"@types/tape": "4.2.33",
"dependencies-hierarchy": "link:",
"mos": "2.0.0-alpha.3",
"mos-plugin-readme": "1.0.4",
"mos-tap-diff": "1.0.0",
"tape": "4.10.1",
"ts-node": "8.1.0",
"tslint": "5.16.0",
"typescript": "3.4.5"
},
"directories": {},
"dist": {
"integrity": "sha512-/zPFtEh+ocmw5FJ82MKASV1NkRgbeMLtVa/d57UMlhoj4q9wfeZwOcvIcP3R0p5fbghtOOUwDGOV4YSAU4BTUg==",
"shasum": "aaa7641422a0f9bcdfa5f04cb943a6626dff5db6",
"tarball": "https://registry.npmjs.org/dependencies-hierarchy/-/dependencies-hierarchy-5.0.5.tgz",
"fileCount": 6,
"unpackedSize": 21624,
"npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcwMQ8CRA9TVsSAnZWagAAGe0P/iUZYkLJ5p1Rt5ZVqsrC\nET7sSh5c6EKSuD/bvN5M+nhDfXh2hM+QI9GFymH1GJYnD2GtJaz3mF7vMbel\nFAcpTNZCRR7V7Ct+taEJcjE8HRsfCFgiAisv3pvtOgzs8zxLmirsQDZFL5gM\nce1kGN71RNJIfl/AD/+Fq4S0F62rxBJXjJIV6hAzJ2U40l4+AXd44C8GQtxe\nr06FbZgJ2QwWmctwW35rDl7nByTZlpvPwunv2RmszthkMMC22Kx42ecQlAeY\nquSROqtkjlwI9FC1XQYgSW+i4utdCmBSsFrPAJcCTOi5QkENlZXfopLMSrux\nvFTKY5hd/Mr99mxSGCVRyG5qMxW2BFBaZllq8thJi/6R1ktlTAJ03fcTY7C4\nfRZS9B67k6Wnh6YASXLaFcyDIRaH3386aTdRXMv0RytT72C94KkGMdUWd6mQ\nx115mf5PVhfCjnH/J2lx/KjAVi4cFmeS2QEzhnaDtzDWBwC3h0yXLEhEtvxe\nj2pJ/55Or26+kY/eVrFgQkkDtEpw58QZ7mhPqbV+eU0LxSRFzgsV9XvX0EEK\nkQCoXyrhjEg0eG9DU8uR9hrgejhwjkiU5FPDNLYBqIx+urXeCSCqLqUIzCgI\npXskN1BcguyyyQrvMu07Oz+M2CWV98RF67KsYohqjE5f1JRHJ42t3p9E9h+I\n65Ie\r\n=oR9C\r\n-----END PGP SIGNATURE-----\r\n"
},
"engines": {
"node": ">=8.15"
},
"files": [
"lib"
],
"homepage": "https://github.com/pnpm/pnpm/blob/master/packages/dependencies-hierarchy#readme",
"keywords": [
"hierarchy",
"pnpm",
"dependencies",
"node_modules"
],
"license": "MIT",
"main": "lib/index.js",
"maintainers": [
{
"name": "zkochan",
"email": "zoltan.kochan@gmail.com"
}
],
"mos": {
"plugins": [
"readme"
],
"installation": {
"useShortAlias": true
}
},
"name": "dependencies-hierarchy",
"optionalDependencies": {},
"readme": "# dependencies-hierarchy\n\n> Creates a dependencies hierarchy for a symlinked \\`node_modules\\`\n\n<!--@shields('npm')-->\n[](https://www.npmjs.com/package/dependencies-hierarchy)\n<!--/@-->\n\nA symlinked `node_modules` is created when installing using [pnpm](https://github.com/pnpm/pnpm).\n\n## Install\n\nInstall it via npm.\n\n npm install dependencies-hierarchy\n\n## Usage\n\n```js\n'use strict'\nconst hierarchyForPackages = require('dependencies-hierarchy').forPackages\n\nhierarchyForPackages(['graceful-fs', {name: 'pify', range: '2'}], __dirname, {depth: 2})\n .then(tree => {\n console.log(JSON.stringify(tree, null, 2))\n //> [\n // {\n // \"dependencies\": [\n // {\n // \"dependencies\": [\n // {\n // \"pkg\": {\n // \"name\": \"graceful-fs\",\n // \"path\": \"/home/zoltan/src/pnpm/pnpm/packages/dependencies-hierarchy/example/node_modules/.registry.npmjs.org/graceful-fs/4.1.11\",\n // \"version\": \"4.1.11\"\n // },\n // \"searched\": true\n // },\n // {\n // \"pkg\": {\n // \"name\": \"pify\",\n // \"path\": \"/home/zoltan/src/pnpm/pnpm/packages/dependencies-hierarchy/example/node_modules/.registry.npmjs.org/pify/2.3.0\",\n // \"version\": \"2.3.0\"\n // },\n // \"searched\": true\n // }\n // ],\n // \"pkg\": {\n // \"name\": \"write-json-file\",\n // \"path\": \"/home/zoltan/src/pnpm/pnpm/packages/dependencies-hierarchy/example/node_modules/.registry.npmjs.org/write-json-file/2.2.0\",\n // \"version\": \"2.2.0\"\n // }\n // }\n // ],\n // \"pkg\": {\n // \"name\": \"write-pkg\",\n // \"path\": \"/home/zoltan/src/pnpm/pnpm/packages/dependencies-hierarchy/example/node_modules/.registry.npmjs.org/write-pkg/3.1.0\",\n // \"version\": \"3.1.0\"\n // }\n // }\n // ]\n })\n```\n\n## API\n\n### default: `dependenciesHierarchy(projectPath, [opts]): Promise<Hierarchy>`\n\nCreates a dependency tree for a project's `node_modules`.\n\n#### Arguments:\n\n- `projectPath` - _String_ - The path to the project.\n- `[opts.depth]` - _Number_ - 0 by default. How deep should the `node_modules` be analyzed.\n- `[opts.only]` - _'dev' | 'prod'_ - Optional. If set to `dev`, then only packages from `devDependencies` are analyzed.\n If set to `prod`, then only packages from `dependencies` are analyzed.\n\n### `forPackages(packageSelectors, projectPath, [opts]): Promise<Hierarchy>`\n\nCreates a dependency tree for a project's `node_modules`. Limits the results to only the paths to the packages named.\n\n#### Arguments:\n\n- `packageSelectors` - _(string | {name: string, version: string})\\[]_ - An array that consist of package names or package names and version ranges.\n E.g. `['foo', {name: 'bar', version: '^2.0.0'}]`.\n- `projectPath` - _String_ - The path to the project\n- `[opts.depth]` - _Number_ - 0 by default. How deep should the `node_modules` be analyzed.\n- `[opts.only]` - _'dev' | 'prod'_ - Optional. If set to `dev`, then only packages from `devDependencies` are analyzed.\n If set to `prod`, then only packages from `dependencies` are analyzed.\n\n## License\n\n[MIT](./LICENSE) © [Zoltan Kochan](https://www.kochan.io/)\n",
"readmeFilename": "README.md",
"repository": {
"type": "git",
"url": "https://github.com/pnpm/pnpm/blob/master/packages/dependencies-hierarchy"
},
"scripts": {
"fix": "tslint -c tslint.json src/**/*.ts test/**/*.ts --fix",
"lint": "tslint -c tslint.json src/**/*.ts test/**/*.ts",
"md": "tsc && mos",
"prepublishOnly": "tsc",
"pretest": "cd fixtures && pnpm recursive install --frozen-lockfile --no-shared-workspace-lockfile --no-link-workspace-packages && cd ../fixtureWithLinks && pnpm recursive install --frozen-lockfile --link-workspace-packages --no-shared-workspace-lockfile && cd ..",
"test": "npm run tsc && npm run lint && ts-node test --type-check && mos t",
"tsc": "tsc"
},
"typings": "lib/index.d.ts",
"version": "5.0.5"
}