The JSCutlery team develops using techniques like Timeboxed TDD and TCR (Test && Commit || Revert). In other words, we commit a lot!!!
We use emojis for commits categorization:
Type | Example | When |
---|---|---|
Work In Progress | wip(plugin-cache): 🚧 do craziness |
This is the commit message when working on a feature. Same message can be reused while working on the feature. |
Feature | feat(plugin-cache): ✅ add craziness |
This is the final commit when the feature is finished and you want it to appear in the changelog. It can be an empty commit. |
Fix | fix(plugin-cache): 🐞 fix craziness |
Anything that fixes a user facing bug. |
Anything else | chore(plugin-cache): 🛠 rename stuff |
This applies to all changes that don't bring new features or fix user facing bugs. |
Docs | docs(plugin-cache): 📝 add docs |
Documentation |
-
Each commit type can be scoped by package name like
feat(core,plugin-cache):
, or no scope at all (i.e.feat:
) if it affects everything -
The
wip
type is allowed to be compliant with TCR -
Breaking changes should add
!
or aBREAKING CHANGE: ...
line in the body of the commit message with the explanation next to it.
Cf. https://www.conventionalcommits.org/
Meanwhile we provide a schematic for this, here are the steps to follow when adding a new plugin:
- Generate library
yarn nx g @nrwl/workspace:library --publishable plugin-xyz
- Update
libs/plugin-xyz/package.json
{
"name": "@convoyr/plugin-xyz",
"version": "2.1.0",
"license": "MIT",
"private": false,
"repository": "[email protected]:jscutlery/convoyr.git",
"scripts": {
"prepublishOnly": "ng build plugin-xyz --prod"
},
"peerDependencies": {
"@convoyr/core": ">= 3.0.0"
}
}
- Update
libs/plugin-xyz/ng-package.json
{
...,
"dest": "dist",
...
}
- Codecov setup by adding the following to codecov.yml
coverage:
status:
project:
plugin-xyz:
target: 90%
flags: plugin-xyz
flags:
plugin-xyz:
paths:
- libs/plugin-xyz/src
🚧 Work In Progress 🚧