Skip to content

Commit 49c6118

Browse files
committed
Add workflow to fast-forward dev after merge to main
1 parent 49568ce commit 49c6118

1 file changed

Lines changed: 25 additions & 0 deletions

File tree

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Sync dev with main
2+
3+
on:
4+
pull_request:
5+
types: [closed]
6+
branches: [main]
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
fast-forward-dev:
13+
if: github.event.pull_request.merged == true && github.event.pull_request.head.ref == 'dev'
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v4
17+
with:
18+
ref: dev
19+
fetch-depth: 0
20+
21+
- name: Fast-forward dev to main
22+
run: |
23+
git fetch origin main
24+
git merge --ff-only origin/main
25+
git push origin dev

0 commit comments

Comments
 (0)