{"_id":"file-exists","_rev":"255370","name":"file-exists","description":"Check if filepath exists and is a file","dist-tags":{"latest":"5.0.1"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"time":{"modified":"2021-06-03T16:21:05.000Z","created":"2014-07-17T23:30:52.010Z","5.0.1":"2018-01-02T21:37:09.514Z","5.0.0":"2017-09-27T11:52:38.662Z","4.0.0":"2017-06-01T15:38:14.223Z","3.0.2":"2017-03-08T13:01:11.561Z","3.0.1":"2017-02-07T15:02:47.577Z","3.0.0":"2017-02-07T14:56:30.957Z","2.0.0":"2016-08-02T13:32:07.006Z","1.0.0":"2015-11-20T18:37:10.008Z","0.1.1":"2014-07-18T22:29:22.762Z","0.1.0":"2014-07-17T23:30:52.010Z"},"users":{"maxrimue":true,"steve3d3d":true,"ronin161":true,"rocket0191":true,"sergiodxa":true,"kiinlam":true},"author":{"name":"Scott Corgan"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"versions":{"5.0.1":{"name":"file-exists","version":"5.0.1","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-format-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"engines":{"node":">=6.0.0"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"@tap-format/spec":"^0.2.0","async":"^2.1.4","mkdirp":"0.5.1","rmdir":"1.2.0","tape":"4.6.3"},"gitHead":"bd4b4a32d7a48792bb0fa37d61f10b13dd0cb42e","_id":"file-exists@5.0.1","_npmVersion":"5.5.1","_nodeVersion":"8.9.1","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"1dcd017f787fc7be7a09a6ef3e6a3550cea31198","size":7279,"noattachment":false,"key":"/file-exists/-/file-exists-5.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-5.0.1.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/file-exists-5.0.1.tgz_1514929028661_0.2489349499810487"},"publish_time":1514929029514,"_hasShrinkwrap":false,"_cnpm_publish_time":1514929029514},"5.0.0":{"name":"file-exists","version":"5.0.0","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-format-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"engines":{"node":">=6.0.0"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"@tap-format/spec":"^0.2.0","async":"^2.1.4","mkdirp":"0.5.1","rmdir":"1.2.0","tape":"4.6.3"},"gitHead":"bc52f382622f1f2c4c681fe73fd5e3dac0302bea","_id":"file-exists@5.0.0","_npmVersion":"5.4.2","_nodeVersion":"8.3.0","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"d8c21d5101312ac8a5600bd86f5420bf9a25b6ad","size":2023,"noattachment":false,"key":"/file-exists/-/file-exists-5.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-5.0.0.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/file-exists-5.0.0.tgz_1506513157702_0.7896219654940069"},"publish_time":1506513158662,"_cnpm_publish_time":1506513158662,"_hasShrinkwrap":false},"4.0.0":{"name":"file-exists","version":"4.0.0","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-format-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"engines":{"node":">=6.0.0"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"@tap-format/spec":"^0.2.0","async":"^2.1.4","mkdirp":"0.5.1","rmdir":"1.2.0","tape":"4.6.3"},"gitHead":"4cae403bbc3c532d121afd2bdedf64d711470f25","_id":"file-exists@4.0.0","_shasum":"104eacf25d3fd6b3e462951ae923533195ffb52b","_from":".","_npmVersion":"4.2.0","_nodeVersion":"7.10.0","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"104eacf25d3fd6b3e462951ae923533195ffb52b","size":2596,"noattachment":false,"key":"/file-exists/-/file-exists-4.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-4.0.0.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/file-exists-4.0.0.tgz_1496331493234_0.07535160169936717"},"publish_time":1496331494223,"_hasShrinkwrap":false,"_cnpm_publish_time":1496331494223},"3.0.2":{"name":"file-exists","version":"3.0.2","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-format-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"engines":{"node":">=6.0.0"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"@tap-format/spec":"^0.2.0","async":"^2.1.4","mkdirp":"0.5.1","rmdir":"1.2.0","tape":"4.6.3"},"gitHead":"d6b9b65971a27eacfd5bc93ffa7abcf56919d44a","_id":"file-exists@3.0.2","_shasum":"1d6b3c197810b43f85892e7eed478a637b1ab614","_from":".","_npmVersion":"4.3.0","_nodeVersion":"6.9.3","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"1d6b3c197810b43f85892e7eed478a637b1ab614","size":2537,"noattachment":false,"key":"/file-exists/-/file-exists-3.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-3.0.2.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/file-exists-3.0.2.tgz_1488978070836_0.7234392759855837"},"publish_time":1488978071561,"_cnpm_publish_time":1488978071561,"_hasShrinkwrap":false},"3.0.1":{"name":"file-exists","version":"3.0.1","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-format-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"engines":{"node":">=6.0.0"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"@tap-format/spec":"^0.2.0","async":"^2.1.4","mkdirp":"0.5.1","rmdir":"1.2.0","tape":"4.6.3"},"gitHead":"fa89c120c02e1e667fe447157882dbb423a88b9f","_id":"file-exists@3.0.1","_shasum":"aaf6cd50cd2370233252f4fcb48a1a521965b22e","_from":".","_npmVersion":"3.10.10","_nodeVersion":"6.9.3","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"aaf6cd50cd2370233252f4fcb48a1a521965b22e","size":2525,"noattachment":false,"key":"/file-exists/-/file-exists-3.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-3.0.1.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/file-exists-3.0.1.tgz_1486479765799_0.6760011021979153"},"publish_time":1486479767577,"_cnpm_publish_time":1486479767577,"_hasShrinkwrap":false},"3.0.0":{"name":"file-exists","version":"3.0.0","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-format-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"engines":{"node":">=6.0.0"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"@tap-format/spec":"^0.2.0","async":"^2.1.4","mkdirp":"0.5.1","rmdir":"1.2.0","tape":"4.6.3"},"gitHead":"135b04045b1596544e783660d6c855b3b0aed416","_id":"file-exists@3.0.0","_shasum":"db81c59080079adafe120f3669bf04bfd947debc","_from":".","_npmVersion":"3.10.10","_nodeVersion":"6.9.3","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"db81c59080079adafe120f3669bf04bfd947debc","size":2519,"noattachment":false,"key":"/file-exists/-/file-exists-3.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-3.0.0.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/file-exists-3.0.0.tgz_1486479390292_0.42030399153009057"},"publish_time":1486479390957,"_cnpm_publish_time":1486479390957,"_hasShrinkwrap":false},"2.0.0":{"name":"file-exists","version":"2.0.0","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"mkdirp":"^0.5.0","rmdir":"^1.0.4","tap-spec":"^4.1.0","tape":"^4.2.2"},"gitHead":"371df5917e6f9d9d23b1f81b4e6552bb5ac3b3d5","_id":"file-exists@2.0.0","_shasum":"a24150665150e62d55bc5449281d88d2b0810dca","_from":".","_npmVersion":"3.8.6","_nodeVersion":"6.1.0","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"a24150665150e62d55bc5449281d88d2b0810dca","size":2206,"noattachment":false,"key":"/file-exists/-/file-exists-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-2.0.0.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/file-exists-2.0.0.tgz_1470144724458_0.9976339789573103"},"publish_time":1470144727006,"_cnpm_publish_time":1470144727006,"_hasShrinkwrap":false},"1.0.0":{"name":"file-exists","version":"1.0.0","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-spec"},"repository":{"type":"git","url":"git+ssh://git@github.com/scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"mkdirp":"^0.5.0","rmdir":"^1.0.4","tap-spec":"^4.1.0","tape":"^4.2.2"},"gitHead":"2915cfcbd7f1ee872557be24a54d3ecc1f5e5d78","_id":"file-exists@1.0.0","_shasum":"e6d269b56567b8922581398e990dd7078f72d616","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.1.0","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"dist":{"shasum":"e6d269b56567b8922581398e990dd7078f72d616","size":2087,"noattachment":false,"key":"/file-exists/-/file-exists-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-1.0.0.tgz"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"publish_time":1448044630008,"_cnpm_publish_time":1448044630008,"_hasShrinkwrap":false},"0.1.1":{"name":"file-exists","version":"0.1.1","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-spec"},"repository":{"type":"git","url":"git@github.com:scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"mkdirp":"^0.5.0","rmdir":"^1.0.4","tap-spec":"^0.2.0","tape":"^2.13.3"},"gitHead":"82f0a2efbf2e634f0aef105fdd98f804a8cc7439","_id":"file-exists@0.1.1","_shasum":"993d3fffb5b49d11fefcc8f45c2355027440803c","_from":".","_npmVersion":"1.4.20","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"dist":{"shasum":"993d3fffb5b49d11fefcc8f45c2355027440803c","size":2101,"noattachment":false,"key":"/file-exists/-/file-exists-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-0.1.1.tgz"},"publish_time":1405722562762,"_cnpm_publish_time":1405722562762,"_hasShrinkwrap":false},"0.1.0":{"name":"file-exists","version":"0.1.0","description":"Check if filepath exists and is a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"node test/index.js | tap-spec"},"repository":{"type":"git","url":"git@github.com:scottcorgan/file-exists.git"},"keywords":["file","exists","fs","isfile","is-file"],"author":{"name":"Scott Corgan"},"license":"MIT","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"homepage":"https://github.com/scottcorgan/file-exists","devDependencies":{"mkdirp":"^0.5.0","rmdir":"^1.0.4","tap-spec":"^0.2.0","tape":"^2.13.3"},"gitHead":"803335602e25b077ce0b6dfac4aaae4bee6faee0","_id":"file-exists@0.1.0","_shasum":"658b244ecb73963102922dc01f7f722df0a68042","_from":".","_npmVersion":"1.4.20","_npmUser":{"name":"scottcorgan","email":"scottcorgan@gmail.com"},"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"}],"dist":{"shasum":"658b244ecb73963102922dc01f7f722df0a68042","size":2096,"noattachment":false,"key":"/file-exists/-/file-exists-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/file-exists/download/file-exists-0.1.0.tgz"},"publish_time":1405639852010,"_cnpm_publish_time":1405639852010,"_hasShrinkwrap":false}},"readme":"# file-exists\n\nCheck if filepath exists and is a file. Returns false for directories.\n\n_(Requires node >=6.0.0)_\n\n## Install\n\n```\nnpm install file-exists --save\n```\n\n## Usage\n\n```js\nconst fileExists = require('file-exists');\n\nfileExists('/index.html', (err, exists) => console.log(exists)) // OUTPUTS: true or false\n\nfileExists('/index.html').then(exists => {\n  console.log(exists) // OUTPUTS: true or false\n})\n\nconsole.log(fileExists.sync('/index.html')) // OUTPUTS: true or false\n```\n\n### Options\n\n#### fileExists(filepath[, options, callback])\n\n* `filepath` - the path to the file to check if it exists\n* `options` - an object of options\n  * `root` - the root directory to look in (or cwd)\n* `callback(err, exists)` - gets called when checking is done\n\n#### fileExists.sync(filepath[, options])\n* `filepath` - the path to the file to check if it exists\n* `options` - an object of options\n  * `root` - the root directory to look in (or cwd)\n\n## Run Tests\n\n```\nnpm install\nnpm test\n```\n","_attachments":{},"homepage":"https://github.com/scottcorgan/file-exists","bugs":{"url":"https://github.com/scottcorgan/file-exists/issues"},"license":"MIT"}