{"_id":"to-file","_rev":"82621","name":"to-file","description":"Convert a file path to a vinyl file.","dist-tags":{"latest":"0.2.0"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"time":{"modified":"2021-06-03T10:26:20.000Z","created":"2015-10-09T06:06:09.628Z","0.2.0":"2016-05-07T18:02:50.445Z","0.1.7":"2016-02-13T01:09:25.072Z","0.1.5":"2015-10-22T21:46:17.094Z","0.1.4":"2015-10-16T15:20:52.641Z","0.1.3":"2015-10-14T08:20:21.529Z","0.1.2":"2015-10-09T06:19:50.103Z","0.1.1":"2015-10-09T06:09:28.388Z","0.1.0":"2015-10-09T06:06:09.628Z"},"users":{},"author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"versions":{"0.2.0":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.2.0","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js","utils.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","extend-shallow":"^2.0.1","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","isobject":"^2.1.0","lazy-cache":"^2.0.1","vinyl":"^1.1.1"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-eslint":"^1.1.1","gulp-format-md":"^0.1.9","gulp-istanbul":"^0.10.1","gulp-mocha":"^2.1.3","mocha":"^2.4.5"},"keywords":["contents","file","read","vinyl"],"verb":{"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"related":{"list":["to-template","to-vinyl"]},"lint":{"reflinks":true},"reflinks":["glob-parent","verb"]},"gitHead":"43b4444a418efa1304ebf01044a5dd9711dd813e","_id":"to-file@0.2.0","_shasum":"236c6c088065e570defbd15cf4b4e565be46ea93","_from":".","_npmVersion":"3.6.0","_nodeVersion":"5.5.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"236c6c088065e570defbd15cf4b4e565be46ea93","size":3204,"noattachment":false,"key":"/to-file/-/to-file-0.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.2.0.tgz"},"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/to-file-0.2.0.tgz_1462644169467_0.5734325663652271"},"directories":{},"publish_time":1462644170445,"_cnpm_publish_time":1462644170445,"_hasShrinkwrap":false},"0.1.7":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.1.7","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js","utils.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","extend-shallow":"^2.0.1","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","isobject":"^2.0.0","lazy-cache":"^1.0.3","vinyl":"^1.1.1"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-eslint":"^1.1.1","gulp-format-md":"^0.1.5","gulp-istanbul":"^0.10.1","gulp-mocha":"^2.1.3","mocha":"*"},"keywords":["contents","file","read","vinyl"],"verb":{"tasks":["readme"],"plugins":["gulp-format-md"],"related":{"list":["to-template","to-vinyl"]}},"gitHead":"80810bf3590140f79baa7a0d30293f866987bd53","_id":"to-file@0.1.7","_shasum":"d492ec9d76f06a2551774218dbd0d739437d9bb6","_from":".","_npmVersion":"3.6.0","_nodeVersion":"5.5.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"d492ec9d76f06a2551774218dbd0d739437d9bb6","size":3008,"noattachment":false,"key":"/to-file/-/to-file-0.1.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.1.7.tgz"},"_npmOperationalInternal":{"host":"packages-6-west.internal.npmjs.com","tmp":"tmp/to-file-0.1.7.tgz_1455325761623_0.09141983138397336"},"directories":{},"publish_time":1455325765072,"_cnpm_publish_time":1455325765072,"_hasShrinkwrap":false},"0.1.5":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.1.5","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js","utils.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","extend-shallow":"^2.0.1","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","lazy-cache":"^0.2.3","vinyl":"^1.0.0"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-istanbul":"^0.10.1","gulp-jshint":"^1.11.2","gulp-mocha":"^2.1.3","jshint-stylish":"^2.0.1","mocha":"*"},"keywords":["contents","file","read","vinyl"],"verb":{"related":{"list":["to-vinyl","to-template"]}},"gitHead":"178cade8812a75d5e3fb70577f215d878e44e7c2","_id":"to-file@0.1.5","_shasum":"0dfd033202e0c9a3062844843486f1d44a07776e","_from":".","_npmVersion":"2.14.7","_nodeVersion":"4.2.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"0dfd033202e0c9a3062844843486f1d44a07776e","size":2825,"noattachment":false,"key":"/to-file/-/to-file-0.1.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.1.5.tgz"},"directories":{},"publish_time":1445550377094,"_cnpm_publish_time":1445550377094,"_hasShrinkwrap":false},"0.1.4":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.1.4","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js","utils.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","lazy-cache":"^0.2.3","vinyl":"^1.0.0"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-istanbul":"^0.10.1","gulp-jshint":"^1.11.2","gulp-mocha":"^2.1.3","jshint-stylish":"^2.0.1","mocha":"*"},"keywords":[],"verb":{"related":{"list":["to-vinyl","to-template"]}},"gitHead":"8bdba888dbaf088425d64b45253eda8bd29c47a9","_id":"to-file@0.1.4","_shasum":"478a4c127fa6f1d23bbe8e0fa269bf00d6f9ee2b","_from":".","_npmVersion":"2.14.4","_nodeVersion":"4.1.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"478a4c127fa6f1d23bbe8e0fa269bf00d6f9ee2b","size":2782,"noattachment":false,"key":"/to-file/-/to-file-0.1.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.1.4.tgz"},"directories":{},"publish_time":1445008852641,"_cnpm_publish_time":1445008852641,"_hasShrinkwrap":false},"0.1.3":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.1.3","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js","utils.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","lazy-cache":"^0.2.3","vinyl":"^1.0.0"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-istanbul":"^0.10.1","gulp-jshint":"^1.11.2","gulp-mocha":"^2.1.3","jshint-stylish":"^2.0.1","mocha":"*"},"keywords":[],"verb":{"related":{"list":["to-vinyl","to-template"]}},"gitHead":"b039531c1786a444c9aee1b6a99be043a1377460","_id":"to-file@0.1.3","_shasum":"8a7c9f171d38f2c58e8066bd3b47a53885c46a2a","_from":".","_npmVersion":"2.14.4","_nodeVersion":"4.1.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"8a7c9f171d38f2c58e8066bd3b47a53885c46a2a","size":2783,"noattachment":false,"key":"/to-file/-/to-file-0.1.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.1.3.tgz"},"directories":{},"publish_time":1444810821529,"_cnpm_publish_time":1444810821529,"_hasShrinkwrap":false},"0.1.2":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.1.2","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js","utils.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","lazy-cache":"^0.2.3","vinyl":"^1.0.0"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-istanbul":"^0.10.1","gulp-jshint":"^1.11.2","gulp-mocha":"^2.1.3","jshint-stylish":"^2.0.1","mocha":"*"},"keywords":[],"verb":{"related":{"list":["to-vinyl","to-template"]}},"gitHead":"b039531c1786a444c9aee1b6a99be043a1377460","_id":"to-file@0.1.2","_shasum":"38e355a1fd3dfe88fd880254ebf9990f3b1ec2f2","_from":".","_npmVersion":"2.14.4","_nodeVersion":"4.1.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"38e355a1fd3dfe88fd880254ebf9990f3b1ec2f2","size":2768,"noattachment":false,"key":"/to-file/-/to-file-0.1.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.1.2.tgz"},"directories":{},"publish_time":1444371590103,"_cnpm_publish_time":1444371590103,"_hasShrinkwrap":false},"0.1.1":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.1.1","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js","utils.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","lazy-cache":"^0.2.3","vinyl":"^1.0.0"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-istanbul":"^0.10.1","gulp-jshint":"^1.11.2","gulp-mocha":"^2.1.3","jshint-stylish":"^2.0.1","mocha":"*"},"keywords":[],"verb":{"related":{"list":["to-vinyl","to-template"]}},"gitHead":"b039531c1786a444c9aee1b6a99be043a1377460","_id":"to-file@0.1.1","_shasum":"5974a48e0ea9c4a1d92fe63c8d11a2e84938dc71","_from":".","_npmVersion":"2.14.4","_nodeVersion":"4.1.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"5974a48e0ea9c4a1d92fe63c8d11a2e84938dc71","size":2743,"noattachment":false,"key":"/to-file/-/to-file-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.1.1.tgz"},"directories":{},"publish_time":1444370968388,"_cnpm_publish_time":1444370968388,"_hasShrinkwrap":false},"0.1.0":{"name":"to-file","description":"Convert a file path to a vinyl file.","version":"0.1.0","homepage":"https://github.com/jonschlinkert/to-file","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/to-file.git"},"bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"define-property":"^0.2.5","file-contents":"^0.2.4","glob-parent":"^2.0.0","is-valid-glob":"^0.3.0","lazy-cache":"^0.2.3","vinyl":"^1.0.0"},"devDependencies":{"glob":"^5.0.15","gulp":"^3.9.0","gulp-istanbul":"^0.10.1","gulp-jshint":"^1.11.2","gulp-mocha":"^2.1.3","jshint-stylish":"^2.0.1","mocha":"*"},"keywords":[],"verb":{"related":{"list":["to-vinyl","to-template"]}},"_id":"to-file@0.1.0","_shasum":"0990b832567c2f49fd9d0132292c5e79db39b10e","_from":".","_npmVersion":"2.14.4","_nodeVersion":"4.1.1","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"0990b832567c2f49fd9d0132292c5e79db39b10e","size":2485,"noattachment":false,"key":"/to-file/-/to-file-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/to-file/download/to-file-0.1.0.tgz"},"directories":{},"publish_time":1444370769628,"_cnpm_publish_time":1444370769628,"_hasShrinkwrap":false}},"readme":"# to-file [![NPM version](https://img.shields.io/npm/v/to-file.svg?style=flat)](https://www.npmjs.com/package/to-file) [![NPM downloads](https://img.shields.io/npm/dm/to-file.svg?style=flat)](https://npmjs.org/package/to-file) [![Build Status](https://img.shields.io/travis/jonschlinkert/to-file.svg?style=flat)](https://travis-ci.org/jonschlinkert/to-file)\n\nConvert a file path to a vinyl file.\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/):\n\n```sh\n$ npm install to-file --save\n```\n\n## Usage\n\n```js\nvar toFile = require('to-file');\nvar glob = require('glob');\n\nvar files = glob.sync('**/*.js')\nfiles = files.map(function(fp) {\n  return toFile(fp);\n});\n```\n\n**glob parent**\n\nOptionally pass the original glob pattern as the second argument to populate `file.base` from the [glob-parent](https://github.com/es128/glob-parent).\n\n```js\nvar files = glob.sync('**/*.js')\nfiles = files.map(function(fp) {\n  return toFile(fp, '**/*.js');\n});\n```\n\n**options**\n\nIf an options object is passed as the second or third argument, the `cwd` and `base` properties will be used to update the file object, and the `options` object will be added as a property on the `file` object.\n\n```js\nvar files = glob.sync('**/*.js')\nfiles = files.map(function(fp) {\n  return toFile(fp, '**/*.js');\n});\n```\n\n## Related projects\n\nYou might also be interested in these projects:\n\n* [to-template](https://www.npmjs.com/package/to-template): Convert a vinyl file object to a Template-compatible template object. | [homepage](https://github.com/jonschlinkert/to-template)\n* [to-vinyl](https://www.npmjs.com/package/to-vinyl): Convert an object to a vinyl file object. Safely mixes additional properties onto the file… [more](https://www.npmjs.com/package/to-vinyl) | [homepage](https://github.com/jonschlinkert/to-vinyl)\n\n## Contributing\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/to-file/issues/new).\n\n## Building docs\n\nGenerate readme and API documentation with [verb](https://github.com/verbose/verb):\n\n```sh\n$ npm install verb && npm run docs\n```\n\nOr, if [verb](https://github.com/verbose/verb) is installed globally:\n\n```sh\n$ verb\n```\n\n## Running tests\n\nInstall dev dependencies:\n\n```sh\n$ npm install -d && npm test\n```\n\n## Author\n\n**Jon Schlinkert**\n\n* [github/jonschlinkert](https://github.com/jonschlinkert)\n* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)\n\n## License\n\nCopyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).\nReleased under the [MIT license](https://github.com/jonschlinkert/to-file/blob/master/LICENSE).\n\n***\n\n_This file was generated by [verb](https://github.com/verbose/verb), v0.9.0, on May 07, 2016._","_attachments":{},"homepage":"https://github.com/jonschlinkert/to-file","bugs":{"url":"https://github.com/jonschlinkert/to-file/issues"},"license":"MIT"}