-
Notifications
You must be signed in to change notification settings - Fork 0
145 lines (127 loc) · 5.61 KB
/
sync.yml
File metadata and controls
145 lines (127 loc) · 5.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
name: Sync Git Repo
on:
push:
workflow_dispatch:
schedule:
- cron: '30 19 */2 * *'
jobs:
sync:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
REPO_URL:
# Already dead repo
# - 'https://github.com/lvguanjun/copilot_share.git'
# - 'https://github.com/pandora-next/deploy.git'
# - 'https://github.com/3Kmfi6HP/EDtunnel.git'
# - 'https://github.com/DiamondHunters/NodeInject_Hook_example.git'
- 'https://github.com/DiamondHunters/NodeInject.git'
- 'https://github.com/tornadocash/tornado-core.git'
- 'https://github.com/tornadocash/tornado-cli.git'
- 'https://github.com/tornadocash/ui-minified.git'
- 'https://github.com/tornadocash/tornado-relayer.git'
- 'https://github.com/tornadocash/tornado-anonymity-mining.git'
- 'https://github.com/tornadocash/torn-token.git'
# Maybe dead until now, since 2025-08-24 ~ 2025-08-26.
# - 'https://git.unlock-music.dev/um/web.git'
# - 'https://git.unlock-music.dev/um/cli.git'
# - 'https://git.unlock-music.dev/um/um-react.git'
# - 'https://git.unlock-music.dev/um/go-mmkv.git'
# - 'https://git.unlock-music.dev/um/um-react-wry.git'
# - 'https://git.unlock-music.dev/um/kgg-dec.git'
# - 'https://git.unlock-music.dev/um/lib_um_crypto_rust.git'
# - 'https://git.unlock-music.dev/um/joox-crypto.git'
- 'https://github.com/spencerwooo/onedrive-vercel-index.git'
- 'https://github.com/2dust/v2rayN.git'
- 'https://github.com/2dust/v2rayNG.git'
- 'https://github.com/2dust/clashN.git'
- 'https://github.com/v2ray/v2ray-core.git'
- 'https://github.com/macronut/phantomsocks.git'
- 'https://github.com/macronut/ghostcp.git'
- 'https://github.com/macronut/godivert.git'
- 'https://github.com/macronut/magisk-module-phantomsocks.git'
- 'https://github.com/zizifn/edgetunnel.git'
- 'https://github.com/Grasscutters/Grasscutter.git'
- 'https://github.com/LSPosed/MagiskOnWSALocal.git'
- 'https://github.com/iperov/DeepFaceLab.git'
- 'https://github.com/deepfakes/faceswap.git'
- 'https://github.com/SeaHOH/GotoX.git'
- 'https://github.com/moesnow/March7thAssistant.git'
- 'https://github.com/x-dr/telegraph-Image.git'
- 'https://github.com/SpaceTimee/Bot-CealingCat.git'
- 'https://github.com/SpaceTimee/Cealing-Host.git'
- 'https://github.com/SpaceTimee/Console-HostGenerator.git'
- 'https://github.com/SpaceTimee/Ona-Dop.git'
- 'https://github.com/SpaceTimee/Ona-Pix.git'
- 'https://github.com/SpaceTimee/Ona-Prox.git'
- 'https://github.com/SpaceTimee/Sheas-Cealer.git'
- 'https://github.com/SpaceTimee/Sheas-Dop.git'
- 'https://github.com/SpaceTimee/Sheas-Nginx.git'
- 'https://github.com/SpotX-Official/SpotX.git'
- 'https://github.com/SpotX-Official/SpotX-Bash.git'
- 'https://github.com/ikunshare/Onekey.git'
- 'https://github.com/guozhigq/pilipala.git'
include:
# - REPO_URL: 'https://git.unlock-music.dev/um/web.git'
# GITLAB_REPO: 'web_v2'
# - REPO_URL: 'https://git.unlock-music.dev/um/lib_um_crypto_rust.git'
# GITLAB_REPO: 'lib_um_crypto_rust_v2'
- REPO_URL: 'https://github.com/SpaceTimee/Cealing-Host.git'
GITLAB_REPO: 'Cealing-Host_v5'
- REPO_URL: 'https://github.com/SpaceTimee/Sheas-Cealer.git'
GITLAB_REPO: 'Sheas-Cealer_v2'
steps:
- name: Clone git repository
run: |
git clone --mirror ${{ matrix.REPO_URL }}
- name: Push to remote
env:
GITLAB_USERNAME: ${{ secrets.GITLAB_USERNAME }}
GITLAB_USERMAIL: ${{ secrets.GITLAB_USERMAIL }}
GITLAB_PASSWORD: ${{ secrets.GITLAB_PASSWORD }}
run: |
export REPO_NAME=$(basename "${{ matrix.REPO_URL }}" .git)
export GITLAB_REPO=${{ matrix.GITLAB_REPO }}
# IF GITLAB_REPO is not given, use default path
if [ -z "$GITLAB_REPO" ]; then
GITLAB_REPO="$REPO_NAME"
fi
cd $REPO_NAME.git
git config user.name $GITLAB_USERNAME
git config user.email $GITLAB_USERMAIL
git remote add gitlab https://$GITLAB_USERNAME:$GITLAB_PASSWORD@gitlab.com/mirrors_git/$GITLAB_REPO.git
git push gitlab --all
visiable:
needs: sync
if: always()
runs-on: ubuntu-latest
steps:
- name: Change Project Visiable
env:
GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }}
run: |
TOKEN="$GITLAB_TOKEN"
GITLAB_URL="https://gitlab.com"
GROUP_ID="77318098"
# Get the ID of all Projects in the Group
project_ids=$(curl --header "PRIVATE-TOKEN: $TOKEN" "$GITLAB_URL/api/v4/groups/$GROUP_ID/projects" | jq '.[].id')
for id in $project_ids
do
curl --request PUT --header "PRIVATE-TOKEN: $TOKEN" "$GITLAB_URL/api/v4/projects/$id?visibility=public"
done
clean:
needs: sync
if: always()
runs-on: ubuntu-latest
permissions:
actions: write
contents: read
steps:
- name: Delete workflow runs
uses: Mattraks/delete-workflow-runs@v2
with:
token: ${{ github.token }}
repository: ${{ github.repository }}
retain_days: 30
keep_minimum_runs: 6