File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- name : Auto-merge Docs PRs
1+ name : Auto-merge Automated Update PRs
22
33on :
44 pull_request :
88
99jobs :
1010 auto-merge :
11- 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]')
11+ 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]')
1212 runs-on : ubuntu-latest
1313 permissions :
1414 pull-requests : write
Original file line number Diff line number Diff line change @@ -109,14 +109,29 @@ jobs:
109109 config-name : release-drafter.yml
110110 version : ${{ env.VERSION }}
111111
112+ - name : Remove Automated Updates from Release Notes
113+ id : filter_notes
114+ shell : pwsh
115+ env :
116+ RELEASE_NOTES : ${{ steps.generate_notes.outputs.body }}
117+ run : |
118+ $filteredNotes = ($env:RELEASE_NOTES -split '\r?\n' | Where-Object {
119+ $_ -notmatch '(?i)Update (Generated Dev Docs|Sponsors)'
120+ }) -join "`n"
121+
122+ $delimiter = [guid]::NewGuid().ToString()
123+ "body<<$delimiter" >> $env:GITHUB_OUTPUT
124+ $filteredNotes >> $env:GITHUB_OUTPUT
125+ $delimiter >> $env:GITHUB_OUTPUT
126+
112127 - name : Create and Upload Release
113128 id : create_release
114129 uses : softprops/action-gh-release@v3
115130 with :
116131 tag_name : ${{ env.VERSION }}
117132 name : Pre-Release ${{ env.VERSION }}
118133 body : |
119- ${{ steps.generate_notes .outputs.body }}
134+ ${{ steps.filter_notes .outputs.body }}
120135
121136 
122137 append_body : false
Original file line number Diff line number Diff line change 2626 id : cpr
2727 uses : peter-evans/create-pull-request@v8
2828 with :
29- token : ${{ secrets.GITHUB_TOKEN }}
29+ token : ${{ secrets.AUTO_MERGE }}
3030 commit-message : ' Update sponsors in README'
3131 title : ' chore: Update Sponsors README'
3232 body : ' Automated update of sponsors section'
You can’t perform that action at this time.
0 commit comments