{"name":"isexe","version":"1.1.1","description":"Minimal module to check if a file is executable.","main":"index.js","directories":{"test":"test"},"devDependencies":{"mkdirp":"^0.5.1","rimraf":"^2.5.0","tap":"^5.1.2"},"scripts":{"test":"tap test/*.js --branches=100 --statements=100 --functions=100 --lines=100"},"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"license":"ISC","repository":{"type":"git","url":"git+https://github.com/isaacs/isexe.git"},"keywords":[],"bugs":{"url":"https://github.com/isaacs/isexe/issues"},"homepage":"https://github.com/isaacs/isexe#readme","gitHead":"af83031caed58654ad9d20b98eb710d383618ad7","_id":"isexe@1.1.1","_shasum":"f0d4793ed2fb5c46bfdeab760bbb965f4485a66c","_from":".","_npmVersion":"2.14.15","_nodeVersion":"4.0.0","_npmUser":{"name":"isaacs","email":"i@izs.me"},"dist":{"shasum":"f0d4793ed2fb5c46bfdeab760bbb965f4485a66c","tarball":"http://registry-npm.ywwl.com/isexe/download/isexe-1.1.1.tgz","integrity":"sha512-k1YjpQ5+RsFWJ5zY6wKt3ozCKse+HrkOZNg5BwkbB3xrlbKw42V0xZUUwUqGFNvUwW9oKIO4/ejxo83p4MWSgw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIE7gPPLpzYbXhErit3+XZ4N3zG4n5lNTe1GlR2E5PDGWAiEA8A0v0wJut6Eulwb4mex41aV3ZWj95TBTdJ18iQGgMgo="}],"size":3262,"noattachment":false,"key":"/isexe/-/isexe-1.1.1.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"readme":"# isexe\n\nMinimal module to check if a file is executable, and a normal file.\n\nUses `fs.stat` and tests against the `PATHEXT` environment variable on\nWindows.\n\n## USAGE\n\n```js\nimport { isexe, sync } from 'isexe'\n// or require() works too\n// const { isexe } = require('isexe')\nisexe('some-file-name').then(isExe => {\n  if (isExe) {\n    console.error('this thing can be run')\n  } else {\n    console.error('cannot be run')\n  }\n}, (err) => {\n  console.error('probably file doesnt exist or something')\n})\n\n// same thing but synchronous, throws errors\nisExe = sync('some-file-name')\n\n// treat errors as just \"not executable\"\nconst isExe = await isexe('maybe-missing-file', { ignoreErrors: true })\nconst isExe = sync('maybe-missing-file', { ignoreErrors: true })\n```\n\n## API\n\n### `isexe(path, [options]) => Promise<boolean>`\n\nCheck if the path is executable.\n\nWill raise whatever errors may be raised by `fs.stat`, unless\n`options.ignoreErrors` is set to true.\n\n### `sync(path, [options]) => boolean`\n\nSame as `isexe` but returns the value and throws any errors raised.\n\n## Platform Specific Implementations\n\nIf for some reason you want to use the implementation for a\nspecific platform, you can do that.\n\n```js\nimport { win32, posix } from 'isexe'\nwin32.isexe(...)\nwin32.sync(...)\n// etc\n\n// or:\nimport { isexe, sync } from 'isexe/posix'\n```\n\nThe default exported implementation will be chosen based on\n`process.platform`.\n\n### Options\n\n```ts\nimport type IsexeOptions from 'isexe'\n```\n\n* `ignoreErrors` Treat all errors as \"no, this is not\n  executable\", but don't raise them.\n* `uid` Number to use as the user id on posix\n* `gid` Number to use as the group id on posix\n* `pathExt` List of path extensions to use instead of `PATHEXT`\n  environment variable on Windows.\n","publish_time":1453773955873,"_cnpm_publish_time":1453773955873,"dist-tags":{"latest":"4.0.0"}}