Skip to content

Commit e8ff229

Browse files
committed
Merge branch 'dev'
2 parents cf82ec7 + 3618c9c commit e8ff229

16 files changed

Lines changed: 147 additions & 124 deletions

File tree

.github/workflows/clear_cache.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
runs-on: ubuntu-latest
1919

2020
steps:
21-
- uses: actions/checkout@v3
21+
- uses: actions/checkout@v4
2222

2323
# https://github.com/marketplace/actions/git-changesets
2424
- id: changed_files

.github/workflows/compile_dev_core.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
sudo apt-get -y install git
2222
2323
- name: Clone OpenClash Repository
24-
uses: actions/checkout@v3
24+
uses: actions/checkout@v4
2525
with:
2626
ref: core
2727

@@ -32,7 +32,7 @@ jobs:
3232
echo "current_id: $(sed -n 1p ./dev/core_version)"
3333
3434
- name: Clone Clash Repository
35-
uses: actions/checkout@v3
35+
uses: actions/checkout@v4
3636
with:
3737
repository: Dreamacro/clash
3838
ref: dev
@@ -64,7 +64,7 @@ jobs:
6464
echo "upx=../upx-3.95-amd64_linux/upx" >> $GITHUB_ENV
6565
6666
- name: Clone OpenClash Repository
67-
uses: actions/checkout@v3
67+
uses: actions/checkout@v4
6868
with:
6969
ref: core
7070

@@ -82,7 +82,7 @@ jobs:
8282
check-latest: true
8383

8484
- name: Clone Clash Repository
85-
uses: actions/checkout@v3
85+
uses: actions/checkout@v4
8686
with:
8787
repository: Dreamacro/clash
8888
ref: dev
@@ -98,7 +98,7 @@ jobs:
9898
cp -rf "./bin/." "../tmp/bin/"
9999
100100
- name: Clone OpenClash Repository
101-
uses: actions/checkout@v3
101+
uses: actions/checkout@v4
102102
with:
103103
ref: core
104104

.github/workflows/compile_meta_core.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
sudo apt-get -y install git
2222
2323
- name: Clone OpenClash Repository
24-
uses: actions/checkout@v3
24+
uses: actions/checkout@v4
2525
with:
2626
ref: core
2727

@@ -32,7 +32,7 @@ jobs:
3232
echo "current_id: $(sed -n 3p ./dev/core_version)"
3333
3434
- name: Clone Clash Meta Repository
35-
uses: actions/checkout@v3
35+
uses: actions/checkout@v4
3636
with:
3737
repository: MetaCubeX/mihomo
3838
ref: Alpha
@@ -63,7 +63,7 @@ jobs:
6363
echo "upx=../upx-3.95-amd64_linux/upx" >> $GITHUB_ENV
6464
6565
- name: Clone OpenClash Repository
66-
uses: actions/checkout@v3
66+
uses: actions/checkout@v4
6767
with:
6868
ref: core
6969

@@ -81,7 +81,7 @@ jobs:
8181
check-latest: true
8282

8383
- name: Clone Clash Meta Repository
84-
uses: actions/checkout@v3
84+
uses: actions/checkout@v4
8585
with:
8686
repository: MetaCubeX/mihomo
8787
ref: Alpha
@@ -96,7 +96,7 @@ jobs:
9696
cp -rf "./bin/." "../tmp/bin/"
9797
9898
- name: Clone OpenClash Repository
99-
uses: actions/checkout@v3
99+
uses: actions/checkout@v4
100100
with:
101101
ref: core
102102

.github/workflows/compile_new_ipk.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
current_version: ${{ steps.current_version.outputs.version }}
1818
steps:
1919
- name: Clone Repository
20-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2121
with:
2222
ref: ${{ github.ref_name }}
2323

@@ -28,7 +28,7 @@ jobs:
2828
echo "New Version: $(grep 'PKG_VERSION:=' ./luci-app-openclash/Makefile |awk -F '=' '{print $2}')"
2929
3030
- name: Clone Repository
31-
uses: actions/checkout@v3
31+
uses: actions/checkout@v4
3232
with:
3333
ref: package
3434

