git-sync.yaml 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. name: git-sync-with-mirror
  2. on:
  3. push:
  4. branches: [ master ]
  5. workflow_dispatch:
  6. jobs:
  7. git-sync:
  8. runs-on: ubuntu-latest
  9. steps:
  10. - name: git-sync
  11. env:
  12. git_sync_source_repo: git@git.fridu.us:heckyel/yt-local.git
  13. git_sync_destination_repo: ssh://git@c.fridu.us/software/yt-local.git
  14. if: env.git_sync_source_repo && env.git_sync_destination_repo
  15. uses: astounds/git-sync@v1
  16. with:
  17. source_repo: git@git.fridu.us:heckyel/yt-local.git
  18. source_branch: "master"
  19. destination_repo: ssh://git@c.fridu.us/software/yt-local.git
  20. destination_branch: "master"
  21. source_ssh_private_key: ${{ secrets.GIT_SYNC_SOURCE_SSH_PRIVATE_KEY }}
  22. destination_ssh_private_key: ${{ secrets.GIT_SYNC_DESTINATION_SSH_PRIVATE_KEY }}
  23. - name: git-sync-sourcehut
  24. env:
  25. git_sync_source_repo: git@git.fridu.us:heckyel/yt-local.git
  26. git_sync_destination_repo: git@git.sr.ht:~heckyel/yt-local
  27. if: env.git_sync_source_repo && env.git_sync_destination_repo
  28. uses: astounds/git-sync@v1
  29. with:
  30. source_repo: git@git.fridu.us:heckyel/yt-local.git
  31. source_branch: "master"
  32. destination_repo: git@git.sr.ht:~heckyel/yt-local
  33. destination_branch: "master"
  34. source_ssh_private_key: ${{ secrets.GIT_SYNC_SOURCE_SSH_PRIVATE_KEY }}
  35. destination_ssh_private_key: ${{ secrets.GIT_SYNC_DESTINATION_SSH_PRIVATE_KEY }}
  36. continue-on-error: true