forked from OSC/ood-documentation
-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (31 loc) · 830 Bytes
/
sync.yml
File metadata and controls
37 lines (31 loc) · 830 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Sync develop
on:
push:
branches: [latest]
defaults:
run:
shell: bash
jobs:
sync:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v3
with:
token: ${{ secrets.OSC_ROBOT_GH_PUB_REPO_TOKEN }}
fetch-depth: 0
- name: Merge Branches
run: |
git config --global user.name ${{ secrets.OSC_ROBOT_GH_USER }}
git config --global user.email ${{ secrets.OSC_ROBOT_GH_USER_EMAIL }}
git fetch
git checkout latest
git pull
git checkout develop
git pull
git merge latest
# note that this shouldn't run if 'merge branches' fails, which it will happen when
# there are merge conflicts.
- name: Sync develop
run: |
git push