26 lines
816 B
YAML
26 lines
816 B
YAML
name: SyncEntireRepo
|
|
on:
|
|
schedule:
|
|
- cron: "0 * * * *" # 每小时执行一次
|
|
|
|
jobs:
|
|
sync_repo:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Configure Git
|
|
run: |
|
|
git config --global user.name "yuanzhen869"
|
|
git config --global user.email "yuanzhen869@gmail.com"
|
|
|
|
- name: Clone GitHub repository
|
|
run: |
|
|
git clone --mirror https://github.com/blackmatrix7/ios_rule_script.git repo_sync # 替换为GitHub仓库URL
|
|
cd repo_sync
|
|
git remote add gitea https://git.halonice.com/yuanzhen869/bypass.git # 替换为Gitea仓库URL
|
|
git fetch -p origin
|
|
git push -f gitea --all # 推送所有分支
|
|
git push -f gitea --tags # 推送所有标签
|
|
|
|
- name: Clean up
|
|
run: |
|
|
rm -rf repo_sync |