|
| 1 | +# Contributing |
| 2 | + |
1 | 3 | See the [contributing docs](https://github.com/yeoman/yeoman/blob/master/contributing.md) |
2 | 4 |
|
3 | 5 | Additionally for this generator: |
4 | 6 |
|
5 | | -When submitting an issue, please follow the [guidelines](https://github.com/yeoman/yeoman/blob/master/contributing.md#issue-submission). Especially important is to make sure Yeoman is up-to-date, and providing the command or commands that cause the issue. |
| 7 | +* When submitting an issue, please follow the [guidelines](https://github.com/yeoman/yeoman/blob/master/contributing.md#issue-submission). Especially important is to make sure Yeoman is up-to-date, and providing the command or commands that cause the issue. |
| 8 | +* When submitting a PR, make sure that the commit messages match the [AngularJS conventions][commit-message-format] (see below). |
| 9 | +* When submitting a bugfix, write a test that exposes the bug and fails before applying your fix. Submit the test alongside the fix. |
| 10 | +* When submitting a new feature, add tests that cover the feature. |
| 11 | + |
| 12 | +## Git Commit Guidelines |
| 13 | + |
| 14 | +These rules are adopted from the AngularJS project. |
| 15 | + |
| 16 | +### Commit Message Format |
| 17 | +Each commit message consists of a **header**, a **body** and a **footer**. The header has a special |
| 18 | +format that includes a **type**, a **scope** and a **subject**: |
| 19 | + |
| 20 | +``` |
| 21 | +<type>(<scope>): <subject> |
| 22 | +<BLANK LINE> |
| 23 | +<body> |
| 24 | +<BLANK LINE> |
| 25 | +<footer> |
| 26 | +``` |
| 27 | + |
| 28 | +Any line of the commit message cannot be longer 100 characters! This allows the message to be easier |
| 29 | +to read on github as well as in various git tools. |
| 30 | + |
| 31 | +### Type |
| 32 | +Must be one of the following: |
| 33 | + |
| 34 | +* **feat**: A new feature |
| 35 | +* **fix**: A bug fix |
| 36 | +* **docs**: Documentation only changes |
| 37 | +* **style**: Changes that do not affect the meaning of the code (white-space, formatting, missing |
| 38 | + semi-colons, etc) |
| 39 | +* **refactor**: A code change that neither fixes a bug or adds a feature |
| 40 | +* **test**: Adding missing tests |
| 41 | +* **chore**: Changes to the build process or auxiliary tools and libraries such as documentation |
| 42 | + generation |
| 43 | + |
| 44 | +### Scope |
| 45 | +The scope could be anything specifying place of the commit change. For example `app`, |
| 46 | +`gen`, `docs`, `gen:view`, `gen:route`, `gen:service`, etc... |
| 47 | + |
| 48 | +### Subject |
| 49 | +The subject contains succinct description of the change: |
| 50 | + |
| 51 | +* use the imperative, present tense: "change" not "changed" nor "changes" |
| 52 | +* don't capitalize first letter |
| 53 | +* no dot (.) at the end |
| 54 | + |
| 55 | +###Body |
| 56 | +Just as in the **subject**, use the imperative, present tense: "change" not "changed" nor "changes" |
| 57 | +The body should include the motivation for the change and contrast this with previous behavior. |
6 | 58 |
|
7 | | -When submitting a PR, make sure that the commit messages match the [AngularJS conventions](https://docs.google.com/document/d/1QrDFcIiPjSLDn3EL15IJygNPiHORgU1_OOAqWjiDU5Y/). |
| 59 | +###Footer |
| 60 | +The footer should contain any information about **Breaking Changes** and is also the place to |
| 61 | +reference GitHub issues that this commit **Closes**. |
8 | 62 |
|
9 | | -When submitting a bugfix, write a test that exposes the bug and fails before applying your fix. Submit the test alongside the fix. |
| 63 | +A detailed explanation can be found in this [document][commit-message-format]. |
10 | 64 |
|
11 | | -When submitting a new feature, add tests that cover the feature. |
| 65 | +[commit-message-format]: https://docs.google.com/document/d/1QrDFcIiPjSLDn3EL15IJygNPiHORgU1_OOAqWjiDU5Y |
0 commit comments