diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2021-04-23 20:09:07 +0200 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2021-04-23 20:09:59 +0200 |
commit | 707c6d1d448284efff002eb1866f31fc31cef7b3 (patch) | |
tree | 966b2d09c5eeeca610c4308ba573867745e6ca96 /.github/workflows/commit-validation.yml | |
parent | 113479feb55e555a6a114cf6878f9a24c48b3347 (diff) | |
download | pandoc-707c6d1d448284efff002eb1866f31fc31cef7b3.tar.gz |
Remove some garbage
Diffstat (limited to '.github/workflows/commit-validation.yml')
-rw-r--r-- | .github/workflows/commit-validation.yml | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/.github/workflows/commit-validation.yml b/.github/workflows/commit-validation.yml deleted file mode 100644 index 0b52e94e5..000000000 --- a/.github/workflows/commit-validation.yml +++ /dev/null @@ -1,38 +0,0 @@ -name: commit-validation -on: [ push, pull_request ] - -jobs: - check-commit-msg-length: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v1 - - name: Check commit message length - run: | - # Get last commit messages - if [ "${{github.event_name}}" = "push" ]; then - if [ "${{github.event.before}}" = "0000000000000000000000000000000000000000" ]; then - # We are on a new branch - current="$(echo '${{github.ref}}' | sed 's!^refs/heads!origin!')" - readarray -t other < <(git show-ref | awk -F' ' '{ sub(/^refs\/remotes\//,"",$NF); }($NF != "'"$current"'"){print "^" $NF;}') - LOG_RANGE=( "$current" "${other[@]}" ) - unset current other - else - # We are on existing branch - LOG_RANGE=( "${{github.event.before}}.." ) - fi - elif [ "${{github.event_name}}" = "pull_request" ]; then - LOG_RANGE=( "origin/${{github.base_ref}}.." ) - fi - if [[ -v LOG_RANGE ]]; then - if git log --no-merges --pretty=format:"%s" "${LOG_RANGE[@]}" -- | grep -qE "^[^#].{78}"; then - echo -e "Last commit log contains a line with more than 78 characters:\n" - git log --no-merges --pretty=format:"%h: %s" "${LOG_RANGE[@]}" -- | grep -E "^[^:]+: [^#].{78}" - echo - exit 1 - else - echo "Commit log looks good." - fi - unset LOG_RANGE - else - echo "Not checking commits on ${{github.event_name}}" - fi |