Skip to content

Commit d35c673

Browse files
committed
mihomo 内核和 sing-box 内核新增 UPX 压缩方式;删除 Clash Premium 内核
1 parent a303abd commit d35c673

4 files changed

Lines changed: 70 additions & 25 deletions

File tree

‎.github/workflows/update-adguardhome.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ jobs:
105105
done
106106
rm -rf ./tmp-beta*
107107
108-
- name: Setup `upx` and compress `AdGuard Home Beta` files
108+
- name: Setup `UPX` and compress `AdGuard Home Beta` files
109109
if: ${{ env.AdGuard_Home_Beta_skip_update != 'true' }}
110110
uses: crazy-max/ghaction-upx@v3
111111
with:

‎.github/workflows/update-mihomo.yml‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,13 @@ jobs:
5959
linux_new_name=(amd64v1 amd64v3 armv5 armv6 armv7 armv8 mips-softfloat mipsle-softfloat mipsle-hardfloat)
6060
for i in "${!linux_old_name[@]}"; do
6161
curl -L "${download_url}/${meta_version}/mihomo-linux-${linux_old_name[i]}-${meta_version}.gz" | gunzip -c > ./tmp-meta/CrashCore
62+
# Compress cores by `tar.gz`
6263
chmod +x ./tmp-meta/CrashCore
6364
tar --no-same-owner -czf "./mihomo/mihomo-meta-linux-${linux_new_name[i]}.tar.gz" -C ./tmp-meta/ CrashCore
65+
66+
# Ready for compress cores by `UPX`
67+
mv -f ./tmp-meta/CrashCore ./mihomo/mihomo-meta-linux-${linux_new_name[i]}.upx
68+
chmod +x ./mihomo/mihomo-meta-linux-${linux_new_name[i]}.upx
6469
done
6570
6671
# Windows
@@ -83,8 +88,13 @@ jobs:
8388
linux_new_name=(amd64v1 amd64v3 armv5 armv6 armv7 armv8 mips-softfloat mipsle-softfloat mipsle-hardfloat)
8489
for i in "${!linux_old_name[@]}"; do
8590
curl -L "${download_url}/Prerelease-Alpha/mihomo-linux-${linux_old_name[i]}-${alpha_version}.gz" | gunzip -c > ./tmp-alpha/CrashCore
91+
# Compress cores by `tar.gz`
8692
chmod +x ./tmp-alpha/CrashCore
8793
tar --no-same-owner -czf "./mihomo/mihomo-alpha-linux-${linux_new_name[i]}.tar.gz" -C ./tmp-alpha/ CrashCore
94+
95+
# Ready for compress cores by `UPX`
96+
mv -f ./tmp-alpha/CrashCore ./mihomo/mihomo-alpha-linux-${linux_new_name[i]}.upx
97+
chmod +x ./mihomo/mihomo-alpha-linux-${linux_new_name[i]}.upx
8898
done
8999
90100
# Windows
@@ -98,6 +108,13 @@ jobs:
98108
done
99109
rm -rf ./tmp-alpha*
100110
111+
- name: Setup `UPX` and compress `mihomo` files
112+
if: ${{ env.mihomo_Meta_skip_update != 'true' || env.mihomo_Alpha_skip_update != 'true' }}
113+
uses: crazy-max/ghaction-upx@v3
114+
with:
115+
version: latest
116+
files: ./mihomo/*.upx
117+
101118
- name: Check if `mihomo` files exist
102119
run: |
103120
if ls ./mihomo/* >/dev/null 2>&1; then

‎.github/workflows/update-singbox.yml‎

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -468,8 +468,13 @@ jobs:
468468
linux_new_name=(amd64v1 amd64v3 armv5 armv6 armv7 armv8 mips-softfloat mipsle-softfloat mipsle-hardfloat)
469469
for i in "${!linux_old_name[@]}"; do
470470
mv -f "./tmp/sing-box-ref1nd-main-linux-${linux_old_name[i]}/sing-box" ./tmp/CrashCore
471+
# Compress cores by `tar`
471472
chmod +x ./tmp/CrashCore
472473
tar --no-same-owner -czf "./sing-box/sing-box-ref1nd-main-linux-${linux_new_name[i]}.tar.gz" -C ./tmp/ CrashCore
474+
475+
# Ready for compress cores by `UPX`
476+
mv -f ./tmp/CrashCore ./sing-box/sing-box-ref1nd-main-linux-${linux_new_name[i]}.upx
477+
chmod +x ./sing-box/sing-box-ref1nd-main-linux-${linux_new_name[i]}.upx
473478
done
474479
475480
# Windows
@@ -488,8 +493,14 @@ jobs:
488493
linux_new_name=(amd64v1 amd64v3 armv5 armv6 armv7 armv8 mips-softfloat mipsle-softfloat mipsle-hardfloat)
489494
for i in "${!linux_old_name[@]}"; do
490495
mv -f "./tmp/sing-box-ref1nd-dev-linux-${linux_old_name[i]}/sing-box" ./tmp/CrashCore
496+
497+
# Compress cores by `tar`
491498
chmod +x ./tmp/CrashCore
492499
tar --no-same-owner -czf "./sing-box/sing-box-ref1nd-dev-linux-${linux_new_name[i]}.tar.gz" -C ./tmp/ CrashCore
500+
501+
# Ready for compress cores by `UPX`
502+
mv -f ./tmp/CrashCore ./sing-box/sing-box-ref1nd-dev-linux-${linux_new_name[i]}.upx
503+
chmod +x ./sing-box/sing-box-ref1nd-dev-linux-${linux_new_name[i]}.upx
493504
done
494505
495506
# Windows
@@ -508,8 +519,13 @@ jobs:
508519
linux_new_name=(amd64v1 amd64v3 armv5 armv6 armv7 armv8 mips-softfloat mipsle-softfloat mipsle-hardfloat)
509520
for i in "${!linux_old_name[@]}"; do
510521
mv -f "./tmp/sing-box-release-linux-${linux_old_name[i]}/sing-box" ./tmp/CrashCore
522+
# Compress cores by `tar`
511523
chmod +x ./tmp/CrashCore
512524
tar --no-same-owner -czf "./sing-box/sing-box-release-linux-${linux_new_name[i]}.tar.gz" -C ./tmp/ CrashCore
525+
526+
# Ready for compress cores by `UPX`
527+
mv -f ./tmp/CrashCore ./sing-box/sing-box-release-linux-${linux_new_name[i]}.upx
528+
chmod +x ./sing-box/sing-box-release-linux-${linux_new_name[i]}.upx
513529
done
514530
515531
# Windows
@@ -528,8 +544,13 @@ jobs:
528544
linux_new_name=(amd64v1 amd64v3 armv5 armv6 armv7 armv8 mips-softfloat mipsle-softfloat mipsle-hardfloat)
529545
for i in "${!linux_old_name[@]}"; do
530546
mv -f "./tmp/sing-box-dev-linux-${linux_old_name[i]}/sing-box" ./tmp/CrashCore
547+
# Compress cores by `tar`
531548
chmod +x ./tmp/CrashCore
532549
tar --no-same-owner -czf "./sing-box/sing-box-dev-linux-${linux_new_name[i]}.tar.gz" -C ./tmp/ CrashCore
550+
551+
# Ready for compress cores by `UPX`
552+
mv -f ./tmp/CrashCore ./sing-box/sing-box-dev-linux-${linux_new_name[i]}.upx
553+
chmod +x ./sing-box/sing-box-dev-linux-${linux_new_name[i]}.upx
533554
done
534555
535556
# Windows
@@ -539,6 +560,13 @@ jobs:
539560
mv -f "./tmp/sing-box-dev-windows-${windows_old_name[i]}/sing-box.exe" "./sing-box/sing-box-dev-windows-${windows_new_name[i]}.exe"
540561
done
541562
563+
- name: Setup `UPX` and compress `sing-box` files
564+
if: ${{ env.ref1nd_main_skip_update != 'true' || env.ref1nd_dev_skip_update != 'true' || env.singbox_release_skip_update != 'true' || env.singbox_dev_skip_update != 'true' }}
565+
uses: crazy-max/ghaction-upx@v3
566+
with:
567+
version: latest
568+
files: ./sing-box/*.upx
569+
542570
- name: Check if `sing-box` files exist
543571
id: check
544572
run: |

‎README.md‎

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
# 更新 [mihomo 内核](https://github.com/MetaCubeX/mihomo)[sing-box 内核](https://github.com/SagerNet/sing-box)[sing-box reF1nd 版内核](https://github.com/reF1nd/sing-box)、Dashboard 面板和 [AdGuard Home](https://github.com/AdguardTeam/AdGuardHome)
22
# 一、 说明
33
每天凌晨(北京时间 UTC+8)自动构建生成:
4-
1. [Clash Premium Release 版和 Nightly 版内核](https://github.com/DustinWin/proxy-tools/releases/tag/Clash-Premium)(已停更)
5-
2. mihomo [Meta 版](https://github.com/MetaCubeX/mihomo/tree/Meta)[Alpha 版](https://github.com/MetaCubeX/mihomo/tree/Alpha)内核
6-
3. sing-box [Release 版](https://github.com/SagerNet/sing-box/tree/main)[Dev 版](https://github.com/SagerNet/sing-box/tree/dev)[reF1nd-main 版](https://github.com/reF1nd/sing-box/tree/reF1nd-main)[reF1nd-dev 版](https://github.com/reF1nd/sing-box/tree/reF1nd-dev)(支持[提供者](https://sing-boxr.dustinwin.us.kg/zh/configuration/provider/) `providers`,类似于 mihomo 内核的[代理集合](https://wiki.metacubex.one/config/proxy-providers/) `proxy-providers`
7-
4. Dashboard 面板:[yacd 面板](https://github.com/haishanh/yacd)[Yacd-meta 面板](https://github.com/MetaCubeX/Yacd-meta)[metacubexd 面板](https://github.com/MetaCubeX/metacubexd)[zashboard 面板](https://github.com/Zephyruso/zashboard)
8-
5. AdGuard Home [Release 版](https://github.com/AdguardTeam/AdGuardHome/tree/beta-v0.107)[Beta 版](https://github.com/AdguardTeam/AdGuardHome/tree/beta-v0.108)
4+
1. mihomo [Meta 版](https://github.com/MetaCubeX/mihomo/tree/Meta)[Alpha 版](https://github.com/MetaCubeX/mihomo/tree/Alpha)内核
5+
2. sing-box [Release 版](https://github.com/SagerNet/sing-box/tree/main)[Dev 版](https://github.com/SagerNet/sing-box/tree/dev)[reF1nd-main 版](https://github.com/reF1nd/sing-box/tree/reF1nd-main)[reF1nd-dev 版](https://github.com/reF1nd/sing-box/tree/reF1nd-dev)(支持[提供者](https://sing-boxr.dustinwin.us.kg/zh/configuration/provider/) `providers`,类似于 mihomo 内核的[代理集合](https://wiki.metacubex.one/config/proxy-providers/) `proxy-providers`
6+
3. Dashboard 面板:[yacd 面板](https://github.com/haishanh/yacd)[Yacd-meta 面板](https://github.com/MetaCubeX/Yacd-meta)[metacubexd 面板](https://github.com/MetaCubeX/metacubexd)[zashboard 面板](https://github.com/Zephyruso/zashboard)
7+
4. AdGuard Home [Release 版](https://github.com/AdguardTeam/AdGuardHome/tree/beta-v0.107)[Beta 版](https://github.com/AdguardTeam/AdGuardHome/tree/beta-v0.108)
98

109
**注:**
1110
- 1. 本教程中的下载链接以 CPU 架构 ARMv8 为例,请注意修改链接后缀
1211
- 2. 查看 CPU 架构可连接 SSH 后执行命令 `uname -ms`,若执行结果是“linux aarch64”,就是搭载的 ARMv8 架构
13-
- 3. 对下载源的说明,可[点此](https://proxy-tutorials.dustinwin.us.kg/about/#%E5%AF%B9%E4%B8%8B%E8%BD%BD%E6%BA%90%E7%9A%84%E8%AF%B4%E6%98%8E)了解
12+
- 3. 本项目中 mihomo 内核和 sing-box 内核分别采用 `tar.gz`[UPX](https://github.com/upx/upx) 两种压缩方式(以下内容都以 UPX 压缩方式为例)
13+
- 4. 对下载源的说明,可[点此](https://proxy-tutorials.dustinwin.us.kg/about/#%E5%AF%B9%E4%B8%8B%E8%BD%BD%E6%BA%90%E7%9A%84%E8%AF%B4%E6%98%8E)了解
1414

1515
# 二、 使用方法
1616
## 1. 导入内核(以 [ShellCrash](https://github.com/juewuy/ShellCrash) 导入内核为例)
@@ -30,37 +30,37 @@
3030
连接 SSH 后执行如下命令:
3131
```shell
3232
# mihomo 内核 Meta 版
33-
curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-meta-linux-armv8.tar.gz | tar -zx -C /tmp/ && sc
33+
curl -o /tmp/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-meta-linux-armv8.upx && sc
3434
# mihomo 内核 Alpha 版
35-
curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-alpha-linux-armv8.tar.gz | tar -zx -C /tmp/ && sc
35+
curl -o /tmp/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-alpha-linux-armv8.upx && sc
3636
# sing-box 内核 reF1nd-main 版
37-
curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-main-linux-armv8.tar.gz | tar -zx -C /tmp/ && sc
37+
curl -o /tmp/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-main-linux-armv8.upx && sc
3838
# sing-box 内核 reF1nd-dev 版
39-
curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-dev-linux-armv8.tar.gz | tar -zx -C /tmp/ && sc
39+
curl -o /tmp/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-dev-linux-armv8.upx && sc
4040
# sing-box 内核 Release 版
41-
curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-release-linux-armv8.tar.gz | tar -zx -C /tmp/ && sc
41+
curl -o /tmp/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-release-linux-armv8.upx && sc
4242
# sing-box 内核 Dev 版
43-
curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-dev-linux-armv8.tar.gz | tar -zx -C /tmp/ && sc
43+
curl -o /tmp/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-dev-linux-armv8.upx && sc
4444
```
4545
此时脚本会自动“发现可用的内核文件”,选择 1 加载,后选择对应的内核
4646
</details>
4747
<details>
48-
<summary>② 升级导入(ShellCrash -> 9 更新/卸载 -> 2 切换内核文件,内核版本不会刷新)</summary>
48+
<summary>② 升级导入(ShellCrash 9 更新/卸载 2 切换内核文件,内核版本不会刷新)</summary>
4949

5050
连接 SSH 后执行如下命令:
5151
```shell
5252
# mihomo 内核 Meta 版
53-
curl -o $CRASHDIR/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-meta-linux-armv8.tar.gz && $CRASHDIR/start.sh restart
53+
curl -o $CRASHDIR/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-meta-linux-armv8.upx && $CRASHDIR/start.sh restart
5454
# mihomo 内核 Alpha 版
55-
curl -o $CRASHDIR/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-alpha-linux-armv8.tar.gz && $CRASHDIR/start.sh restart
55+
curl -o $CRASHDIR/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-alpha-linux-armv8.upx && $CRASHDIR/start.sh restart
5656
# sing-box 内核 reF1nd-main 版
57-
curl -o $CRASHDIR/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-main-linux-armv8.tar.gz && $CRASHDIR/start.sh restart
57+
curl -o $CRASHDIR/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-main-linux-armv8.upx && $CRASHDIR/start.sh restart
5858
# sing-box 内核 reF1nd-dev 版
59-
curl -o $CRASHDIR/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-dev-linux-armv8.tar.gz && $CRASHDIR/start.sh restart
59+
curl -o $CRASHDIR/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-dev-linux-armv8.upx && $CRASHDIR/start.sh restart
6060
# sing-box 内核 Release 版
61-
curl -o $CRASHDIR/CrashCore.tar.gz -L https://cdn.jsdelivr.net/gh/DustinWin/proxy-tools/@sing-box/sing-box-release-linux-armv8.tar.gz && $CRASHDIR/start.sh restart
61+
curl -o $CRASHDIR/CrashCore.upx -L https://cdn.jsdelivr.net/gh/DustinWin/proxy-tools/@sing-box/sing-box-release-linux-armv8.upx && $CRASHDIR/start.sh restart
6262
# sing-box 内核 Dev 版
63-
curl -o $CRASHDIR/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-dev-linux-armv8.tar.gz && $CRASHDIR/start.sh restart
63+
curl -o $CRASHDIR/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-dev-linux-armv8.upx && $CRASHDIR/start.sh restart
6464
```
6565
</details>
6666

@@ -78,7 +78,7 @@ curl -o $CRASHDIR/CrashCore.tar.gz -L https://ghfast.top/https://github.com/Dust
7878
curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/Dashboard/zashboard.tar.gz | tar -zx -C $CRASHDIR/ui/ && $CRASHDIR/start.sh restart
7979
```
8080
- 注:若使用基于 [Chromium 项目](https://www.chromium.org/Home/)开发的浏览器打开网址去访问 Dashboard 面板时,以 [Chrome 浏览器](https://www.google.com/chrome/)为例,需要设置该网址域名“允许显示不安全内容”。方法如下:
81-
进入设置 -> 隐私和安全 -> 网站设置 -> 更多内容设置 -> 不安全内容(或者地址栏直接打开 chrome://settings/content/insecureContent 进行设置),在“允许显示不安全内容”内添加网址域名如:`board.zash.run.place`
81+
进入设置 隐私和安全 网站设置 更多内容设置 不安全内容(或者地址栏直接打开 chrome://settings/content/insecureContent 进行设置),在“允许显示不安全内容”内添加网址域名如:`board.zash.run.place`
8282

8383
## 3. 安装 AdGuard Home
8484
**AdGuard Home Linux 版 CPU 架构和链接后缀对应关系如下表:**
@@ -139,14 +139,14 @@ curl -o /data/AdGuardHome/AdGuardHome -L https://ghgo.xyz/https://github.com/Dus
139139
- 3. 须重启 ShellCrash 和 AdGuard Home 服务后生效
140140

141141
```shell
142-
201#curl -o /data/ShellCrash/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-meta-linux-armv8.tar.gz >/dev/null 2>&1#更新mihomo内核
143-
202#curl -o /data/ShellCrash/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-main-linux-armv8.tar.gz >/dev/null 2>&1#更新sing-boxr内核
144-
203#curl -o /data/ShellCrash/CrashCore.tar.gz -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-release-linux-armv8.tar.gz >/dev/null 2>&1#更新sing-box内核
142+
201#curl -o /data/ShellCrash/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/mihomo/mihomo-meta-linux-armv8.upx >/dev/null 2>&1#更新mihomo内核
143+
202#curl -o /data/ShellCrash/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-ref1nd-main-linux-armv8.upx >/dev/null 2>&1#更新sing-boxr内核
144+
203#curl -o /data/ShellCrash/CrashCore.upx -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/sing-box/sing-box-release-linux-armv8.upx >/dev/null 2>&1#更新sing-box内核
145145
204#curl -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/Dashboard/zashboard.tar.gz | tar -zx -C $CRASHDIR/ui/ >/dev/null 2>&1#更新zashboard面板
146146
205#curl -o /data/AdGuardHome/AdGuardHome -L https://ghfast.top/https://github.com/DustinWin/proxy-tools/releases/download/AdGuardHome/AdGuardHome_beta_linux_armv8 >/dev/null 2>&1#更新AdGuardHome
147147
```
148148
2. 按一下 Esc 键(退出键),输入英文冒号 `:`,继续输入 `wq` 并回车
149-
3. 执行 `sc`,进入 ShellCrash -> 5 配置自动任务 -> 1 添加自动任务,可以看到末尾就有添加的定时任务,输入对应的数字并回车后可设置执行条件
149+
3. 执行 `sc`,进入 ShellCrash 5 配置自动任务 1 添加自动任务,可以看到末尾就有添加的定时任务,输入对应的数字并回车后可设置执行条件
150150

151151
# 给作者加鸡腿
152152
<img src="https://github.com/user-attachments/assets/e640fdf6-0990-421f-8ec6-2d263b533b89" alt="支付宝" width="30%" />

0 commit comments

Comments
 (0)