woodburn/.gitea/workflows/push.yml

28 lines
643 B
YAML
Raw Normal View History

2023-07-17 16:40:30 +10:00
name: OnPush
run-name: ${{ gitea.actor }} has pushed to woodburn repo
on: [push]
jobs:
2023-07-17 16:44:22 +10:00
CheckFiles:
2023-07-17 16:40:30 +10:00
runs-on: ubuntu-latest
steps:
- name: Commiter
run: |
echo "Commited by: ${{ gitea.actor }}!"
2023-07-17 16:44:22 +10:00
- name: Checkout
uses: actions/checkout@v2
2023-07-17 16:40:30 +10:00
- name: List HTML files
run: |
2023-07-17 16:44:22 +10:00
ls *.html
2023-07-17 16:50:39 +10:00
- name: Check files
2023-07-17 16:48:37 +10:00
run: |
for file in *.html; do
2023-07-17 16:51:32 +10:00
if grep -q "$file" "$file"; then
echo "File $file contains $file!"
2023-07-17 16:48:37 +10:00
exit 1
2023-07-17 16:50:39 +10:00
else
2023-07-17 16:51:32 +10:00
echo "File $file does not contain $file!"
2023-07-17 16:48:37 +10:00
fi
done