rebase-command #825
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Rebase | |
on: | |
repository_dispatch: | |
types: | |
- rebase-command | |
jobs: | |
rebase: | |
name: Rebase | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
persist-credentials: false | |
- name: Automatic rebase | |
uses: giorio94/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.CI_TOKEN }} | |
- name: Set the reaction for the comment | |
id: rebase_reaction | |
run: | | |
[[ ${{ job.status }} == 'success' ]] && \ | |
echo "reaction=hooray" >> $GITHUB_OUTPUT || \ | |
echo "reaction::confused" >> $GITHUB_OUTPUT | |
if: always() | |
- name: Report status as reaction | |
uses: peter-evans/create-or-update-comment@v2 | |
with: | |
token: ${{ secrets.CI_TOKEN }} | |
comment-id: ${{ github.event.client_payload.github.payload.comment.id }} | |
reactions: '${{ steps.rebase_reaction.outputs.reaction }}' | |
if: always() |