|
| 1 | +# commitlint-config-traverson |
| 2 | + |
| 3 | +shareable config for [commitlint](https://github.com/marionebl/commitlint) |
| 4 | + |
| 5 | +<!-- status badges --> |
| 6 | +[![Build Status][ci-badge]][ci-link] |
| 7 | + |
| 8 | +## Purpose |
| 9 | + |
| 10 | +This is a [shareable config](https://marionebl.github.io/commitlint/#/concepts-shareable-config) for [commitlint](https://github.com/marionebl/commitlint), which helps us ensure our commits are compatible with [semantic-release](https://github.com/semantic-release/semantic-release). |
| 11 | + |
| 12 | +This config extends [commitlint-config-travi](https://github.com/travi/commitlint-config-travi). |
| 13 | + |
| 14 | +## Usage |
| 15 | + |
| 16 | +<!-- consumer badges --> |
| 17 | +[![npm][npm-badge]][npm-link] |
| 18 | +[![MIT license][license-badge]][license-link] |
| 19 | + |
| 20 | +### Installation |
| 21 | + |
| 22 | +```sh |
| 23 | +$ npm install commitlint-config-traverson --save-dev |
| 24 | +``` |
| 25 | + |
| 26 | +### Define the config for your project |
| 27 | + |
| 28 | +```sh |
| 29 | +$ echo "module.exports = {extends: ['traverson']};" > .commitlintrc.js |
| 30 | +``` |
| 31 | + |
| 32 | +### Define the [husky](https://github.com/typicode/husky) hook |
| 33 | + |
| 34 | +([in a `.huskyrc.json`](https://github.com/typicode/husky#upgrading-from-014), |
| 35 | +for example) |
| 36 | + |
| 37 | +```json |
| 38 | +{ |
| 39 | + "hooks": { |
| 40 | + "commit-msg": "commitlint -e" |
| 41 | + } |
| 42 | +} |
| 43 | +``` |
| 44 | + |
| 45 | +## Contributing |
| 46 | + |
| 47 | +<!-- contribution badges --> |
| 48 | +[![Conventional Commits][commit-convention-badge]][commit-convention-link] |
| 49 | +[![Commitizen friendly][commitizen-badge]][commitizen-link] |
| 50 | +[![semantic-release][semantic-release-badge]][semantic-release-link] |
| 51 | +[![PRs Welcome][PRs-badge]][PRs-link] |
| 52 | + |
| 53 | +### Dependencies |
| 54 | + |
| 55 | +```sh |
| 56 | +$ nvm install |
| 57 | +$ npm install |
| 58 | +``` |
| 59 | + |
| 60 | +### Verification |
| 61 | + |
| 62 | +```sh |
| 63 | +$ npm test |
| 64 | +``` |
| 65 | + |
| 66 | +[npm-link]: https://www.npmjs.com/package/commitlint-config-traverson |
| 67 | +[npm-badge]: https://img.shields.io/npm/v/commitlint-config-traverson.svg |
| 68 | +[license-link]: LICENSE |
| 69 | +[license-badge]: https://img.shields.io/github/license/traverson/commitlint-config-traverson.svg |
| 70 | +[ci-link]: https://travis-ci.com/traverson/commitlint-config-traverson |
| 71 | +[ci-badge]: https://img.shields.io/travis/traverson/commitlint-config-traverson.svg?branch=master |
| 72 | +[commit-convention-link]: https://conventionalcommits.org |
| 73 | +[commit-convention-badge]: https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg |
| 74 | +[commitizen-link]: http://commitizen.github.io/cz-cli/ |
| 75 | +[commitizen-badge]: https://img.shields.io/badge/commitizen-friendly-brightgreen.svg |
| 76 | +[semantic-release-link]: https://github.com/semantic-release/semantic-release |
| 77 | +[semantic-release-badge]: https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg |
| 78 | +[PRs-link]: http://makeapullrequest.com |
| 79 | +[PRs-badge]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg |
0 commit comments