diff options
author | John MacFarlane <jgm@berkeley.edu> | 2020-05-21 14:38:14 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2020-05-21 14:38:14 -0700 |
commit | 2aa0832320ff1cc7f6268e59380830784de083c3 (patch) | |
tree | d83a0bc45bcb66406086c8790ae2b8c01ace976f | |
parent | 1b3ce803471511262c8d66573651d3f051909462 (diff) | |
download | pandoc-2aa0832320ff1cc7f6268e59380830784de083c3.tar.gz |
Add commit message check to ci.yml workflow.
-rw-r--r-- | .github/workflows/ci.yml | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 05bb75f7f..97d4eb889 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,6 +58,17 @@ jobs: steps: - uses: actions/checkout@v1 + - name: Check commit message + run: | + # Get last commit message + git log -1 --pretty=format:"%s" | grep -c "^[^#].{78}" + if [ $? -eq 0 ]; then + echo "Last commit log contains a line with more than 78 characters." + exit 1 + else + echo "Commit log looks good." + fi + # declare/restore cached things # caching doesn't work for scheduled runs yet # https://github.com/actions/cache/issues/63 |