Skip to content

Commit

Permalink
Merge pull request #3 from beeware/meta-dependabot
Browse files Browse the repository at this point in the history
Enable dependabot on the dependabot configuration
  • Loading branch information
rmartin16 authored Dec 12, 2022
2 parents 440e711 + 5a814f5 commit 7b3ca0b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
9 changes: 9 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
# Check for updates on Sunday, 8PM UTC
interval: "weekly"
day: "sunday"
time: "20:00"
6 changes: 3 additions & 3 deletions .github/workflows/dependabot-changenote.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ permissions:
jobs:
changenote:
name: Dependabot Change Note
if: github.actor == 'dependabot[bot]'
if: github.actor == 'dependabot[bot]' && github.repository != 'beeware/.github'
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
Expand All @@ -30,11 +30,11 @@ jobs:
# Fetch PR number for commit from Github API
API_URL="${{ github.api_url }}/repos/${{ github.repository }}/commits/${{ github.event.head_commit.id }}/pulls"
PR_NUM=$(curl -s -H "Accept: application/vnd.github+json" "${API_URL}" | jq -r '.[].number')
# Create change note from first line of dependabot commit
NEWS=$(printf "%s" "${{ github.event.head_commit.message }}" | head -n1 | sed -e 's/Bump/Updated/')
printf "%s.\n" "${NEWS}" > "./changes/${PR_NUM}.misc.rst"
# Commit the change note
git add "./changes/${PR_NUM}.misc.rst"
# "dependabot skip" tells Dependabot to continue rebasing this branch despite foreign commits
Expand Down

0 comments on commit 7b3ca0b

Please sign in to comment.