feat(orquestra): enforce semver and conventional commits
This commit is contained in:
16
scripts/install_git_hooks.sh
Executable file
16
scripts/install_git_hooks.sh
Executable file
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd -P)"
|
||||
cd "$ROOT"
|
||||
|
||||
git rev-parse --is-inside-work-tree >/dev/null 2>&1 || {
|
||||
echo '[FAIL] Not inside a git repository' >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
chmod +x scripts/git-hooks/commit-msg scripts/validate_conventional_commit.py scripts/version.py
|
||||
git config core.hooksPath scripts/git-hooks
|
||||
|
||||
echo '[OK] Git hooks installed: core.hooksPath=scripts/git-hooks'
|
||||
echo '[OK] commit-msg now enforces Conventional Commits'
|
||||
Reference in New Issue
Block a user