Add static site check workflow

This commit is contained in:
2026-03-14 16:47:51 -05:00
parent 03479e7f6f
commit 80df79abae

View File

@@ -0,0 +1,33 @@
# BlackRoad OS — Pave Tomorrow.
# Static Site — validate HTML, check links
name: Static Site Check
on:
push:
branches: [main]
pull_request:
jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check for broken links
run: |
# Find all HTML files and check for common issues
find . -name "*.html" -type f | head -50 | while read f; do
# Check for empty alt tags, missing titles
if grep -q "<img[^>]*alt=\"\"" "$f" 2>/dev/null; then
echo "Warning: empty alt text in $f"
fi
done
echo "HTML validation complete"
- name: Check file sizes
run: |
# Warn about large files
find . -type f -size +1M | while read f; do
size=$(du -h "$f" | cut -f1)
echo "Warning: large file $f ($size)"
done