{"_id":"empty-dir","_rev":"22-3f84dc5183d92eec669bc5d635dae1d1","name":"empty-dir","description":"Check if a directory is empty.","dist-tags":{"latest":"3.0.0"},"versions":{"0.1.0":{"name":"empty-dir","description":"Check if a directory is empty.","version":"0.1.0","homepage":"https://github.com/tkellen/node-empty-dir","author":{"name":"Tyler Kellen","url":"http://goingslowly.com/"},"repository":{"type":"git","url":"git://github.com/tkellen/node-empty-dir.git"},"bugs":{"url":"https://github.com/tkellen/node-empty-dir/issues"},"licenses":[{"type":"MIT","url":"https://github.com/tkellen/node-empty-dir/blob/master/LICENSE"}],"main":"index.js","engines":{"node":">= 0.8.0"},"scripts":{"test":"mocha -R spec test"},"devDependencies":{"chai":"~1.9.1","mocha":"~1.18.2"},"keywords":["empty directory","empty dir","empty folder"],"_id":"empty-dir@0.1.0","dist":{"shasum":"4915bd8b63773c3f458b2dc50339c908849c84f0","tarball":"https://registry.npmjs.org/empty-dir/-/empty-dir-0.1.0.tgz","integrity":"sha512-EatTcJH5cVS/NXEpy7IWBSpH0WxvJdBnmRkz8Gqr2Jn4GmSqc4Q4E81SmVGOrHHHtCys1SsFKmAoHlhaFkRlmg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBiBLoJH1C0LPInd04qcA1ZBbHyUwmPQsAPpjiUJSOa9AiEA7t2kY6czxM2j67cA+i6MqmH4SRMYo0vygcoskyIGK/4="}]},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"tkellen","email":"tyler@sleekcode.net"},"maintainers":[{"name":"tkellen","email":"tyler@sleekcode.net"}],"directories":{}},"0.2.0":{"name":"empty-dir","description":"Check if a directory is empty.","version":"0.2.0","homepage":"https://github.com/tkellen/js-empty-dir","author":{"name":"Tyler Kellen","email":"http://goingslowly.com/"},"repository":{"type":"git","url":"git+https://github.com/tkellen/js-empty-dir.git"},"bugs":{"url":"https://github.com/tkellen/js-empty-dir/issues"},"license":"MIT","main":"index.js","files":["index.js"],"engines":{"node":">= 0.8.0"},"scripts":{"test":"mocha"},"dependencies":{"try-open":"^0.1.0"},"devDependencies":{"chai":"~1.9.1","mocha":"~1.18.2"},"keywords":["empty directory","empty dir","empty folder"],"gitHead":"153f3f0ded3dda3c7e2b9eaeeabd4b7a7a25dfda","_id":"empty-dir@0.2.0","_shasum":"265499aba875e9020c14baed46685b6920156d7f","_from":".","_npmVersion":"3.6.0","_nodeVersion":"4.2.6","_npmUser":{"name":"tkellen","email":"tyler@sleekcode.net"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"},{"name":"tkellen","email":"tyler@sleekcode.net"}],"dist":{"shasum":"265499aba875e9020c14baed46685b6920156d7f","tarball":"https://registry.npmjs.org/empty-dir/-/empty-dir-0.2.0.tgz","integrity":"sha512-hUjp/EsNXuz5rnqNfwvFWzJjmHaETP67HNYpFtNvXIV62sYWBLVqGvCsLAbQz8Ch71qqOngmj5cdtmRBvP7JAQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCsILchvjn6/K67oEv6pIqu6u/FC+6Ou0MWk9FtbJ/mwwIhAL7PqmCplk+fQYlLLsq0nDGFX29GMj7IhAliFh730BBn"}]},"_npmOperationalInternal":{"host":"packages-5-east.internal.npmjs.com","tmp":"tmp/empty-dir-0.2.0.tgz_1454870948426_0.9172745416872203"},"directories":{}},"0.2.1":{"name":"empty-dir","description":"Check if a directory is empty.","version":"0.2.1","homepage":"https://github.com/js-cli/js-empty-dir","author":{"name":"Tyler Kellen","email":"http://goingslowly.com/"},"repository":{"type":"git","url":"git+https://github.com/js-cli/js-empty-dir.git"},"bugs":{"url":"https://github.com/js-cli/js-empty-dir/issues"},"license":"MIT","main":"index.js","files":["index.js"],"engines":{"node":">= 0.8.0"},"scripts":{"test":"mocha"},"dependencies":{"fs-exists-sync":"^0.1.0"},"devDependencies":{"chai":"~1.9.1","mocha":"~1.18.2"},"keywords":["empty directory","empty dir","empty folder"],"gitHead":"76037e3785d6c5cce9e07ea1e77e55713ce5c52a","_id":"empty-dir@0.2.1","_shasum":"809ee48a1eb4ad1cb510c2572d66fd0ed84d01ab","_from":".","_npmVersion":"3.10.3","_nodeVersion":"6.3.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"},{"name":"tkellen","email":"tyler@sleekcode.net"}],"dist":{"shasum":"809ee48a1eb4ad1cb510c2572d66fd0ed84d01ab","tarball":"https://registry.npmjs.org/empty-dir/-/empty-dir-0.2.1.tgz","integrity":"sha512-0f1naHGJh4K6iVG28nRN7SCdfzT18OlpGzHmXw3JGwREb8qmtibHdmRgqx08u4sQfDadezK7kpU3bcIZNSwoZw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDGvWY8ISKea+SMPwIpmtGVq9nlPmPvV4PQ/SQ5Zkm9JQIgegSwyt5t8TcUUmcFHww+IW+0vQwElEDJ6SBRfvdwjBA="}]},"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/empty-dir-0.2.1.tgz_1469814745254_0.6127190270926803"},"directories":{}},"1.0.0":{"name":"empty-dir","description":"Check if a directory is empty.","version":"1.0.0","homepage":"https://github.com/js-cli/js-empty-dir","author":{"name":"Tyler Kellen","email":"http://goingslowly.com/"},"repository":{"type":"git","url":"git+https://github.com/js-cli/js-empty-dir.git"},"bugs":{"url":"https://github.com/js-cli/js-empty-dir/issues"},"license":"MIT","main":"index.js","files":["index.js"],"engines":{"node":">= 0.8.0"},"scripts":{"test":"mocha"},"keywords":["empty","is-empty","directory","folder"],"devDependencies":{"mocha":"^3.5.3"},"gitHead":"a9d270d986b183dc5389ddb43c8f8df03c0395da","_id":"empty-dir@1.0.0","_npmVersion":"5.7.1","_nodeVersion":"9.7.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"dist":{"integrity":"sha512-97qcDM6mUA1jAeX6cktw7akc5awIGA+VIkA5MygKOKA+c2Vseo/xwKN0JNJTUhZUtPwZboKVD2p1xu+sV/F4xA==","shasum":"be3ea41ca6798dc27bb9407f035888150e4c2995","tarball":"https://registry.npmjs.org/empty-dir/-/empty-dir-1.0.0.tgz","fileCount":4,"unpackedSize":5062,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIF0VNKCKFNGtWQ9S685EtE7TzuJacEnRHmILC9RhEyLfAiEA0/d+gENi+ZgHpMmydLxU6qGPeXeEgr1Hek7Ym7RFo88="}]},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"},{"name":"tkellen","email":"tyler@sleekcode.net"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/empty-dir_1.0.0_1520610532465_0.3523054457401449"},"_hasShrinkwrap":false},"2.0.0":{"name":"empty-dir","version":"2.0.0","description":"Check if a directory is empty.","author":{"name":"Gulp Team","email":"team@gulpjs.com","url":"http://gulpjs.com/"},"contributors":[{"name":"Tyler Kellen","email":"tyler@sleekcode.net"},{"name":"Jon Schlinkert","email":"jon.schlinkert@sellside.com"},{"name":"Blaine Bublitz","email":"blaine.bublitz@gmail.com"}],"repository":{"type":"git","url":"git+https://github.com/gulpjs/empty-dir.git"},"license":"MIT","engines":{"node":">= 4"},"main":"index.js","scripts":{"lint":"eslint .","pretest":"npm run lint","test":"mocha --async-only","cover":"istanbul cover _mocha --report lcovonly","coveralls":"npm run cover && istanbul-coveralls"},"dependencies":{},"devDependencies":{"eslint":"^2.13.0","eslint-config-gulp":"^3.0.1","expect":"^1.20.2","istanbul":"^0.4.3","istanbul-coveralls":"^1.0.3","mocha":"^3.5.3"},"keywords":["empty","is-empty","directory","folder","check"],"gitHead":"4817e656907fe58fcb3e4b41fde7363812a8f737","bugs":{"url":"https://github.com/gulpjs/empty-dir/issues"},"homepage":"https://github.com/gulpjs/empty-dir#readme","_id":"empty-dir@2.0.0","_npmVersion":"5.6.0","_nodeVersion":"8.11.1","_npmUser":{"name":"phated","email":"blaine.bublitz@gmail.com"},"dist":{"integrity":"sha512-XAedXlNAQZxMmbllXY9cxuESlNVjZ8xd67bSIUZwbS7VoLyhlNehVN3Iy35yDTGFHKR1opBRgORkp3am0so+WQ==","shasum":"c59b4e73b9909d3c4bd49c1fbdaea52031fe22ac","tarball":"https://registry.npmjs.org/empty-dir/-/empty-dir-2.0.0.tgz","fileCount":4,"unpackedSize":7405,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh2pqYCRA9TVsSAnZWagAAj+UP/AqdqDsmB4htCOs/UQzB\nyE1IApMkbeTcT0igFGy+GFRzlBq38GgTC6f0T310ZVFUNZkMndRNycSeMsKt\nWhvRXB5Y8WF+9eLD28mHm7jetNlnfl23onBcjRyBmoT+SyY4UU6kp4xiPiWN\n2mLvMn+Ipk0UN/AKsZJT0hVvbfUT1JNJfDuYHHAUTIchIBdsV3iBXv4ZA/a0\n9YRvZEpJIaaEfEsrhM4Jm2wFsQcOACrVxr6v+u0eBFb92as1/x+HRfB2u9sZ\n8UAMlN/y8myegUoHDtL4RSC+tVDFB2LMKCk7TIbkPzjhrhU2q5WHjKI8oZk9\n5uZbo3bk9CrJfDQBr80OejNpI9Ggoj2TTgeNtrOC7+vuj2vr8rI8fOFvQ+8M\nnRfG13fikNNsgdUlmssJ1GGMfqzmv+WejE39shAdze5kv08Tx96B1D51db0n\nPJYfeC5BXg4gClIoaC/92qohFqmHZXKQ9XQhIlr20x6iat4CcvUIX9oL2Lri\nRr3O75xbnTz6SVtFSI2+X2xLPx72NjUCtEfeT4hXGy0AByxdPcrMSoMgBKZJ\n6D6mjZ9VnVkJ7sY3H+JrDiXSC8Oj3SSbjlIxTjfxjrxN2nCB+Cfy3R2Jadol\nh9OLcd883YS7VmKvK7KxGdQbLOlPNXx0gXNMDZMk1hHHZUoDVsSG6qP7bFV0\nHawP\r\n=/U4p\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBPAO56tRqDxYKNqWU7pa1UDDF1kHvGUKhWeFqiiqzT7AiEA2Y3AYu6MfS0hpqSTCRd80Pwrrr7YC6TMnnbryZKpx/Y="}]},"maintainers":[{"email":"yo@contra.io","name":"contra"},{"email":"blaine.bublitz@gmail.com","name":"phated"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/empty-dir_2.0.0_1545437039831_0.1059495481944166"},"_hasShrinkwrap":false},"3.0.0":{"name":"empty-dir","version":"3.0.0","description":"Check if a directory is empty.","author":{"name":"Gulp Team","email":"team@gulpjs.com","url":"https://gulpjs.com/"},"contributors":[{"name":"Tyler Kellen","email":"tyler@sleekcode.net"},{"name":"Jon Schlinkert","email":"jon.schlinkert@sellside.com"},{"name":"Blaine Bublitz","email":"blaine.bublitz@gmail.com"}],"repository":{"type":"git","url":"git+https://github.com/gulpjs/empty-dir.git"},"license":"MIT","engines":{"node":">=10.13.0"},"main":"index.js","scripts":{"lint":"eslint .","pretest":"npm run lint","test":"nyc mocha --async-only"},"devDependencies":{"eslint":"^7.0.0","eslint-config-gulp":"^5.0.0","eslint-plugin-node":"^11.1.0","expect":"^27.0.0","mocha":"^8.0.0","nyc":"^15.0.0","sinon":"^12.0.1"},"nyc":{"reporter":["lcov","text-summary"]},"prettier":{"singleQuote":true},"keywords":["empty","is-empty","directory","folder","check"],"gitHead":"3963107ccef87db336ac83e15205dbc42d9486fd","bugs":{"url":"https://github.com/gulpjs/empty-dir/issues"},"homepage":"https://github.com/gulpjs/empty-dir#readme","_id":"empty-dir@3.0.0","_nodeVersion":"16.14.2","_npmVersion":"8.11.0","dist":{"integrity":"sha512-BVrc23tc2khY2AiAAaNsAlhSHBPdDU/gAMAYzA8QwBqqLpZ3PGedNNeatONxk4nYGuY852VlgSDrQxmjKHP/yw==","shasum":"abb2e5e26e197b40585b50aae3422d89a2304839","tarball":"https://registry.npmjs.org/empty-dir/-/empty-dir-3.0.0.tgz","fileCount":4,"unpackedSize":7214,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD1/aR9bXbbvvWCeupjcwWD9KgLfAmE2K/XM9rJcukKwwIhAMdUJWmha8u8AcYaV27zoHy5y4u/r0FHLI5zVU7WmT1i"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjCRR6ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmp9Ow//TowQB2/wxqdba/nEgZhg+8oLKhdGmJ2bvXjdMmN99az6Y4IH\r\nQskUSGnX4o5pG5/EC3WoFqZ6qWh0RVZ/j53QNV6AlMm6jV9PGHwA6d+E0EK9\r\nKITuKtuWkixINtCXxXnbesFdCfnfqVNtS9m/OS0+sQr60T99zr2Dh4vW2z72\r\nl3TbgcpXjOctwCpGfSHuVUpc4/PuaROSfzFnr56uLZbKUliahH6XAjnwFz5s\r\nAUxk5c2/RByROurThg2zJ6j9h1GbWAdZ7BbpR/UP5h32Gb5U3jd/PwOHrQ8o\r\nk3bidkQaeaPQqRl9+xkqwTb693daWnAXuuwwRZaL5aJUAFKvj4sjk+IlkSCs\r\n9GQEVcwXIRYYwQ/HzRWTBqnaSNWGfjq7duoP5tioPvnWH3bRF0DMHpExkp3d\r\nX/pfe1pGx28xMCibMMgmjC3Jw+PXPxZrms673k61pXgFpCebkEgA/cl8ug5Q\r\nfFYQTF2owq1dwamVqvndBpAb/PWb16YuZ7ZEDA54VJWxYTCZ5AfBEOuTnhFy\r\nc3IXTOGAHtZR38zfNeQYuwJOerabNxihYKGAEzkQcpP6Cu/SqzcyUgvDky+q\r\noJ7BI7i8oPzN8olt2OHo3flaAo9nAtagt4cuuaPywU9SVbxHeJg1lt7WKI4G\r\neV3YXdRcapifeX5AxWR69L9vv8lIkR0SvaA=\r\n=X/7L\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"phated","email":"blaine.bublitz@gmail.com"},"directories":{},"maintainers":[{"name":"yocontra","email":"yo@contra.io"},{"name":"phated","email":"blaine.bublitz@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/empty-dir_3.0.0_1661539450381_0.9792129422855214"},"_hasShrinkwrap":false}},"readme":"<p align=\"center\">\n  <a href=\"http://gulpjs.com\">\n    <img height=\"257\" width=\"114\" src=\"https://raw.githubusercontent.com/gulpjs/artwork/master/gulp-2x.png\">\n  </a>\n</p>\n\n# empty-dir\n\n[![NPM version][npm-image]][npm-url] [![Downloads][downloads-image]][npm-url] [![Build Status][ci-image]][ci-url] [![Coveralls Status][coveralls-image]][coveralls-url]\n\nCheck if a directory is empty.\n\n## Usage\n\n```js\nvar emptyDir = require('empty-dir');\n\n// Using an error-back\nemptyDir('./', function (err, result) {\n  if (err) {\n    console.error(err);\n  } else {\n    console.log('Directory is empty:', result);\n  }\n});\n\n// Using a Promise\nemptyDir('./').then(function (result) {\n  console.log('Directory is empty:', result);\n});\n\nvar result = emptyDir.sync('./test/empty');\nconsole.log('Directory is empty:', result);\n```\n\n## API\n\n### `emptyDir(paths, [filterFunction], [callback])`\n\nTakes a path string or array of path strings and returns a Promise. Checks if the given paths are empty and resolves with a boolean indicating if the paths are empty directories. Optionally takes a filter function to filter out files that cause false positives. Also, can take a node-style callback function instead of returning a Promise.\n\n### `emptyDir.sync(paths, [filterFunction])`\n\nSame as the above API but operates and returns synchronously. An error will be thrown.\n\n#### Filter function\n\nBoth async and sync take a filter function as the second argument, to ignore files like `.DS_Store` on mac or `Thumbs.db` on windows from causing false-negatives.\n\n```js\nvar emptyDir = require('empty-dir');\n\nfunction filter(filepath) {\n  return /(Thumbs\\.db|\\.DS_Store)$/i.test(filepath);\n}\n\nemptyDir('./', filter, function (err, isEmpty) {\n  if (err) {\n    console.error(err);\n  } else {\n    console.log('Directory is empty:', isEmpty);\n  }\n});\n\nvar isEmpty = emptyDir.sync('./test/empty', filter);\nconsole.log('Directory is empty:', isEmpty);\n```\n\n#### Promises\n\nGlobal promises are required for this module. If you are using a platform that doesn't have promise support, you'll need to polyfill Promise on the global.\n\n```js\nglobal.Promise = require('insert-your-promise-polyfill-here');\n\nvar emptyDir = require('empty-dir');\n\nemptyDir('./').then(function (result) {\n  console.log('Directory is empty:', result);\n});\n```\n\n## License\n\nMIT\n\n<!-- prettier-ignore-start -->\n[downloads-image]: https://img.shields.io/npm/dm/empty-dir.svg?style=flat-square\n[npm-url]: https://www.npmjs.com/package/empty-dir\n[npm-image]: https://img.shields.io/npm/v/empty-dir.svg?style=flat-square\n\n[ci-url]: https://github.com/gulpjs/empty-dir/actions?query=workflow:dev\n[ci-image]: https://img.shields.io/github/workflow/status/gulpjs/empty-dir/dev?style=flat-square\n\n[coveralls-url]: https://coveralls.io/r/gulpjs/empty-dir\n[coveralls-image]: https://img.shields.io/coveralls/gulpjs/empty-dir/master.svg?style=flat-square\n<!-- prettier-ignore-end -->\n","maintainers":[{"name":"yocontra","email":"yo@contra.io"},{"name":"phated","email":"blaine.bublitz@gmail.com"}],"time":{"modified":"2022-08-26T18:44:10.645Z","created":"2014-05-09T00:35:14.545Z","0.1.0":"2014-05-09T00:35:14.545Z","0.2.0":"2016-02-07T18:49:09.684Z","0.2.1":"2016-07-29T17:52:27.266Z","1.0.0":"2018-03-09T15:48:52.540Z","2.0.0":"2018-12-22T00:03:59.982Z","3.0.0":"2022-08-26T18:44:10.553Z"},"homepage":"https://github.com/gulpjs/empty-dir#readme","keywords":["empty","is-empty","directory","folder","check"],"repository":{"type":"git","url":"git+https://github.com/gulpjs/empty-dir.git"},"author":{"name":"Gulp Team","email":"team@gulpjs.com","url":"https://gulpjs.com/"},"bugs":{"url":"https://github.com/gulpjs/empty-dir/issues"},"readmeFilename":"README.md","users":{"afc163":true,"tmurngon":true},"license":"MIT","contributors":[{"name":"Tyler Kellen","email":"tyler@sleekcode.net"},{"name":"Jon Schlinkert","email":"jon.schlinkert@sellside.com"},{"name":"Blaine Bublitz","email":"blaine.bublitz@gmail.com"}]}