feat: start website background tasks #1
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
name: Commit Message | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
check_commit_messages: | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout code | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
fetch-depth: 0 | |
- name: show logs | |
run: git log --format="%s" origin/main..HEAD | |
- name: Check commit messages | |
run: | | |
git log --format="%s" origin/main..HEAD | while IFS= read -r message; do | |
echo "Checking commit message: $message" | |
if ! bash .githooks/commit-msg "$message"; then | |
echo "Error: Commit message '$message' does not follow the required format." | |
exit 1 | |
fi | |
done |