{"name":"module-details-from-path","version":"1.0.4","description":"Resolve npm package details, like name and base path, given an absolute path to a file inside a package","main":"index.js","dependencies":{},"devDependencies":{"bench-node":"^0.5.4","standard":"^15.0.1","tape":"^4.6.0"},"scripts":{"bench":"node --allow-natives-syntax bench.js","lint":"standard","test":"standard && node test.js","test:ci":"node test.js"},"repository":{"type":"git","url":"git+https://github.com/watson/module-details-from-path.git"},"keywords":["node","nodejs","npm","module","package","extract","parse","name","basedir","directory","path","relative"],"author":{"name":"Thomas Watson","email":"w@tson.dk","url":"https://wa.tson.dk/"},"license":"MIT","bugs":{"url":"https://github.com/watson/module-details-from-path/issues"},"homepage":"https://github.com/watson/module-details-from-path#readme","coordinates":[55.666507,12.5798711],"_id":"module-details-from-path@1.0.4","gitHead":"a7df269d5eb0803bb26ab61cb486f7c1fb4fad9c","_nodeVersion":"22.14.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-EGWKgxALGMgzvxYF1UyGTy0HXX/2vHLkw6+NvDKW2jypWbHpjQuj4UMcqQWXHERJhVGKikolT06G3bcKe4fi7w==","shasum":"b662fdcd93f6c83d3f25289da0ce81c8d9685b94","tarball":"http://registry-npm.ywwl.com/module-details-from-path/download/module-details-from-path-1.0.4.tgz","fileCount":4,"unpackedSize":3958,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIE8MWZakKcUYdjHnIqDS3U26etM9f4/kclfFvn6gSZ7IAiEAtJlPgGq/oHaZNWEvjudwfujIIzfmXlg1jG+O9P88/eg="}],"size":1961,"noattachment":false,"key":"/module-details-from-path/-/module-details-from-path-1.0.4.tgz"},"_npmUser":{"name":"watson","email":"w@tson.dk"},"directories":{},"maintainers":[{"name":"watson","email":"w@tson.dk"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/module-details-from-path_1.0.4_1745945993545_0.3113631506706067"},"_hasShrinkwrap":false,"readme":"# module-details-from-path\n\nResolve npm package details, like name and base path, given an absolute path to a file inside a package.\n\n[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat)](https://github.com/feross/standard)\n\n## Installation\n\n```\nnpm install module-details-from-path --save\n```\n\n## Usage\n\n```js\nconst assert = require('assert')\nconst parse = require('module-details-from-path')\n\nconst path = '/Users/watson/code/node_modules/blackjack/node_modules/picture-tube/bin/tube.js'\n\nassert.deepStrictEqual(parse(path), {\n  name: 'picture-tube',\n  basedir: '/Users/watson/code/node_modules/blackjack/node_modules/picture-tube',\n  path: 'bin/tube.js'\n})\n```\n\nReturns `undefined` if module details cannot be found.\n\n## License\n\nMIT\n","publish_time":1745945993775,"_cnpm_publish_time":1745945993775,"dist-tags":{"latest":"1.0.4"}}