{"name":"fsevents","version":"2.0.2-pre-1","description":"Native Access to Mac OS-X FSEvents","main":"fsevents.js","os":["darwin"],"engines":{"node":"^10.6.0 || >=11.0.0"},"scripts":{"clean":"node-gyp clean && rm -f fsevents.node","install":"[ -f fsevents.node ] || npm run prepare","test":"/bin/bash ./test.sh 2>/dev/null","prepare":"node-gyp rebuild && node-gyp clean"},"repository":{"type":"git","url":"git+https://github.com/strongloop/fsevents.git"},"keywords":["fsevents","mac"],"contributors":[{"name":"Philipp Dunkel","email":"pip@pipobscure.com"},{"name":"Ben Noordhuis","email":"info@bnoordhuis.nl"},{"name":"Elan Shankar","email":"elan.shanker@gmail.com"},{"name":"Miroslav Bajtoš","email":"mbajtoss@gmail.com"}],"license":"MIT","bugs":{"url":"https://github.com/strongloop/fsevents/issues"},"homepage":"https://github.com/strongloop/fsevents","devDependencies":{},"readme":"# fsevents [![NPM](https://nodei.co/npm/fsevents.png)](https://nodei.co/npm/fsevents/)\n\nNative access to OS X FSEvents in [Node.js](http://nodejs.org/)\n\nThe FSEvents API in OS X allows applications to register for notifications of\nchanges to a given directory tree. It is a very fast and lightweight alternative\nto kqueue.\n\nThis is a low-level library. For a cross-compatible file watching module that\nuses fsevents, check out [Chokidar](https://www.npmjs.com/package/chokidar).\n\n* [Module Site & GitHub](https://github.com/strongloop/fsevents)\n* [NPM Page](https://npmjs.org/package/fsevents)\n\n## Installation\n\n\t$ npm install fsevents\n\n## Usage\n\n```js\nconst fsevents = require('fsevents');\nlet stop = fsevents.watch(__dirname, (path, flags, id)=>{\n  const info = fsevents.getInfo(path, flags, id);\n}); // To start observation\nstop(); // To end observation\n```\n\n### Callback\n\nThe callback passed as the second parameter to `.watch` get's called whenever the operating system detects a\na change in the file system. It takes three arguments:\n\n * `path` - which is a string naming the path of the item in the filesystem that changed\n * `flags` - a numeric value describing what the change was\n * `id` - a unique-id identifying this specific event\n\n### `getInfo(path, flags, id) => {info-object}`\n\nThe `getInfo` function takes the `path`, `flags` and `id` arguments and converts those parameters into a structure\nthat is easier to digest to determine what the change was.\n\nThe `info-object` has the following shape:\n\n```js\n{\n  \"event\": \"<deleted|moved|created|modified|root-changed|unknown>\",\n  \"path\": \"<path-that-this-is-about>\",\n  \"type\": \"<file|directory|symlink>\",\n  \"changes\": {\n    \"inode\": true, // Has the iNode Meta-Information changed\n    \"finder\": false, // Has the Finder Meta-Data changed\n    \"access\": false, // Have the access permissions changed\n    \"xattrs\": false // Have the xAttributes changed\n  },\n  \"flags\": <raw-flags>\n}\n```\n\n## MIT License\n\nCopyright (C) 2010-2018 by Philipp Dunkel, Ben Noordhuis, Elan Shankar\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.\n","readmeFilename":"Readme.md","gitHead":"b47d7926a1f9f71267b2b0e293e70151b1ce0e57","_id":"fsevents@2.0.2-pre-1","_npmVersion":"6.4.1","_nodeVersion":"11.0.0","_npmUser":{"name":"pipobscure","email":"pip@pipobscure.com"},"dist":{"integrity":"sha512-rcrAK4uZLlxZLgz+s8nJtLOlpgM3gsDvOTM5mjLbaSUZmiR75JCxdeqNB8NnekRMl+0sAXWShKQGHKIkyYzY7g==","shasum":"edcd17077801eb2df0e8d15f85d0c9147e48434b","tarball":"http://registry-npm.ywwl.com/fsevents/download/fsevents-2.0.2-pre-1.tgz","fileCount":19,"unpackedSize":59344,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcJ1MACRA9TVsSAnZWagAAHOAP/j02R1b5DjHVWCAbCIzz\nApwoLmiT0OoyRbe4m2ohwaGrCgHQmaKjj6VH2PQsxwXkHGH0YbuyAESzCCIq\n/+thlNdauVpU6xrisYifkHKlFXP69dg5BVWaAeIOCdOqN86rFcx+HF4Psrzo\nBWoSI5xV/1F1UNcnt3wvZcpZc/rPlSVy2fyoXYOF02AljwCRIdVTACLqVyps\nK8ivkYjCyxUiwYOSmC5CGZylfWgCyVGVMEobJNkNXpH9z7i2kGov7rQ9XnvY\nRarb+tKuTzAY9xaNXcgbe+N3EVRbSHphwpEv1L+6RFS8kvWjNAXkKun66JTM\niWDLVm2yMvCZUhwHYSwkEK0I998WV7KUpQGKD8uCzr76YCV+yXMCzDRWtL+z\nXhG+junO37oRtZp1wFIdmJD9z/jw7RkOmPFI7y3Gg1kWw0XtsuOCtHGDoBTk\nqb67RlEEic3C1uNc1mqxXa8jlEqScuV3hGcmKdC/M5uQzQccrH4tHfluuFFJ\nwf4rS/DwPaIqelx88FPsYms3Ny0FBRpHQC+U8B3CPtiV4Y9gMZzSyouL6TPr\n/KfZeSvLIFGofhywsFHcSf2ceJLdFYF/RHPF9jSicq2eNRHV08rIUxYZxAv4\n8jXhZm3S4n4wAUa6I8xOfXoDfpdWr3z2IqGQOnyjh48iZtUMd9W56JlYCJZr\nfVg8\r\n=hnQb\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCscstz2JS/Aibw0FmeONJDqUdHT5teJH8c7TahQilkcgIhAKujP5j3bRA04KRfacaGgqQf13ZkDyQ8nhdSt/3cDKZO"}],"size":16011,"noattachment":false,"key":"/fsevents/-/fsevents-2.0.2-pre-1.tgz"},"maintainers":[{"email":"mbajtoss@gmail.com","name":"bajtos"},{"email":"info@bnoordhuis.nl","name":"bnoordhuis"},{"email":"elan.shanker+npm@gmail.com","name":"es128"},{"email":"pip@pipobscure.com","name":"pipobscure"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/fsevents_2.0.2-pre-1_1546081023950_0.5562314985010346"},"_hasShrinkwrap":false,"publish_time":1546081024076,"_cnpm_publish_time":1546081024076,"dist-tags":{"latest":"2.3.3","nan":"1.2.13"}}