{"_id":"rewrite-ext","_rev":"77438","name":"rewrite-ext","description":"Automatically re-write the destination extension of a filepath based on the source extension. e.g  `.coffee` => `.js`. This will only rename the ext, no other path parts are modified.","dist-tags":{"latest":"1.0.0"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"time":{"modified":"2021-06-03T10:24:54.000Z","created":"2014-11-13T16:23:37.941Z","1.0.0":"2017-03-23T00:11:09.218Z","0.2.0":"2015-02-22T23:35:51.588Z","0.1.0":"2014-11-13T16:23:37.941Z"},"users":{},"author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/rewrite-ext.git"},"versions":{"1.0.0":{"name":"rewrite-ext","description":"Automatically re-write the destination extension of a filepath based on the source extension. e.g  `.coffee` => `.js`. This will only rename the ext, no other path parts are modified.","version":"1.0.0","homepage":"https://github.com/jonschlinkert/rewrite-ext","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/rewrite-ext.git"},"bugs":{"url":"https://github.com/jonschlinkert/rewrite-ext/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"ext-map":"^1.0.1","extend-shallow":"^2.0.1"},"devDependencies":{"gulp-format-md":"^0.1.11","mocha":"^3.2.0"},"keywords":["dest","ext","extensions","extname","file","filename","filepath","fp","fs","gulpfriendly","map","path","rewrite","src"],"verb":{"related":{"list":["file-normalize","parse-filepath","fs-utils"]},"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"lint":{"reflinks":true}},"gitHead":"d957635c216c5d2e775ab06a71c99bf812ec75d8","_id":"rewrite-ext@1.0.0","_shasum":"9190ffdab41ad080bda1a3ebaa7a47ab4fe86998","_from":".","_npmVersion":"4.1.2","_nodeVersion":"7.7.3","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"9190ffdab41ad080bda1a3ebaa7a47ab4fe86998","size":2921,"noattachment":false,"key":"/rewrite-ext/-/rewrite-ext-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/rewrite-ext/download/rewrite-ext-1.0.0.tgz"},"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/rewrite-ext-1.0.0.tgz_1490227867257_0.17998358141630888"},"directories":{},"publish_time":1490227869218,"_cnpm_publish_time":1490227869218,"_hasShrinkwrap":false},"0.2.0":{"name":"rewrite-ext","description":"Automatically re-write the destination extension of a filepath based on the source extension. e.g  `.coffee` => `.js`. This will only rename the ext, no other path parts are modified.","version":"0.2.0","homepage":"https://github.com/jonschlinkert/rewrite-ext","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"https://github.com/jonschlinkert/rewrite-ext"},"bugs":{"url":"https://github.com/jonschlinkert/rewrite-ext/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"ext-map":"^1.0.0"},"devDependencies":{"mocha":"*","should":"*"},"keywords":["dest","ext","extensions","extname","file","filename","filepath","fp","fs","gulpfriendly","map","path","src"],"gitHead":"973c2508d69e466e576e0e52b52c618f5eaaffdb","_id":"rewrite-ext@0.2.0","_shasum":"5b358b4472d4f544e7036c37b066306492edd7b4","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"5b358b4472d4f544e7036c37b066306492edd7b4","size":1991,"noattachment":false,"key":"/rewrite-ext/-/rewrite-ext-0.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/rewrite-ext/download/rewrite-ext-0.2.0.tgz"},"directories":{},"publish_time":1424648151588,"_cnpm_publish_time":1424648151588,"_hasShrinkwrap":false},"0.1.0":{"name":"rewrite-ext","description":"Automatically re-write the destination extension of a filepath based on the source extension. e.g  `.coffee` => `.js`. This will only rename the ext, no other path parts are modified.","version":"0.1.0","homepage":"https://github.com/jonschlinkert/rewrite-ext","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/rewrite-ext.git"},"bugs":{"url":"https://github.com/jonschlinkert/rewrite-ext/issues"},"licenses":[{"type":"MIT","url":"https://github.com/jonschlinkert/rewrite-ext/blob/master/LICENSE-MIT"}],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha -R spec"},"devDependencies":{"mocha":"*","should":"*"},"keywords":["dest","ext","extensions","extname","file","filename","filepath","fp","fs","gulpfriendly","map","path","src"],"dependencies":{"ext-map":"^0.1.0"},"_id":"rewrite-ext@0.1.0","_shasum":"1efb9f659d984cf937a49083bc03034b32c10dd5","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"1efb9f659d984cf937a49083bc03034b32c10dd5","size":3116,"noattachment":false,"key":"/rewrite-ext/-/rewrite-ext-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/rewrite-ext/download/rewrite-ext-0.1.0.tgz"},"directories":{},"publish_time":1415895817941,"_cnpm_publish_time":1415895817941,"_hasShrinkwrap":false}},"readme":"# rewrite-ext [![NPM version](https://img.shields.io/npm/v/rewrite-ext.svg?style=flat)](https://www.npmjs.com/package/rewrite-ext) [![NPM monthly downloads](https://img.shields.io/npm/dm/rewrite-ext.svg?style=flat)](https://npmjs.org/package/rewrite-ext)  [![NPM total downloads](https://img.shields.io/npm/dt/rewrite-ext.svg?style=flat)](https://npmjs.org/package/rewrite-ext) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/rewrite-ext.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/rewrite-ext)\n\n> Automatically re-write the destination extension of a filepath based on the source extension. e.g  `.coffee` => `.js`. This will only rename the ext, no other path parts are modified.\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/):\n\n```sh\n$ npm install --save rewrite-ext\n```\n\n## Usage\n\n```js\nvar rewrite = require('rewrite-ext');\n```\n\nAutomatically re-write extensions to the mapped extensions from [ext-map](https://github.com/jonschlinkert/ext-map):\n\n```js\nconsole.log(rewrite('abc.coffee'));\n//=> 'abc.js'\nconsole.log(rewrite('abc.less'));\n//=> 'abc.css'\n```\n\nExplicitly pass an extension to use:\n\n```js\nconsole.log(rewrite('foo/bar.txt', '.abc'));\n//=> 'foo/bar.abc'\n```\n\n## More examples\n\n```js\nrewrite('abc.styl');    //=> 'abc.css'\nrewrite('abc.sass');    //=> 'abc.css'\nrewrite('abc.scss');    //=> 'abc.css'\nrewrite('faux.css');    //=> 'faux.css'\nrewrite('abc.swig');    //=> 'abc.html'\nrewrite('abc.hbs');     //=> 'abc.html'\nrewrite('abc.md');      //=> 'abc.html'\nrewrite('abc.tmpl');    //=> 'abc.html'\nrewrite('faux.html');   //=> 'faux.html'\nrewrite('faux.coffee'); //=> 'faux.js'\n```\n\n## About\n\n### Related projects\n\n* [file-normalize](https://www.npmjs.com/package/file-normalize): File system utils for normalizing things like eol, encoding and BOM.  | [homepage](https://github.com/jonschlinkert/file-normalize \"File system utils for normalizing things like eol, encoding and BOM. \")\n* [fs-utils](https://www.npmjs.com/package/fs-utils): fs extras and utilities to extend the node.js file system module. Used in Assemble and… [more](https://github.com/assemble/fs-utils) | [homepage](https://github.com/assemble/fs-utils \"fs extras and utilities to extend the node.js file system module. Used in Assemble and many other projects.\")\n* [parse-filepath](https://www.npmjs.com/package/parse-filepath): Pollyfill for node.js `path.parse`, parses a filepath into an object. | [homepage](https://github.com/jonschlinkert/parse-filepath \"Pollyfill for node.js `path.parse`, parses a filepath into an object.\")\n\n### Contributing\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).\n\n### Building docs\n\n_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_\n\nTo generate the readme, run the following command:\n\n```sh\n$ npm install -g verbose/verb#dev verb-generate-readme && verb\n```\n\n### Running tests\n\nRunning and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:\n\n```sh\n$ npm install && npm test\n```\n\n### Author\n\n**Jon Schlinkert**\n\n* [github/jonschlinkert](https://github.com/jonschlinkert)\n* [twitter/jonschlinkert](https://twitter.com/jonschlinkert)\n\n### License\n\nCopyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert).\nReleased under the [MIT License](LICENSE).\n\n***\n\n_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.4.3, on March 22, 2017._","_attachments":{},"homepage":"https://github.com/jonschlinkert/rewrite-ext","bugs":{"url":"https://github.com/jonschlinkert/rewrite-ext/issues"},"license":"MIT"}