From 59df8d9618823f45bb9fbb7c973f1121cc0e4fc1 Mon Sep 17 00:00:00 2001 From: Bart Stefanski Date: Mon, 3 Apr 2023 19:02:55 +0200 Subject: [PATCH] chore: setup conventional commits hook --- .pre-commit-config.yaml | 5 ++++ git-conventional-commits.yaml | 43 +++++++++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 .pre-commit-config.yaml create mode 100644 git-conventional-commits.yaml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..b57ef43 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,5 @@ +repos: + - repo: https://github.com/qoomon/git-conventional-commits + rev: v2.6.3 + hooks: + - id: conventional-commits diff --git a/git-conventional-commits.yaml b/git-conventional-commits.yaml new file mode 100644 index 0000000..60ac584 --- /dev/null +++ b/git-conventional-commits.yaml @@ -0,0 +1,43 @@ +--- +convention: + commitTypes: + - feat + - fix + - perf + - refactor + - style + - test + - build + - ops + - docs + - chore + - merge + - revert + commitScopes: [] + releaseTagGlobPattern: v[0-9]*.[0-9]*.[0-9]* +changelog: + commitTypes: + - feat + - fix + - perf + - merge + includeInvalidCommits: true + commitIgnoreRegexPattern: "^WIP " + headlines: + feat: Features + fix: Bug Fixes + perf: Performance Improvements + merge: Merges + breakingChange: BREAKING CHANGES + + ## GitHub + # commitUrl: https://github.com/ACCOUNT/REPOSITORY/commit/%commit% + # commitRangeUrl: https://github.com/ACCOUNT/REPOSITORY/compare/%from%...%to%?diff=split + + ## GitHub Issues + # issueRegexPattern: "#[0-9]+" + # issueUrl: https://github.com/ACCOUNT/REPOSITORY/issues/%issue% + + ## Jira Issues + # issueRegexPattern: "[A-Z][A-Z0-9]+-[0-9]+" + # issueUrl: https://WORKSPACE.atlassian.net/browse/%issue%