|
| 1 | +# Commit Messages |
| 2 | + |
| 3 | +Contributors should adhere to our [commit message guidelines](https://docs.google.com/document/d/1QrDFcIiPjSLDn3EL15IJygNPiHORgU1_OOAqWjiDU5Y/edit?pli=1). |
| 4 | + |
| 5 | +The goal is to achive better readability of the projects commit log and eventually use the log as a low level change tracker. |
| 6 | + |
| 7 | +```plain |
| 8 | +feat(context-pad): add delete button |
| 9 | +fix(modeling): assign valid semantic ids |
| 10 | +fix(Viewer): correctly fire imported event |
| 11 | +fix(core): handle missing DMNTable during import |
| 12 | +``` |
| 13 | + |
| 14 | +It is important for [semantic versioning](http://semver.org/) during releases and for project change tracking. |
| 15 | + |
| 16 | + |
| 17 | +## General Syntax |
| 18 | + |
| 19 | +```plain |
| 20 | +<what>(<component>): <present-tense-description> |
| 21 | +
|
| 22 | +<longer-description> |
| 23 | +
|
| 24 | +Closes #<issue-number> |
| 25 | +
|
| 26 | +[BREAKING CHANGE: |
| 27 | +
|
| 28 | +* migration notes ] |
| 29 | +``` |
| 30 | + |
| 31 | + |
| 32 | +## Hints |
| 33 | + |
| 34 | +Consider the following hints when writing commit messages |
| 35 | + |
| 36 | +* Classify what you did |
| 37 | + |
| 38 | + * `fix` commit fixes a bug, patches the project |
| 39 | + * `feat` commit adds a feature, increases the minor version |
| 40 | + * `docs` commit improves or adds documentation |
| 41 | + * `refactor` commit cleans up mess in a non-api-breaking manner |
| 42 | + |
| 43 | +* State the module your change applies to |
| 44 | + |
| 45 | + * `viewer` commit changes viewer code |
| 46 | + * `context-pad` commit alters context pad |
| 47 | + * `modeling/DmnFactory` commit fixes a specific bug in the `DmnFactory` (use in rare important cases only) |
| 48 | + * use lower case for modules, camelCase for files (according to file names) |
| 49 | + |
| 50 | +* beware of public api (everything that has been blogged about on the [camunda team blog](http://blog.camunda.org/)) |
| 51 | + |
| 52 | + * mark breaking public api via `BREAKING CHANGE: ...` |
| 53 | + |
| 54 | +* try not to swallow bug fixes (`fix`) in feature commits (`feat`). People may wait for a fixes forever. |
| 55 | + |
| 56 | + |
| 57 | +## Examples |
| 58 | + |
| 59 | +```plain |
| 60 | +feat(modeler): add create table option |
| 61 | +
|
| 62 | +This commit adds the ability to create a new table in the modeler via |
| 63 | +
|
| 64 | +Modeler#createTable(done) |
| 65 | +
|
| 66 | +Related to #12 |
| 67 | +``` |
| 68 | + |
| 69 | + |
| 70 | +```plain |
| 71 | +fix(modeling): generate valid semantic ids |
| 72 | +
|
| 73 | +IDs in XML documents must not start with a number as per XML spec. |
| 74 | +
|
| 75 | +This commit changes our id generation behavior to use semantic ids that |
| 76 | +are prefixed with the elements type (never starts with a number): |
| 77 | +
|
| 78 | +Before: asdas123se8as |
| 79 | +Now: Rule_asdas123se8as |
| 80 | +
|
| 81 | +Closes #108 |
| 82 | +``` |
0 commit comments