forked from BrainPix/BrainPix-front
-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (33 loc) · 999 Bytes
/
sync-to-fork.yml
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
38
39
name: Sync Fork With Upstream
on:
push:
branches:
- main
- develop
jobs:
sync:
if: github.repository == 'BrainPix-front'
runs-on: ubuntu-latest
steps:
- name: Checkout develop
uses: actions/checkout@v3
with:
token: ${{secrets.PAT_TOKEN}}
ref: develop
persition-credentials: false
- name: Set up Git
run: |
git config user.name minejeong9919
git config user.email "[email protected]"
- name: Add remote-url
run: |
git remote add forked-repo https://github.com/minjeong9919/BrainPix-front.git
- name: Push changes to Forked-reop
env:
GITHUB_USERNAME: minjeong9919
GITHUB_TOKEN: ${{secrets.PAT_TOKEN}}
run: |
git push -f http://$GITHUB_USERNAME:$GITHUB_TOKEN@https://github.com/minjeong9919/BrainPix-front.git develop
- name: Clean up
run: |
git remote remove forked-repo