File tree Expand file tree Collapse file tree 1 file changed +16
-11
lines changed Expand file tree Collapse file tree 1 file changed +16
-11
lines changed Original file line number Diff line number Diff line change @@ -14,17 +14,22 @@ A GitHub Action for syncing between two independent repositories using **force p
1414
1515### Github Actions
1616```
17- action "repo-sync" {
18- uses = "wei/git-sync@master"
19- args = "$SOURCE_REPO $SOURCE_BRANCH $DESTINATION_REPO $DESTINATION_BRANCH"
20- env = {
21- SOURCE_REPO = ""
22- SOURCE_BRANCH = ""
23- DESTINATION_REPO = ""
24- DESTINATION_BRANCH = ""
25- }
26- secrets = ["SSH_PRIVATE_KEY"]
27- }
17+ # File: .github/workflows/repo-sync.yml
18+
19+ on: push
20+ jobs:
21+ repo-sync:
22+ runs-on: ubuntu-latest
23+ steps:
24+ - name: repo-sync
25+ uses: wei/git-sync@master
26+ env:
27+ SOURCE_REPO: ""
28+ SOURCE_BRANCH: ""
29+ DESTINATION_REPO: ""
30+ DESTINATION_BRANCH: ""
31+ SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
32+ args: $SOURCE_REPO $SOURCE_BRANCH $DESTINATION_REPO $DESTINATION_BRANCH
2833```
2934` SSH_PRIVATE_KEY ` can be omitted if using authenticated HTTPS repo clone urls like ` https://username:access_token@github.com/username/repository.git ` .
3035
You can’t perform that action at this time.
0 commit comments