This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
zhangyang-zerotierone/.github/workflows/badstrings.yml
2021-09-28 17:06:50 +02:00

18 lines
524 B
YAML

name: badstrings
on: [pull_request, push]
jobs:
badstrings:
runs-on: ubuntu-latest
steps:
- name: scanning commit message for bad strings
run: |
#!/bin/bash
set -euo pipefail
IFS=$'\n\t'
message="${{ github.event.head_commit.message }}"
strings=($(curl -s https://raw.githubusercontent.com/someara/badstrings/main/strings.txt))
for i in ${strings[@]} ; do
echo "${message}" | grep -v "$i" &>/dev/null;
done