diff --git a/.github/workflows/cnb.yml b/.github/workflows/cnb.yml new file mode 100644 index 000000000..b7d67bcc3 --- /dev/null +++ b/.github/workflows/cnb.yml @@ -0,0 +1,18 @@ +name: cnb.yml + +on: + push + +jobs: + run: + if: ${{ github.repository == 'HMCL-dev/HMCL' }} + runs-on: ubuntu-latest + steps: + - name: Mirror GitHub to CNB + env: + SOURCE_REPO: HMCL-dev/HMCL + TARGET_REPO: HMCL-dev/HMCL + run: | + git clone --mirror "https://github.com/$SOURCE_REPO.git" -- repo + cd repo + git push --mirror "https://${{ secrets.CNB_SYNC_USERNAME }}:${{ secrets.CNB_SYNC_TOKEN }}@cnb.cool/$TARGET_REPO.git"