@@ -44,7 +44,7 @@ jobs:
4444
if: ${{ needs.Get-Version.outputs.version != needs.Get-Version.outputs.current_version }}
4545
steps:
4646
- name: Clone OpenClash dev Repository
47-
uses: actions/checkout@v3
47+
uses: actions/checkout@v4
4848
with:
4949
ref: ${{ github.ref_name }}
5050

@@ -59,10 +59,10 @@ jobs:
5959
run: |
6060
cd ..
6161
mkdir tmp
62-
curl -SLk --connect-timeout 30 --retry 2 "https://archive.openwrt.org/snapshots/trunk/ar71xx/generic/OpenWrt-SDK-ar71xx-generic_gcc-5.3.0_musl-1.1.16.Linux-x86_64.tar.bz2" -o "./tmp/SDK.tar.bz2"
62+
curl -SLk --connect-timeout 30 --retry 2 "https://archive.openwrt.org/chaos_calmer/15.05.1/ar71xx/generic/OpenWrt-SDK-15.05.1-ar71xx-generic_gcc-4.8-linaro_uClibc-0.9.33.2.Linux-x86_64.tar.bz2" -o "./tmp/SDK.tar.bz2"
6363
cd \tmp
6464
tar xjf SDK.tar.bz2
65-
mv "OpenWrt-SDK-ar71xx-generic_gcc-5.3.0_musl-1.1.16.Linux-x86_64" "SDK"
65+
mv "OpenWrt-SDK-15.05.1-ar71xx-generic_gcc-4.8-linaro_uClibc-0.9.33.2.Linux-x86_64" "SDK"
6666
6767
- name: Copy OpenClash Source Codes
6868
run: |
@@ -85,7 +85,7 @@ jobs:
8585
make package/luci-app-openclash/compile V=99
8686
8787
- name: Switch OpenClash Repository to Package
88-
uses: actions/checkout@v3
88+
uses: actions/checkout@v4
8989
with:
9090
ref: package
9191

.github/workflows/compile_premium_core.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
sudo apt-get -y install curl git gzip
2222
2323
- name: Clone OpenClash Repository
24-
uses: actions/checkout@v3
24+
uses: actions/checkout@v4
2525
with:
2626
ref: core
2727

@@ -63,7 +63,7 @@ jobs:
6363
echo "upx=../upx-3.95-amd64_linux/upx" >> $GITHUB_ENV
6464
6565
- name: Clone OpenClash Repository
66-
uses: actions/checkout@v3
66+
uses: actions/checkout@v4
6767
with:
6868
ref: core
6969

.github/workflows/master_release_sync.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
sudo apt-get -y install git
1818
1919
- name: Clone OpenClash Repository
20-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2121
with:
2222
ref: core
2323

@@ -39,7 +39,7 @@ jobs:
3939
fi
4040
4141
- name: Clone OpenClash Repository
42-
uses: actions/checkout@v3
42+
uses: actions/checkout@v4
4343
with:
4444
ref: package
4545

README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,13 @@
6868
---
6969

7070

