File tree Expand file tree Collapse file tree 1 file changed +42
-0
lines changed
Expand file tree Collapse file tree 1 file changed +42
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Update Dependabot Configuration
2+
3+ on :
4+ schedule :
5+ # Run daily at midnight UTC
6+ - cron : ' 0 0 * * *'
7+ # Allow manual triggering
8+ workflow_dispatch :
9+
10+ jobs :
11+ update-dependabot-config :
12+ runs-on : ubuntu-latest
13+ permissions :
14+ contents : write
15+
16+ steps :
17+ - name : Checkout code
18+ uses : actions/checkout@v4
19+
20+ - name : Set up PHP
21+ uses : shivammathur/setup-php@v2
22+ with :
23+ php-version : ' 8.2'
24+ extensions : json
25+ coverage : none
26+
27+ - name : Generate dependabot configuration
28+ run : php scripts/generate-dependabot-config.php
29+
30+ - name : Check for changes
31+ id : git-check
32+ run : |
33+ git diff --exit-code .github/dependabot.yml || echo "changes=true" >> $GITHUB_OUTPUT
34+
35+ - name : Commit and push if changed
36+ if : steps.git-check.outputs.changes == 'true'
37+ run : |
38+ git config --local user.email "github-actions[bot]@users.noreply.github.com"
39+ git config --local user.name "github-actions[bot]"
40+ git add .github/dependabot.yml
41+ git commit -m "chore: update dependabot configuration [skip ci]"
42+ git push
You can’t perform that action at this time.
0 commit comments