{"_id":"file-utils","_rev":"25-37fdd33bd7ebbeccf79416832baed31e","name":"file-utils","description":"Sync file utility for Node.js command line tools","dist-tags":{"latest":"0.2.2"},"versions":{"0.0.1":{"name":"file-utils","version":"0.0.1","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.1.0","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.6.4","grunt-contrib-nodeunit":"~0.2.0","grunt-release":"~0.3.3"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"_id":"file-utils@0.0.1","dist":{"shasum":"2585cafcc4cc30a89f4e9c72781a0307236930a5","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.0.1.tgz","integrity":"sha512-t9JG/M7uEs53rwT6QO4unCnd2o7c1PxW5/mgSOlwbo5XakZA7e6/k54e8rRc+lkMJS7KmkIaUKkr8g7vCDiyBg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD4ANvSsENbo5zG6NICdcag/cle1C9MyNqSo+JWvACpygIhAN1IA1rOBrcBcEPdzP+5IjcO20g16i3HiGjnyx6Q8RJJ"}]},"_from":".","_npmVersion":"1.3.8","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.1.0":{"name":"file-utils","version":"0.1.0","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.1.0","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.6.4","grunt-contrib-nodeunit":"~0.2.0","grunt-contrib-watch":"~0.5.3","grunt-release":"~0.3.3"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"_id":"file-utils@0.1.0","dist":{"shasum":"0141877d85bb2562639c7178b2e629f59d5a8eff","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.1.0.tgz","integrity":"sha512-gujci9NLqTqhD6mLU0mRle3u3GkLPNvaeAFVySVTWwx4Awds4GHDSAPDnbo/9yvu+DMj2GUlPrwVg08f7apmjQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGHRBgoHu4uedrOmnAyF2dSE3OI7bsf9yjXp3KukRcl5AiEA3FIfjtcSFHsbkE2O62Ud81v/v4pgOd5dB5kB9GCcGSY="}]},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.1.1":{"name":"file-utils","version":"0.1.1","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.1.0","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.6.4","grunt-contrib-nodeunit":"~0.2.0","grunt-contrib-watch":"~0.5.3","grunt-release":"~0.3.3"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"_id":"file-utils@0.1.1","dist":{"shasum":"61990c1aecda0c38c37dfdfaca018c4a99c0fc7e","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.1.1.tgz","integrity":"sha512-AaTpiF2jC1jT0AsoaXxz3wnE7y6aVkcCpD6N/MdfHxxVdOm5Bn/9YWhLPO3gGtkAd3SKwUwleX5q6f+1WDyF7Q==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQClBPH22PCFALtGBO0xu0Roe087BZ0rvINzQm7hqa0ukwIhAN4I8EKA2wnuxAGR8t29BQ0ZOofjyUcDEsbd5qpPu/qu"}]},"_from":".","_npmVersion":"1.3.8","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.1.2":{"name":"file-utils","version":"0.1.2","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.1.0","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.6.4","grunt-contrib-nodeunit":"~0.2.0","grunt-contrib-watch":"~0.5.3","grunt-release":"~0.3.3"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"_id":"file-utils@0.1.2","dist":{"shasum":"99673d8aaa0efd3884ea5649cffcfc7412808e41","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.1.2.tgz","integrity":"sha512-j3K/XCNmozSeEYzAz5EoKjypqoX7BlwM2wWDV6o1dN23ODteRVrW7Y/VTzTIqTB/hzgCAQJd9CK+GrNml+SEnA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBjgpeQ3sTW9eu5wnsgkUlYUFZbJqknXcwV7/QfhFX8UAiBBGOw41QZ9Dp3pxcuKFgKVpsWBp6lPx1YCKynJe8wkmQ=="}]},"_from":".","_npmVersion":"1.3.8","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.1.3":{"name":"file-utils","version":"0.1.3","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.1.0","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.6.4","grunt-contrib-nodeunit":"~0.2.0","grunt-contrib-watch":"~0.5.3","grunt-release":"~0.3.3"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"_id":"file-utils@0.1.3","dist":{"shasum":"83e3c95d53d1f1204f6e3a2ac933b8be4f8cdae6","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.1.3.tgz","integrity":"sha512-Ycin26JEgeCoeP3Q2KOi6NTg7AdbtdAixszLMtuwkSTC21fftQyXKwXa/WgacjwtcODsvgWQW6nb9RqtW4/P6w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFfwa72gh3MgoUf7XDnVKSHn52uQkjHU72+cz49bh/IpAiEA9Lar7+U+LBIf6xTuZH5gkzbNovy3c/a495zPkXe0nMQ="}]},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.1.4":{"name":"file-utils","version":"0.1.4","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.1.0","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2","isbinaryfile":"~0.1.9"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.6.4","grunt-contrib-nodeunit":"~0.2.0","grunt-contrib-watch":"~0.5.3","grunt-release":"~0.3.3"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"_id":"file-utils@0.1.4","dist":{"shasum":"9ecc8f7e6945a28ee0e23cefa423a8368dd099cd","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.1.4.tgz","integrity":"sha512-9jc/MA7QdDVm7YTV/kNuC7ep07VVWSdgwyU71lkA5NHQyriKxWwXVgINLCFVUOkPY4WzyRvcq9YZp7RRa/9GZg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD+dex+HvXsdSg4mVytUZ+Hw93AJ5GXNB5bHXxHOUpJvgIgUnjLZYakggLdC1/kOHqriYaghn/j2BKimD39jeYSnUs="}]},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.1.5":{"name":"file-utils","version":"0.1.5","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.1.0","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2","isbinaryfile":"~0.1.9"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.6.4","grunt-contrib-nodeunit":"~0.2.0","grunt-contrib-watch":"~0.5.3","grunt-release":"~0.3.3"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"_id":"file-utils@0.1.5","dist":{"shasum":"dc8153c855387cb4dacb0a1725531fa444a6b48c","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.1.5.tgz","integrity":"sha512-DFNaKyVV63vP3KB2KDks91O1k46DfguUMv9mtGRzomzPVeB7k41u2aKrD8U4Kcg1UnCXLIZ+VYA3Bb3PjcnWeg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGZPZqYsvSWFdwHSI4pMS5EtEHg2JPZVjgwzcdKVBog1AiEAn++J8dL8q8mhNydpyYucXflKhAvkKLPgEmyfdfDBHeI="}]},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.2.0":{"name":"file-utils","version":"0.2.0","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"lodash":"~2.4.1","iconv-lite":"~0.2.11","rimraf":"~2.2.2","glob":"~3.2.6","minimatch":"~0.2.12","findup-sync":"~0.1.2","isbinaryfile":"~2.0.0"},"devDependencies":{"temporary":"~0.0.4","grunt-contrib-jshint":"~0.8.0","grunt-contrib-nodeunit":"~0.2.0","grunt-contrib-watch":"~0.5.3","grunt-release":"~0.6.0"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"engines":{"node":">=0.10.0"},"_id":"file-utils@0.2.0","dist":{"shasum":"0372c89b19bd96fc9a02a180c91fad29e4dbacaa","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.2.0.tgz","integrity":"sha512-5/TPOcg1dP34T40gTaJxLpq4cDIfUqPo5dhRt3/aa8otA0O0ccdN0q5rkNdp6kXkMifZdUmhxNVSDQIoJhKfvg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDKpNB/8dVpAfJUoYsVnEorg+QAZGvcgUmgK2n1IVy71wIhAI81CY3lzNm7SPJ1VhrPzCqPq2uZcOVJxftQd22TPkz6"}]},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}]},"0.2.1":{"name":"file-utils","version":"0.2.1","description":"Sync file utility for Node.js command line tools","main":"index.js","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"findup-sync":"~0.1.2","glob":"~3.2.6","iconv-lite":"~0.4.3","isbinaryfile":"~2.0.1","lodash":"~2.4.1","minimatch":"~0.2.12","rimraf":"~2.2.2"},"devDependencies":{"grunt":"^0.4.5","grunt-cli":"^0.1.13","grunt-contrib-jshint":"^0.10.0","grunt-contrib-nodeunit":"^0.4.1","grunt-contrib-watch":"^0.6.1","grunt-release":"^0.7.0","temporary":"~0.0.4"},"repository":{"type":"git","url":"git://github.com/SBoudrias/file-utils.git"},"keywords":["file","utils","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"engines":{"node":">=0.10.0"},"homepage":"https://github.com/SBoudrias/file-utils","_id":"file-utils@0.2.1","_shasum":"4978d430f2ecc0c93f262c266c106de9e007a871","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}],"dist":{"shasum":"4978d430f2ecc0c93f262c266c106de9e007a871","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.2.1.tgz","integrity":"sha512-VnvQi7z9n1nOSyM/4zQeeHb43hhS+Hy9fOa8w1GcZ3OIh4Rg+1OgW0vHyINEVoYlAz7xFejkwMy0k/Ztw4rtVw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCID7+pXuPJFIebxlC2XcX6gHRo8KB0FPAv2C/jlS8GShwAiAIS379gexPm5jAy2cKrU9qeY5xmFSUOEjg4lGEefAEQg=="}]}},"0.2.2":{"name":"file-utils","version":"0.2.2","description":"Sync file utility for Node.js command line tools","directories":{"test":"tests"},"scripts":{"test":"grunt test"},"license":"MIT","dependencies":{"findup-sync":"^0.2.1","glob":"^4.3.5","iconv-lite":"^0.4.3","isbinaryfile":"^2.0.1","lodash":"^2.4.1","minimatch":"^2.0.1","rimraf":"^2.2.2"},"devDependencies":{"grunt":"^0.4.5","grunt-cli":"^0.1.13","grunt-contrib-jshint":"^0.10.0","grunt-contrib-nodeunit":"^0.4.1","grunt-contrib-watch":"^0.6.1","grunt-release":"^0.10.0","temporary":"0.0.8"},"repository":{"type":"git","url":"https://github.com/SBoudrias/file-utils"},"keywords":["file","fs","utils","util","scaffold","tool","cli"],"author":{"name":"Simon Boudrias"},"engines":{"node":">=0.10.0"},"files":["lib","index.js"],"gitHead":"9e59b23f7394f6d875e1cb4843b43efcd391ef7b","bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"homepage":"https://github.com/SBoudrias/file-utils","_id":"file-utils@0.2.2","_shasum":"4b7967bb2079ada4d4a7f5454206ecb5c0d4c589","_from":".","_npmVersion":"2.4.1","_nodeVersion":"0.10.32","_npmUser":{"name":"sboudrias","email":"admin@simonboudrias.com"},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}],"dist":{"shasum":"4b7967bb2079ada4d4a7f5454206ecb5c0d4c589","tarball":"https://registry.npmjs.org/file-utils/-/file-utils-0.2.2.tgz","integrity":"sha512-J8uMrEBvJLD1f5p0XyuiR2XqUIc1bxBdAnBWcrBzrEIydhjWrHICpvdJmlpvz2AbijANANuUnC4/Q+B1wKpYNQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDGU6FGFE2vcdXB+jBKOgqOZClpvEI1slId6EbUm89vOgIhANoCjONnZ3zq3KXU+6Ayd6F/sQL1IGoBx+nBY86IaTAe"}]}}},"readme":"file-utils [![](https://travis-ci.org/SBoudrias/file-utils.png)](https://travis-ci.org/SBoudrias/file-utils)\n==========\n\nThis is a Grunt.file forks to allow the creation of scoped file utilities and the ability to add write filters.\n\nSame as Grunt.file, this is a set of _synchronous_ utility. As so, it should **never** be used on a Node.js server. This is meant for users/command line utilities.\n\n\nFile API\n=========\n\nUpcoming. Meanwhile, check [Grunt.file documentation](http://gruntjs.com/api/grunt.file) as the same methods are available.\n\n#### Setting options - `file.option( name, [ value ])`\n\n```\n// Set option\nfile.option('write', false);\n\n// Get option\nfile.option('write');\n```\n\n**Available Options**\n- `write` (Boolean): If write is set to `false`, then no file will be written or deleted. Useful for test run without side effets.\n- `logger` (Logger object): Used internally to log information to the console. **API still work in progress**\n- `encoding` (String): Defaults `utf8`. Set the default encoding used for reading/writing. Note most methods allow you to overwridde it for a single run.\n- `force` (Boolean): `force: true` Force the deletion of folders and file outside the utility scope (or CWD if no scope).\n\n\nENV scope and filters\n=========\n\n### Creating an Env - file#createEnv([ options ]);\n\n```javascript\nvar file = require('file-utils');\n\nvar env = file.createEnv({\n  base: 'my/scoped/path',\n  dest: 'destination/path' // optionnal\n});\n\n// Alternatively, they can be functions returning a path:\n\nvar env = file.createEnv({\n  base: function() {\n    return 'my/scoped/path';\n  },\n  dest: function() { // optionnal\n    return 'destination/path';\n  }\n});\n```\n\nThe `base` directory will prefix any paths passed to `mkdir`, `recurse`, `read`, `readJSON`, `write`, `delete`, `exists`, `isLink`, `isDir` and `isFile` methods.\n\nThe `dest` directory will prefix the `destination` path provided in the `copy` method. Note that this option is optionnal and will default to the current working directory.\n\nIf [options (`logger`, `write`, etc)](#setting-options---fileoption-name--value-) are not passed, each `Env` instance inherit those of its parent.\n\nWrite Filters\n---------\n\nWrite filters are applied on `env.write` and `env.copy`.\n\nThey're used to modifiy the content or the filepath of a file.\n\n#### Add a write filter - `env.registerWriteFilter( name, filter )`\n\n**options**\n- `name` (String): The name under which registering the filter\n- `filter` (Function): The filter function\n\nThe filter function take a file object as parameter. This file object is a hash containing a `path` and a `contents` property. You can modify these two property as you like and returning the modified object.\n\n```javascript\nenv.registerWriteFilter( 'coffee', function( file ) {\n  if (!path.extname(file) !== '.js') return file;\n\n  file.path = file.path.replace(/(\\.js)$/, '.coffee');\n  file.content = convertJsToCoffee( file.contents );\n\n  return file;\n});\n```\n\n#### Remove a write filter - `env.removeWriteFilter( name )`\n\n```javascript\nenv.removeWriteFilter('coffee');\n```\n\n#### Async filter\n\nThe filter can also be asynchronous. This is done by calling `this.async()` and passing the return value to the callback provided.\n\n```javascript\nenv.registerWriteFilter( 'coffee', function( file ) {\n  var done = this.async();\n\n  // some process\n  setTimeout(function() {\n    done({ path: '/newfile', contents: 'filtered content' });\n  }, 1000);\n});\n```\n\n**Caution:** Using an asynchronous filter will change the way write and copy method are called to. This will make both of those method to run asynchronously too.\n\nValidation Filters\n----------\n\nValidation filters are applied on `env.write` and `env.copy`.\n\nThey're used to allow or disallow the write action.\n\n#### Add a validation filter - `env.registerValidationFilter( name, filter )`\n\n**options**\n- `name` (String): The name under which registering the filter\n- `filter` (Function): The filter function\n\nThe filter function take a file object as parameter. This file object is a hash containing a `path` (String) and a `contents` (String if text file, Buffer otherwise) property.\n\nReturn `true` to allow the file to be written. Return `false` or an error message `String` to disallow the write action.\n\n```javascript\nenv.registerValidationFilter( 'checkConflicts', function( toOutput ) {\n  if ( file.exists(toOutput.path) ) {\n    return 'file is already present';\n  }\n  return true;\n});\n```\n\nJust like the write filters, [this filter can be asynchronous](#async-filter).\n\n#### Remove a validation filter - `env.removeValidationFilter( name )`\n\n```javascript\nenv.removeValidationFilter('checkConflicts');\n```\n\n\nTodos\n=========\n\n- Real Logging system\n","maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"}],"time":{"modified":"2022-06-18T00:40:34.094Z","created":"2013-10-05T19:04:54.975Z","0.0.1":"2013-10-05T19:04:56.526Z","0.1.0":"2013-10-16T00:24:38.031Z","0.1.1":"2013-10-20T00:20:12.916Z","0.1.2":"2013-10-21T01:40:48.358Z","0.1.3":"2013-11-14T22:52:18.929Z","0.1.4":"2013-11-15T20:36:40.900Z","0.1.5":"2013-11-18T19:02:21.807Z","0.2.0":"2014-01-16T21:57:57.104Z","0.2.1":"2014-08-26T06:23:34.768Z","0.2.2":"2015-02-06T08:12:23.354Z"},"author":{"name":"Simon Boudrias"},"repository":{"type":"git","url":"https://github.com/SBoudrias/file-utils"},"readmeFilename":"README.md","homepage":"https://github.com/SBoudrias/file-utils","keywords":["file","fs","utils","util","scaffold","tool","cli"],"bugs":{"url":"https://github.com/SBoudrias/file-utils/issues"},"license":"MIT","users":{"itonyyo":true}}