Skip to content

Commit 751c81e

Browse files
authored
Create repo-sync.yml
creating sync
1 parent 91c8442 commit 751c81e

1 file changed

Lines changed: 30 additions & 0 deletions

File tree

.github/workflows/repo-sync.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Repo Sync
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
repo-sync:
8+
name: Repo Sync
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v3
12+
- uses: repo-sync/github-sync@v2
13+
name: Sync repo to branch
14+
with:
15+
source_repo: ${{ secrets.SOURCE_REPO }}
16+
source_branch: main
17+
destination_branch: ${{ secrets.INTERMEDIATE_BRANCH }}
18+
github_token: ${{ secrets.REPO_SYNC }}
19+
skip_if_no_changes: true
20+
- name: Print workflow inputs
21+
run: |
22+
echo "source_repo: ${{ inputs.source_repo }}"
23+
echo "destination_repository: ${{ inputs.destination_repository }}"
24+
- uses: repo-sync/pull-request@v2
25+
name: Create pull request
26+
with:
27+
source_branch: ${{ secrets.INTERMEDIATE_BRANCH }}
28+
destination_repository: ${{ secrets.DESTINATION_REPOSITORY }}
29+
destination_branch: main
30+
github_token: ${{ secrets.REPO_SYNC }}

0 commit comments

Comments
 (0)