-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci(pre-commit): enforce conventional-commits message structure
This adds pre-commit and ci checks to ensure that commit messages follow [`conventional-commits`](https://www.conventionalcommits.org/en/v1.0.0/). From their site: Conventional Commits is: `A specification for adding human and machine readable meaning to commit messages` Commit messages must follow the following format: ``` <type>[optional scope]: <description> [optional body] [optional footer(s)] ``` In general, this means that you will provide a topic: * feat * fix * ci * refactor Followed by a description. Following this standard allows for automatic semantic versioning and release note generation. * `.commitlintrc.yaml` - defines the commit message format for linting * `.cz.json` - configuration for [`commitizen-cli`](http://commitizen.github.io/cz-cli/)
- Loading branch information
Showing
5 changed files
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
extends: | ||
- "@commitlint/config-conventional" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"maxHeaderWidth": 72, | ||
"path": "cz-conventional-changelog" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,9 +12,12 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Go | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: 1.15 | ||
- uses: actions/setup-python@v2 | ||
- uses: pre-commit/[email protected] | ||
- uses: wagoid/commitlint-github-action@v2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters