Update automated update PR workflows and filter release notes

This commit is contained in:
Chris Titus
2026-07-16 13:39:33 -05:00
parent 06f33e88ba
commit 5c104d02e2
3 changed files with 19 additions and 4 deletions
+2 -2
View File
@@ -1,4 +1,4 @@
name: Auto-merge Docs PRs
name: Auto-merge Automated Update PRs
on:
pull_request:
@@ -8,7 +8,7 @@ on:
jobs:
auto-merge:
if: github.event.pull_request.head.ref == 'docs-update' && (github.event.pull_request.user.login == 'ChrisTitusTech' || github.event.pull_request.user.login == 'github-actions[bot]')
if: (github.event.pull_request.head.ref == 'docs-update' || github.event.pull_request.head.ref == 'sponsors-update') && (github.event.pull_request.user.login == 'ChrisTitusTech' || github.event.pull_request.user.login == 'github-actions[bot]')
runs-on: ubuntu-latest
permissions:
pull-requests: write
+16 -1
View File
@@ -109,6 +109,21 @@ jobs:
config-name: release-drafter.yml
version: ${{ env.VERSION }}
- name: Remove Automated Updates from Release Notes
id: filter_notes
shell: pwsh
env:
RELEASE_NOTES: ${{ steps.generate_notes.outputs.body }}
run: |
$filteredNotes = ($env:RELEASE_NOTES -split '\r?\n' | Where-Object {
$_ -notmatch '(?i)Update (Generated Dev Docs|Sponsors)'
}) -join "`n"
$delimiter = [guid]::NewGuid().ToString()
"body<<$delimiter" >> $env:GITHUB_OUTPUT
$filteredNotes >> $env:GITHUB_OUTPUT
$delimiter >> $env:GITHUB_OUTPUT
- name: Create and Upload Release
id: create_release
uses: softprops/action-gh-release@v3
@@ -116,7 +131,7 @@ jobs:
tag_name: ${{ env.VERSION }}
name: Pre-Release ${{ env.VERSION }}
body: |
${{ steps.generate_notes.outputs.body }}
${{ steps.filter_notes.outputs.body }}
![GitHub Downloads (specific asset, specific tag)](https://img.shields.io/github/downloads/ChrisTitusTech/winutil/${{ env.VERSION }}/winutil.ps1)
append_body: false
+1 -1
View File
@@ -26,7 +26,7 @@ jobs:
id: cpr
uses: peter-evans/create-pull-request@v8
with:
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.AUTO_MERGE }}
commit-message: 'Update sponsors in README'
title: 'chore: Update Sponsors README'
body: 'Automated update of sponsors section'