71-
从 OpenWrt 的 [SDK](https://archive.openwrt.org/snapshots/trunk/ar71xx/generic/OpenWrt-SDK-ar71xx-generic_gcc-5.3.0_musl-1.1.16.Linux-x86_64.tar.bz2) 编译
71+
从 OpenWrt 的 [SDK](https://archive.openwrt.org/chaos_calmer/15.05.1/ar71xx/generic/OpenWrt-SDK-15.05.1-ar71xx-generic_gcc-4.8-linaro_uClibc-0.9.33.2.Linux-x86_64.tar.bz2) 编译
7272
```bash
7373
# 解压下载好的 SDK
74-
tar xjf OpenWrt-SDK-ar71xx-generic_gcc-5.3.0_musl-1.1.16.Linux-x86_64.tar.bz2
75-
cd OpenWrt-SDK-ar71xx-*
74+
curl -SLk --connect-timeout 30 --retry 2 "https://archive.openwrt.org/chaos_calmer/15.05.1/ar71xx/generic/OpenWrt-SDK-15.05.1-ar71xx-generic_gcc-4.8-linaro_uClibc-0.9.33.2.Linux-x86_64.tar.bz2" -o "/tmp/SDK.tar.bz2"
75+
cd \tmp
76+
tar xjf SDK.tar.bz2
77+
cd OpenWrt-SDK-15.05.1-*
7678

7779
# Clone 项目
7880
mkdir package/luci-app-openclash
@@ -96,7 +98,7 @@ cd ../..
9698
make package/luci-app-openclash/luci-app-openclash/compile V=99
9799

98100
# IPK文件位置
99-
./bin/ar71xx/packages/base/luci-app-openclash_0.39.7-beta_all.ipk
101+
./bin/ar71xx/packages/base/luci-app-openclash_*-beta_all.ipk
100102
```
101103

102104
```bash

luci-app-openclash/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
include $(TOPDIR)/rules.mk
22

33
PKG_NAME:=luci-app-openclash
4-
PKG_VERSION:=0.46.001
4+
PKG_VERSION:=0.46.003
55
PKG_RELEASE:=beta
66
PKG_MAINTAINER:=vernesong <https://github.com/vernesong/OpenClash>
77

luci-app-openclash/luasrc/controller/openclash.lua

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -654,7 +654,7 @@ function set_subinfo_url()
654654
end
655655

656656
function sub_info_get()
657-
local filepath, filename, sub_url, sub_info, info, upload, download, total, expire, http_code, len, percent, day_left, day_expire
657+
local filepath, filename, sub_url, sub_info, info, upload, download, total, expire, http_code, len, percent, day_left, day_expire, surplus, used
658658
local info_tb = {}
659659
filename = luci.http.formvalue("filename")
660660
sub_info = ""
@@ -705,14 +705,14 @@ function sub_info_get()
705705
else
706706
day_left = 0
707707
end
708-
709708
if used and total and used < total then
710709
percent = string.format("%.1f",((total-used)/total)*100) or nil
711710
elseif used == nil or total == nil or total == 0 then
712711
percent = 100
713712
else
714713
percent = 0
715714
end
715+
surplus = fs.filesize(total - used) or "null"
716716
total = fs.filesize(total) or "null"
717717
used = fs.filesize(used) or "null"
718718
sub_info = "Successful"
@@ -727,6 +727,7 @@ function sub_info_get()
727727
luci.http.write_json({
728728
http_code = http_code,
729729
sub_info = sub_info,
730+
surplus = surplus,
730731
used = used,
731732
total = total,
732733
percent = percent,
@@ -1071,7 +1072,8 @@ function action_status()
10711072
db_forward_ssl = db_foward_ssl(),
10721073
web = is_web(),
10731074
cn_port = cn_port(),
1074-
restricted_mode = restricted_mode();
1075+
restricted_mode = restricted_mode(),
1076+
core_type = uci:get("openclash", "config", "core_type") or "Dev";
10751077
})
10761078
end
10771079

luci-app-openclash/luasrc/model/cbi/openclash/settings.lua

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,10 @@ o = s:taboption("traffic_control", Flag, "disable_udp_quic", font_red..bold_on..
236236
o.description = translate("Prevent YouTube and Others To Use QUIC Transmission")..", "..font_red..bold_on..translate("REJECT UDP Traffic(Not Include CN) On Port 443")..bold_off..font_off
237237
o.default = 1
238238

239+
o = s:taboption("traffic_control", Flag, "skip_proxy_address", translate("Skip Proxy Address"))
240+
o.description = translate("Bypassing Server Addresses And Preventing Duplicate Proxies")
241+
o.default = 0
242+
239243
o = s:taboption("traffic_control", Value, "common_ports", font_red..bold_on..translate("Common Ports Proxy Mode")..bold_off..font_off)
240244
o.description = translate("Only Common Ports, Prevent BT/P2P Passing")
241245
o:value("0", translate("Disable"))

0 commit comments

Comments
 (0)