summary refs log tree commit diff
path: root/.github/workflows/dependabot_changelog.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/dependabot_changelog.yml')
-rw-r--r--.github/workflows/dependabot_changelog.yml23
1 files changed, 23 insertions, 0 deletions
diff --git a/.github/workflows/dependabot_changelog.yml b/.github/workflows/dependabot_changelog.yml
new file mode 100644
index 0000000000..9fef12a91c
--- /dev/null
+++ b/.github/workflows/dependabot_changelog.yml
@@ -0,0 +1,23 @@
+name: Write changelog for dependabot PR
+on:
+  pull_request:
+    types:
+      - opened
+
+jobs:
+  add-changelog:
+    runs-on: 'ubuntu-latest'
+    if: ${{ github.actor == 'dependabot[bot]' }}
+    steps:
+      - uses: actions/checkout@v3
+        with:
+          ref: ${{ github.event.pull_request.head.ref }}
+      - name: Write, commit and push changelog
+        run: |
+          echo "${{ github.event.pull_request.title }}." > "changelog.d/${{ github.event.pull_request.number }}".docker
+          git add changelog.d
+          git config user.email "github-actions[bot]@users.noreply.github.com"
+          git config user.name "GitHub Actions"
+          git commit -m "Changelog"
+          git push
+        shell: bash