|
45 | 45 | required: false |
46 | 46 | type: boolean |
47 | 47 | default: true |
| 48 | + committer: |
| 49 | + description: > |
| 50 | + The committer name and email address in the format `Display Name <email@address.com>`. |
| 51 | + Defaults to the GitHub Actions bot user. |
| 52 | + required: false |
| 53 | + type: string |
| 54 | + default: '' |
| 55 | + author: |
| 56 | + description: > |
| 57 | + The committer name and email address in the format `Display Name <email@address.com>`. |
| 58 | + Defaults to the user who triggered the workflow run. |
| 59 | + required: false |
| 60 | + type: string |
| 61 | + default: '' |
48 | 62 |
|
49 | 63 | secrets: |
50 | 64 | repository_token: |
@@ -193,7 +207,78 @@ jobs: |
193 | 207 | if: steps.check_grumphp.outputs.files_exists == 'true' |
194 | 208 | run: vendor/bin/grumphp git:deinit |
195 | 209 |
|
196 | | - - name: Create a pull request |
| 210 | + - name: Create a pull request with committer and author |
| 211 | + if: ${{ inputs.committer != '' && inputs.author != '' }} |
| 212 | + uses: peter-evans/create-pull-request@v6 |
| 213 | + id: cpr |
| 214 | + with: |
| 215 | + token: ${{ secrets.repository_token }} |
| 216 | + commit-message: | |
| 217 | + Update modules |
| 218 | +
|
| 219 | + ${{ steps.composer-update.outputs.commit_body }} |
| 220 | + signoff: false |
| 221 | + branch: hotfix/${{ steps.semvers.outputs.patch }} |
| 222 | + base: ${{ inputs.branch }} |
| 223 | + delete-branch: false |
| 224 | + title: Update modules |
| 225 | + body: | |
| 226 | + ${{ steps.composer-update.outputs.commit_body }} |
| 227 | + labels: | |
| 228 | + updates |
| 229 | + automated pr |
| 230 | + draft: true |
| 231 | + committer: ${{ inputs.committer }} |
| 232 | + author: ${{ inputs.author }} |
| 233 | + |
| 234 | + - name: Create a pull request with only committer |
| 235 | + if: ${{ inputs.committer != '' && inputs.author == '' }} |
| 236 | + uses: peter-evans/create-pull-request@v6 |
| 237 | + id: cpr |
| 238 | + with: |
| 239 | + token: ${{ secrets.repository_token }} |
| 240 | + commit-message: | |
| 241 | + Update modules |
| 242 | +
|
| 243 | + ${{ steps.composer-update.outputs.commit_body }} |
| 244 | + signoff: false |
| 245 | + branch: hotfix/${{ steps.semvers.outputs.patch }} |
| 246 | + base: ${{ inputs.branch }} |
| 247 | + delete-branch: false |
| 248 | + title: Update modules |
| 249 | + body: | |
| 250 | + ${{ steps.composer-update.outputs.commit_body }} |
| 251 | + labels: | |
| 252 | + updates |
| 253 | + automated pr |
| 254 | + draft: true |
| 255 | + committer: ${{ inputs.committer }} |
| 256 | + |
| 257 | + - name: Create a pull request with only author |
| 258 | + if: ${{ inputs.committer == '' && inputs.author != '' }} |
| 259 | + uses: peter-evans/create-pull-request@v6 |
| 260 | + id: cpr |
| 261 | + with: |
| 262 | + token: ${{ secrets.repository_token }} |
| 263 | + commit-message: | |
| 264 | + Update modules |
| 265 | +
|
| 266 | + ${{ steps.composer-update.outputs.commit_body }} |
| 267 | + signoff: false |
| 268 | + branch: hotfix/${{ steps.semvers.outputs.patch }} |
| 269 | + base: ${{ inputs.branch }} |
| 270 | + delete-branch: false |
| 271 | + title: Update modules |
| 272 | + body: | |
| 273 | + ${{ steps.composer-update.outputs.commit_body }} |
| 274 | + labels: | |
| 275 | + updates |
| 276 | + automated pr |
| 277 | + draft: true |
| 278 | + author: ${{ inputs.author }} |
| 279 | + |
| 280 | + - name: Create a pull request with default committer and author |
| 281 | + if: ${{ inputs.committer == '' && inputs.author == '' }} |
197 | 282 | uses: peter-evans/create-pull-request@v6 |
198 | 283 | id: cpr |
199 | 284 | with: |
|
0 commit comments