Sync to Gitee #1178
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Sync to Gitee | |
| on: | |
| workflow_dispatch: | |
| schedule: | |
| - cron: '45 6 * * *' | |
| push: | |
| paths-ignore: | |
| - 'scripts/ReadMeTemplate.java' | |
| jobs: | |
| run: | |
| if: ${{ github.repository_owner == 'HMCL-dev' }} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Sync to Gitee | |
| run: | | |
| mkdir -p ~/gitee/.ssh | |
| echo "$INPUT_SSH_PRIVATE_KEY" > ~/gitee/.ssh/id_rsa | |
| chmod 600 ~/gitee/.ssh/id_rsa | |
| export GIT_SSH_COMMAND="ssh -v -i ~/gitee/.ssh/id_rsa -o StrictHostKeyChecking=no -F /dev/null" | |
| git push --mirror "$INPUT_TARGET_REPO_URL" | |
| env: | |
| INPUT_SSH_PRIVATE_KEY: | |
| ${{ secrets.GITEE_SYNC_BOT_PRIVATE_KEY }} | |
| INPUT_TARGET_REPO_URL: | |
| [email protected]:Glavo/HMCL-Update.git |