File tree Expand file tree Collapse file tree 2 files changed +39
-0
lines changed
Expand file tree Collapse file tree 2 files changed +39
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Dependabot Auto-Merge
2+
3+ # Dependabot Pull Requests Auto-Merge
4+
5+ # The auto-merge will be performed only if the semantic version for the changes is MINOR or PATCH.
6+ # Pull Requests with semantic versions MAJOR will need manual review and approval.
7+
8+ on :
9+ pull_request :
10+ branches : ["master", "main"]
11+
12+ permissions :
13+ contents : write
14+ pull-requests : write
15+
16+ jobs :
17+ dependabot-automerge :
18+ runs-on : ubuntu-latest
19+ # Solo si es Dependabot
20+ if : github.actor == 'dependabot[bot]'
21+
22+ steps :
23+ - name : Metadata de Dependabot
24+ id : metadata
25+ uses : dependabot/fetch-metadata@08eff52bf64351f401fb50d4972fa95b9f2c2d1b # v2.4.0
26+ with :
27+ github-token : " ${{ secrets.GITHUB_TOKEN }}"
28+
29+ # Este paso maneja AMBOS casos (pom.xml y workflows) automáticamente.
30+ # fetch-metadata analiza el cambio de versión (SemVer), no el tipo de archivo.
31+ - name : Activar Auto-Merge
32+ # Solo Minor y Patch
33+ if : ${{ steps.metadata.outputs.update-type == 'version-update:semver-minor' || steps.metadata.outputs.update-type == 'version-update:semver-patch' }}
34+ run : gh pr merge --auto --squash "$PR_URL"
35+ env :
36+ PR_URL : ${{ github.event.pull_request.html_url }}
37+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change @@ -140,3 +140,5 @@ git clone https://github.com/Flashky/advent-of-code-{year}.git --recurse-submodu
140140## About
141141
142142- [ Advent of Code] ( https://adventofcode.com/{year}/about )
143+
144+
You can’t perform that action at this time.
0 commit comments