{"name":"resolve-bin","version":"0.3.0","description":"Resolves the full path to the bin file of a given package by inspecting the \"bin\" field in its package.json.","main":"index.js","scripts":{"test":"tap test/*.js"},"repository":{"type":"git","url":"git://github.com/thlorenz/resolve-bin.git"},"homepage":"https://github.com/thlorenz/resolve-bin","dependencies":{"find-parent-dir":"~0.1.0"},"devDependencies":{"tap":"~0.4.3","mocha":"~1.14.0"},"keywords":["resolve","bin","module"],"author":{"name":"Thorsten Lorenz","email":"thlorenz@gmx.de","url":"http://thlorenz.com"},"license":{"type":"MIT","url":"https://github.com/thlorenz/resolve-bin/blob/master/LICENSE"},"engine":{"node":">=0.6"},"bugs":{"url":"https://github.com/thlorenz/resolve-bin/issues"},"_id":"resolve-bin@0.3.0","dist":{"shasum":"798fb5b68ada15b80f906ce39d51343a17569aa1","tarball":"http://registry-npm.ywwl.com/resolve-bin/download/resolve-bin-0.3.0.tgz","integrity":"sha512-fs5rR1FF33XCG1MbKXkVcuHHl3+O098PzVloBZpQ/XeuCuj3JAD8cEpwRaoy2795/fWJ89Wl9tqEkqupSpojsg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBzjpxIj0Iwlt5CN6PI9C8K74OOCIAM6CosuVxfaEkfjAiEAmNM7SmL4uIV+W84+gazrDI6gHbVhocMPMKczvsa0/C0="}],"size":3358,"noattachment":false,"key":"/resolve-bin/-/resolve-bin-0.3.0.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"thlorenz","email":"thlorenz@gmx.de"},"maintainers":[{"name":"thlorenz","email":"thlorenz@gmx.de"}],"directories":{},"readme":"# resolve-bin [![Tests](https://github.com/thlorenz/resolve-bin/actions/workflows/test.yml/badge.svg)](https://github.com/thlorenz/resolve-bin/actions/workflows/test.yml)\n\nResolves the full path to the bin file of a given package by inspecting the `\"bin\"` field in its package.json.\n\n```js\nvar resolveBin = require('resolve-bin');\n\n// package.json: \"bin\": \"bin/tap.js\"\nresolveBin('tap', function (err, bin) {\n  if (err) return console.error(err);\n  console.log(bin);  \n});\n\n// => [..]/resolve-bin/node_modules/tap/bin/tap.js\n```\n\n## Installation\n\n    npm install resolve-bin\n\n## API\n\n\n<!-- START docme generated API please keep comment here to allow auto update -->\n<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN docme TO UPDATE -->\n\n<div>\n<div class=\"jsdoc-githubify\">\n<section>\n<article>\n<div class=\"container-overview\">\n<dl class=\"details\">\n</dl>\n</div>\n<dl>\n<dt>\n<h4 class=\"name\" id=\"resolveBin\"><span class=\"type-signature\"></span>resolveBin<span class=\"signature\">(name, <span class=\"optional\">opts</span>, cb)</span><span class=\"type-signature\"></span></h4>\n</dt>\n<dd>\n<div class=\"description\">\n<p>Resolves the full path to the bin file of a given package by inspecting the &quot;bin&quot; field in its package.json.</p>\n</div>\n<h5>Parameters:</h5>\n<table class=\"params\">\n<thead>\n<tr>\n<th>Name</th>\n<th>Type</th>\n<th>Argument</th>\n<th class=\"last\">Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td class=\"name\"><code>name</code></td>\n<td class=\"type\">\n<span class=\"param-type\">string</span>\n</td>\n<td class=\"attributes\">\n</td>\n<td class=\"description last\"><p>module name, i.e. 'tap'</p></td>\n</tr>\n<tr>\n<td class=\"name\"><code>opts</code></td>\n<td class=\"type\">\n<span class=\"param-type\">Object</span>\n</td>\n<td class=\"attributes\">\n&lt;optional><br>\n</td>\n<td class=\"description last\"><p>options</p>\n<h6>Properties</h6>\n<table class=\"params\">\n<thead>\n<tr>\n<th>Name</th>\n<th>Type</th>\n<th class=\"last\">Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td class=\"name\"><code>executable</code></td>\n<td class=\"type\">\n<span class=\"param-type\">string</span>\n</td>\n<td class=\"description last\"><p>(default: @name) executable name (e.g. 'buster-test')</p></td>\n</tr>\n</tbody>\n</table>\n</td>\n</tr>\n<tr>\n<td class=\"name\"><code>cb</code></td>\n<td class=\"type\">\n<span class=\"param-type\">function</span>\n</td>\n<td class=\"attributes\">\n</td>\n<td class=\"description last\"><p>called back with the full path to the bin file of the module or an error if it couldn't be resolved</p></td>\n</tr>\n</tbody>\n</table>\n<dl class=\"details\">\n<dt class=\"tag-source\">Source:</dt>\n<dd class=\"tag-source\"><ul class=\"dummy\">\n<li>\n<a href=\"https://github.com/thlorenz/resolve-bin/blob/master/index.js\">index.js</a>\n<span>, </span>\n<a href=\"https://github.com/thlorenz/resolve-bin/blob/master/index.js#L6\">lineno 6</a>\n</li>\n</ul></dd>\n</dl>\n</dd>\n\n<dt>\n<h4 class=\"name\" id=\"resolveBin::sync\"><span class=\"type-signature\"></span>resolveBin::sync<span class=\"signature\">(name, <span class=\"optional\">opts</span>)</span><span class=\"type-signature\"> &rarr; {string}</span></h4>\n</dt>\n<dd>\n<div class=\"description\">\n<p>Synchronous version of resolveBin</p>\n</div>\n<h5>Parameters:</h5>\n<table class=\"params\">\n<thead>\n<tr>\n<th>Name</th>\n<th>Type</th>\n<th>Argument</th>\n<th class=\"last\">Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td class=\"name\"><code>name</code></td>\n<td class=\"type\">\n<span class=\"param-type\">string</span>\n</td>\n<td class=\"attributes\">\n</td>\n<td class=\"description last\"><p>module name, i.e. 'tap'</p></td>\n</tr>\n<tr>\n<td class=\"name\"><code>opts</code></td>\n<td class=\"type\">\n<span class=\"param-type\">Object</span>\n</td>\n<td class=\"attributes\">\n&lt;optional><br>\n</td>\n<td class=\"description last\"><p>options</p>\n<h6>Properties</h6>\n<table class=\"params\">\n<thead>\n<tr>\n<th>Name</th>\n<th>Type</th>\n<th class=\"last\">Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td class=\"name\"><code>executable</code></td>\n<td class=\"type\">\n<span class=\"param-type\">string</span>\n</td>\n<td class=\"description last\"><p>(default: @name) executable name (e.g. 'buster-test')</p></td>\n</tr>\n</tbody>\n</table>\n</td>\n</tr>\n</tbody>\n</table>\n<dl class=\"details\">\n<dt class=\"tag-source\">Source:</dt>\n<dd class=\"tag-source\"><ul class=\"dummy\">\n<li>\n<a href=\"https://github.com/thlorenz/resolve-bin/blob/master/index.js\">index.js</a>\n<span>, </span>\n<a href=\"https://github.com/thlorenz/resolve-bin/blob/master/index.js#L55\">lineno 55</a>\n</li>\n</ul></dd>\n</dl>\n</dd>\n\n</dl>\n</article>\n</section>\n</div>\n\n*generated with [docme](https://github.com/thlorenz/docme)*\n</div>\n<!-- END docme generated API please keep comment here to allow auto update -->\n\n## License\n\nMIT\n","publish_time":1400784803616,"_cnpm_publish_time":1400784803616,"dist-tags":{"latest":"1.0.1"}}