{"versions":{"1.0.0":{"name":"deps","version":"1.0.0","description":"Node dependency usage checker using V8 Coverage","keywords":["node","dependency","usage","coverage","v8"],"bin":{"deps":"bin/deps.js","deps-start":"bin/deps-start.sh","deps-stop":"bin/deps-stop.sh"},"scripts":{"build":"rm -rf dist && tsc -p src","dev":"npm run build -- -w","lint":"xo","version":"standard-version"},"husky":{"hooks":{"pre-commit":"lint-staged && tsc -p src --composite false --noEmit","commit-msg":"commitlint -E HUSKY_GIT_PARAMS"}},"lint-staged":{"*.[tj]s":"xo --fix"},"repository":{"type":"git","url":"git+https://github.com/privatenumber/deps.git"},"author":{"name":"Hiroki Osame","email":"hiroki.osame@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/privatenumber/deps/issues"},"homepage":"https://github.com/privatenumber/deps#readme","dependencies":{"chalk":"^4.1.0","cli-simple-table":"0.0.3","del":"^5.1.0","execa":"^4.0.1","minimist":"^1.2.5","read-pkg":"^5.2.0","sort-keys":"^4.0.0","tempy":"^0.5.0"},"devDependencies":{"@commitlint/cli":"^8.3.5","@commitlint/config-conventional":"^8.3.4","@types/minimist":"^1.2.0","@types/node":"^14.0.13","husky":"^4.2.5","lint-staged":"^10.2.10","standard-version":"^8.0.0","typescript":"^3.9.5","xo":"^0.32.0"},"gitHead":"290c77b0d5abcd9aaa3cbd80063657fdb728a702","_id":"deps@1.0.0","_nodeVersion":"12.18.0","_npmVersion":"6.14.4","dist":{"shasum":"b2ffb343c57e94847508b28c3f936c69da9e10dc","size":22951,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/deps/-/deps-1.0.0.tgz","integrity":"sha512-/mP1HrwnkRaetYr51krCOtAzHE9V5rV5/dhurFJ+B8ztvGP5zWdzBWqPMapyhIpPVy/9Kzr7JbeF0QaPhkF7aQ=="},"maintainers":[{"email":"hiroki.osame@gmail.com","name":"anonymous"}],"_npmUser":{"name":"anonymous","email":"hiroki.osame@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/deps_1.0.0_1592635666488_0.1437626955315361"},"_hasShrinkwrap":false,"publish_time":1592635666619,"_cnpm_publish_time":1592635666619,"_cnpmcore_publish_time":"2021-12-16T18:26:21.142Z","contributors":[]},"0.1.2":{"author":{"name":"Zeus Lalkaka","email":"lalkaka.zeus@gmail.com","url":"distracteddev.com"},"name":"deps","description":"A executable tool that allows you to add/remove/view your current depedencies from the command line","version":"0.1.2","repository":{"url":""},"main":"deps","dependencies":{},"devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"bin":{"deps":"./deps"},"_npmUser":{"name":"anonymous","email":"lalkaka.zeus@gmail.com"},"_id":"deps@0.1.2","_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/deps/-/deps-0.1.2.tgz","shasum":"c763b5ea142a264ed29a5f1be9de0c1df4b62cf8","size":1567,"noattachment":false,"integrity":"sha512-9/c64/m5aJXDxiYU+BxflH5vqhUZr2z/bC0cSt3YWen7CPU64VLtuHL6Lqt9B3RCAY+H8mc35ZPeYFVzOw2ZJg=="},"maintainers":[{"name":"anonymous","email":"lalkaka.zeus@gmail.com"}],"directories":{},"publish_time":1342516821354,"_hasShrinkwrap":false,"_cnpm_publish_time":1342516821354,"_cnpmcore_publish_time":"2021-12-16T18:26:21.378Z","contributors":[]},"0.1.1":{"author":{"name":"Zeus Lalkaka","email":"lalkaka.zeus@gmail.com","url":"distracteddev.com"},"name":"deps","description":"A executable tool that allows you to add/remove/view your current depedencies from the command line","version":"0.1.1","repository":{"url":""},"main":"deps","dependencies":{},"devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"bin":{"deps":"./deps"},"_npmUser":{"name":"anonymous","email":"lalkaka.zeus@gmail.com"},"_id":"deps@0.1.1","_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/deps/-/deps-0.1.1.tgz","shasum":"f0642132b9971a0e6767db644b63d9056485df21","size":1274,"noattachment":false,"integrity":"sha512-JtBMwrO0KF5vec8eBdFP4B3Iy2sP85/QwxAYyGdVdF1XrmJJOzMON+fIXuWwxurskrrz50rTU8udMZlznY0/5A=="},"maintainers":[{"name":"anonymous","email":"lalkaka.zeus@gmail.com"}],"directories":{},"publish_time":1342421724041,"_hasShrinkwrap":false,"_cnpm_publish_time":1342421724041,"_cnpmcore_publish_time":"2021-12-16T18:26:21.603Z","contributors":[]},"0.1.0":{"author":{"name":"Zeus Lalkaka","email":"lalkaka.zeus@gmail.com","url":"distracteddev.com"},"name":"deps","description":"A executable tool that allows you to add/remove/view your current depedencies from the command line","version":"0.1.0","repository":{"type":"git","url":"git://github.com/distracteddev/deps.git"},"main":"deps","dependencies":{},"devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"bin":{"deps":"./deps"},"homepage":"https://github.com/distracteddev/deps.git","_npmUser":{"name":"anonymous","email":"lalkaka.zeus@gmail.com"},"_id":"deps@0.1.0","_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/deps/-/deps-0.1.0.tgz","shasum":"e89cb484be637bff883489fa144d56c348c9ca22","size":1279,"noattachment":false,"integrity":"sha512-O1fjPkNDKu+LAWtSpBLx6mvd4yex9Cr5dRJal6ZtmGdACvsLX0MaP85N5HdgQOvHlkm0XVoGsQGfI/CHfYyPqw=="},"maintainers":[{"name":"anonymous","email":"lalkaka.zeus@gmail.com"}],"directories":{},"publish_time":1342398332293,"_hasShrinkwrap":false,"_cnpm_publish_time":1342398332293,"_cnpmcore_publish_time":"2021-12-16T18:26:21.901Z","contributors":[]}},"dist-tags":{"latest":"1.0.0"},"name":"deps","time":{"created":"2022-01-28T19:58:19.056Z","modified":"2023-08-01T13:29:48.245Z","1.0.0":"2020-06-20T06:47:46.619Z","0.1.2":"2012-07-17T09:20:21.354Z","0.1.1":"2012-07-16T06:55:24.041Z","0.1.0":"2012-07-16T00:25:32.293Z"},"readme":"# ???? deps <a href=\"https://npm.im/deps\"><img src=\"https://badgen.net/npm/v/deps\"></a> <a href=\"https://npm.im/deps\"><img src=\"https://badgen.net/npm/dm/deps\"></a> <a href=\"https://packagephobia.now.sh/result?p=deps\"><img src=\"https://packagephobia.now.sh/badge?p=deps\"></a>\n\n<p align=\"center\">\n  <img src=\"/.github/screenshot.png\" width=\"70%\">\n  <br>\n  Accurately detect which Node dependencies are in-use with V8 Coverage ????\n</p>\n\n#### Try it out!\n```sh\n$ npx deps [...command]\n```\n_eg. `npx deps npm run build`_\n\n## :rocket: Install\nInstall globally if you don't want to use it via [npx](https://blog.npmjs.org/post/162869356040/introducing-npx-an-npm-package-runner).\n```sh\nnpm i -g deps\n```\n\n## Usage\n### ???? Quick analysis\nPrefix your Node command with `deps` and it will analyze and output the dependencies it used\n```sh\n$ deps ...\n```\neg. `deps npm run build`\n\n### ????‍???? Analyzing dependency usage across commands\n_Prerequisite: install `deps` globally_\n1. Start recording dependecy usage (note the [dot-space](https://superuser.com/questions/1136409/what-is-the-dot-space-filename-command-doing-in-bash) at the beginning)\n  ```sh\n  $ . deps-start\n  ```\n\n2. Run a series of Node scripts eg.\n  - `npm run dev`\n  - `npm run build`\n  - `npm run lint`\n  - etc.\n\n3. Analyze used dependencies\n  ```sh\n  $ deps analyze\n  ```\n  - Save data to file:\n    ```sh\n    deps analyze -o output.json\n    ```\n  - Read later with:\n    ```sh\n    deps -f output.json\n    ```\n\n4. When you're done, stop recording\n  ```sh\n  $ . deps-stop\n  ```\n\n## ????‍♂️ FAQ\n\n#### How does it work?\n`deps` detects which modules are loaded by using [V8's code coverage](https://nodejs.org/api/cli.html#cli_node_v8_coverage_dir) feature, so it's very accurate. However, it doesn't detect file-system reads, as they are simply read as text rather than actually being parsed and executed. That means it can't detect what files are statically analyzed by bundlers (eg. Webpack, Rollup, etc.). I am considering supporting FS reads in the future.\n\n#### How does it compare to `depcheck`?\n[`depcheck`](https://github.com/depcheck/depcheck) statically analyzes your project to see which dependencies are imported, avoiding the need to execute code. In contrast, `deps` executes code to analyze which dependencies were loaded during run-time. They work in completely different ways, but a major drawback for me is that `depcheck` requires a [\"special\"](https://github.com/depcheck/depcheck#special) for supporting whether a module was loaded via dev-tools.\n\n## ???? License\nMIT","users":{}}