Skip to content

Commit 636032d

Browse files
Merge pull request #109 from Create-Python-App/fix/50-dependabot
ci: Dependabot + auto-merge policy (#50)
2 parents 8e53717 + a986af1 commit 636032d

2 files changed

Lines changed: 28 additions & 0 deletions

File tree

.github/dependabot.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: pip
4+
directory: /
5+
schedule:
6+
interval: weekly
7+
- package-ecosystem: github-actions
8+
directory: /
9+
schedule:
10+
interval: weekly
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Dependabot auto-merge
2+
on: pull_request
3+
permissions:
4+
contents: write
5+
pull-requests: write
6+
jobs:
7+
dependabot:
8+
if: github.event.pull_request.user.login == 'dependabot[bot]'
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: dependabot/fetch-metadata@v2
12+
id: meta
13+
- name: Enable auto-merge for Dependabot PRs
14+
if: steps.meta.outputs.update-type == 'version-update:semver-patch' || steps.meta.outputs.update-type == 'version-update:semver-minor'
15+
run: gh pr merge --auto --squash "$PR_URL"
16+
env:
17+
PR_URL: ${{ github.event.pull_request.html_url }}
18+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)