Skip to content

Commit

Permalink
ci: add fast-forward merge action to pull requests (#42)
Browse files Browse the repository at this point in the history
  • Loading branch information
premsrii committed Jan 16, 2023
1 parent d2a4fbf commit 41036b9
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/fast-forward-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: FastForwardPR

on:
issue_comment:
types: [created]

jobs:
fast_forward_job:
name: Fast Forward
if: github.event.issue.pull_request != '' && contains(github.event.comment.body, '/fast-forward')
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Fast Forward PR
id: ff-action
uses: endre-spotlab/fast-forward-js-action@2.1
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
success_message: 'Success! Fast forwarded ***target_base*** to ***source_head***! ```git checkout target_base && git merge source_head --ff-only``` '
failure_message: 'Failed! Cannot do fast forward!'
production_branch: 'main'
staging_branch: 'develop'

0 comments on commit 41036b9

Please sign in to comment.