{"name":"update-year","description":"Update a year or range of years in a string.","version":"0.3.0","homepage":"https://github.com/jonschlinkert/update-year","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/update-year.git"},"bugs":{"url":"https://github.com/jonschlinkert/update-year/issues"},"license":{"type":"MIT","url":"https://github.com/jonschlinkert/update-year/blob/master/LICENSE-MIT"},"main":"index.js","files":["index.js"],"engines":{"node":">=0.10.0"},"scripts":{"test":"mocha -R spec"},"dependencies":{"array-unique":"^0.1.1","year":"^0.2.1"},"devDependencies":{"mocha":"*","should":"*"},"keywords":["parse","update","year"],"gitHead":"d1f351ce7a2a58fbc5ea1c9b71cabbb57e67b6e7","_id":"update-year@0.3.0","_shasum":"495144f81e61c76fb04eab2bc66ad99e40a90025","_from":".","_npmVersion":"1.4.28","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"495144f81e61c76fb04eab2bc66ad99e40a90025","tarball":"http://registry-npm.ywwl.com/update-year/download/update-year-0.3.0.tgz","integrity":"sha512-6lsVYOS55ntp6S0ijNHd/N/snH8qu4LKBGTs9Vw1Km+nMvFxJc+ZDRqdlP7CCJI2KcS95Am9qubWSaw4WlRzhA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCHDMMIrBl62SCX6OJdYcLga75SNhOYKG44RVwNVE1xlwIgDoR/4eJHNNHo6poJpTaNyIc5OMMfCyjTugAkvLLfZ98="}],"size":1587,"noattachment":false,"key":"/update-year/-/update-year-0.3.0.tgz"},"directories":{},"readme":"# update-year [![NPM version](https://img.shields.io/npm/v/update-year.svg)](https://www.npmjs.com/package/update-year) [![Build Status](https://img.shields.io/travis/jonschlinkert/update-year.svg)](https://travis-ci.org/jonschlinkert/update-year)\n\n> Update or add the current year to a range of years in a string.\n\n- [Install](#install)\n- [Usage](#usage)\n  * [.matchRange](#matchrange)\n- [Related projects](#related-projects)\n- [Running tests](#running-tests)\n- [Contributing](#contributing)\n- [Author](#author)\n- [License](#license)\n\n_(TOC generated by [verb](https://github.com/verbose/verb) using [markdown-toc](https://github.com/jonschlinkert/markdown-toc))_\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/):\n\n```sh\n$ npm i update-year --save\n```\n\n## Usage\n\n_(Useful for updating [copyright statements](https://github.com/jonschlinkert/update-copyright), etc.)_\n\nPass a year, or a range of years (e.g. `1999-2012`), and the current year will be appended or the range will be updated with the current year, using the correct syntax.\n\n**Examples**\n\n```js\nvar year = require('update-year');\n\nyear('2016'); //=> '2016'\nyear('2015'); //=> '2015-2016'\nyear('2012'); //=> '2012, 2016'\nyear('2013'); //=> '2013, 2016'\nyear('2014'); //=> '2014, 2016'\nyear('2013, 2015'); //=> '2013, 2015-2016'\nyear('2014-2015'); //=> '2014-2016'\nyear('1999, 2001'); //=> '1999, 2001, 2016'\nyear('1999-2001'); //=> '1999-2001, 2016'\nyear('1999-2001, 2009'); //=> '1999-2001, 2009, 2016'\n```\n\n### .matchRange\n\nMatch a year or year range in a string\n\n```js\nyear.matchRange('foo bar 2009, 2011, 2013-2014 baz');\n//=> '2009, 2011, 2013-2014'\n```\n\n## Related projects\n\n* [month](https://www.npmjs.com/package/month): Get the name or number of the current month or any month of the year. | [homepage](https://github.com/datetime/month)\n* [update-copyright](https://www.npmjs.com/package/update-copyright): Update the copyright statement in a string based on globally stored template and values. | [homepage](https://github.com/jonschlinkert/update-copyright)\n* [year](https://www.npmjs.com/package/year): Simple utility to get the current year with 2 or 4 digits. | [homepage](https://github.com/jonschlinkert/year)\n\n## Running tests\n\nInstall dev dependencies:\n\n```sh\n$ npm i -d && npm test\n```\n\n## Contributing\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/update-year/issues/new).\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.\n\n***\n\n_This file was generated by [verb](https://github.com/verbose/verb) on January 19, 2016._","publish_time":1422794414936,"_cnpm_publish_time":1422794414936,"dist-tags":{"latest":"0.5.2"}}