File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Trigger Netlify Build on public/ changes
2+
3+ # Nur auslösen, wenn sich Dateien im public/ Ordner ändern
4+ on :
5+ push :
6+ paths :
7+ - ' public/**'
8+
9+ jobs :
10+ netlify-build :
11+ runs-on : ubuntu-latest
12+
13+ steps :
14+ # Checkout Code
15+ - name : Checkout repository
16+ uses : actions/checkout@v3
17+
18+ # Optional: Check whether public/ has really changed
19+ - name : Check for changes in public/
20+ id : check_changes
21+ run : |
22+ echo "CHANGED=$(git diff --name-only HEAD~1 | grep -E '^public/' || true)" >> $GITHUB_ENV
23+ if [ -z "$CHANGED" ]; then
24+ echo "No changes in public/, exiting."
25+ exit 0
26+ fi
27+
28+ # Trigger Netlify Build Hook
29+ - name : Trigger Netlify Build
30+ run : |
31+ curl -X POST -d '{}' ${{ secrets.NETLIFY_BUILD_HOOK }}
You can’t perform that action at this time.
0 commit comments