Compare commits
10 Commits
24
UPDATELOG.md
24
UPDATELOG.md
@@ -1,3 +1,27 @@
|
||||
## v1.7.6
|
||||
|
||||
### Notice
|
||||
|
||||
- Clash Verge Rev 目前已进入稳定周期,日后更新将着重于 bug 修复与内核常规升级
|
||||
|
||||
### Features
|
||||
|
||||
- Meta(mihomo)内核升级 1.18.7
|
||||
- 界面细节调整
|
||||
- 优化服务模式安装逻辑
|
||||
- 移除无用的 console log
|
||||
- 能自动选择第一个订阅
|
||||
|
||||
### Bugs Fixes
|
||||
|
||||
- 修复服务模式安装问题
|
||||
- 修复 Mac 下的代理绕过 CIDR 写法过滤
|
||||
- 修复 32 位升级 URL
|
||||
- 修复不同分组 URL 测试地址配置无效的问题
|
||||
- 修复 Web UI 下的一处 hostname 参数
|
||||
|
||||
---
|
||||
|
||||
## v1.7.5
|
||||
|
||||
### Features
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "clash-verge",
|
||||
"version": "1.7.5",
|
||||
"version": "1.7.6",
|
||||
"license": "GPL-3.0-only",
|
||||
"scripts": {
|
||||
"dev": "tauri dev",
|
||||
|
||||
@@ -72,12 +72,12 @@ async function resolveUpdater() {
|
||||
}
|
||||
|
||||
// win32 url
|
||||
if (name.endsWith("x64-setup.nsis.zip")) {
|
||||
if (name.endsWith("x86-setup.nsis.zip")) {
|
||||
updateData.platforms["windows-x86"].url = browser_download_url;
|
||||
updateData.platforms["windows-i686"].url = browser_download_url;
|
||||
}
|
||||
// win32 signature
|
||||
if (name.endsWith("x64-setup.nsis.zip.sig")) {
|
||||
if (name.endsWith("x86-setup.nsis.zip.sig")) {
|
||||
const sig = await getSignature(browser_download_url);
|
||||
updateData.platforms["windows-x86"].signature = sig;
|
||||
updateData.platforms["windows-i686"].signature = sig;
|
||||
|
||||
2
src-tauri/Cargo.lock
generated
2
src-tauri/Cargo.lock
generated
@@ -790,7 +790,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "clash-verge"
|
||||
version = "1.7.5"
|
||||
version = "1.7.6"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"auto-launch",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "clash-verge"
|
||||
version = "1.7.5"
|
||||
version = "1.7.6"
|
||||
description = "clash verge"
|
||||
authors = ["zzzgydi", "wonfen", "MystiPanda"]
|
||||
license = "GPL-3.0-only"
|
||||
|
||||
@@ -111,6 +111,7 @@ impl IProfiles {
|
||||
if item.uid.is_none() {
|
||||
bail!("the uid should not be null");
|
||||
}
|
||||
let uid = item.uid.clone();
|
||||
|
||||
// save the file data
|
||||
// move the field value after save
|
||||
@@ -128,6 +129,12 @@ impl IProfiles {
|
||||
.with_context(|| format!("failed to write to file \"{}\"", file))?;
|
||||
}
|
||||
|
||||
if self.current.is_none()
|
||||
&& (item.itype == Some("remote".to_string()) || item.itype == Some("local".to_string()))
|
||||
{
|
||||
self.current = uid;
|
||||
}
|
||||
|
||||
if self.items.is_none() {
|
||||
self.items = Some(vec![]);
|
||||
}
|
||||
@@ -135,6 +142,7 @@ impl IProfiles {
|
||||
if let Some(items) = self.items.as_mut() {
|
||||
items.push(item)
|
||||
}
|
||||
|
||||
self.save_file()
|
||||
}
|
||||
|
||||
@@ -355,10 +363,15 @@ impl IProfiles {
|
||||
}
|
||||
// delete the original uid
|
||||
if current == uid {
|
||||
self.current = match !items.is_empty() {
|
||||
true => items[0].uid.clone(),
|
||||
false => None,
|
||||
};
|
||||
self.current = None;
|
||||
for item in items.iter() {
|
||||
if item.itype == Some("remote".to_string())
|
||||
|| item.itype == Some("local".to_string())
|
||||
{
|
||||
self.current = item.uid.clone();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
self.items = Some(items);
|
||||
|
||||
@@ -30,7 +30,7 @@ pub struct JsonResponse {
|
||||
|
||||
#[cfg(not(target_os = "windows"))]
|
||||
pub fn sudo(passwd: &String, cmd: String) -> StdCommand {
|
||||
let shell = format!("echo {} | sudo -S {}", passwd, cmd);
|
||||
let shell = format!("echo \"{}\" | sudo -S {}", passwd, cmd);
|
||||
let mut command = StdCommand::new("bash");
|
||||
command.arg("-c").arg(shell);
|
||||
command
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"$schema": "../node_modules/@tauri-apps/cli/schema.json",
|
||||
"package": {
|
||||
"productName": "Clash Verge",
|
||||
"version": "1.7.5"
|
||||
"version": "1.7.6"
|
||||
},
|
||||
"build": {
|
||||
"distDir": "../dist",
|
||||
|
||||
@@ -723,7 +723,7 @@ export const GroupsEditorViewer = (props: Props) => {
|
||||
throw new Error(t("Group Name Already Exists"));
|
||||
}
|
||||
}
|
||||
setPrependSeq([...prependSeq, formIns.getValues()]);
|
||||
setPrependSeq([formIns.getValues(), ...prependSeq]);
|
||||
} catch (err: any) {
|
||||
Notice.error(err.message || err.toString());
|
||||
}
|
||||
|
||||
@@ -276,7 +276,7 @@ export const ProxiesEditorViewer = (props: Props) => {
|
||||
startIcon={<VerticalAlignTopRounded />}
|
||||
onClick={() => {
|
||||
let proxies = handleParse();
|
||||
setPrependSeq([...prependSeq, ...proxies]);
|
||||
setPrependSeq([...proxies, ...prependSeq]);
|
||||
}}
|
||||
>
|
||||
{t("Prepend Proxy")}
|
||||
|
||||
@@ -543,7 +543,7 @@ export const RulesEditorViewer = (props: Props) => {
|
||||
try {
|
||||
let raw = validateRule();
|
||||
if (prependSeq.includes(raw)) return;
|
||||
setPrependSeq([...prependSeq, raw]);
|
||||
setPrependSeq([raw, ...prependSeq]);
|
||||
} catch (err: any) {
|
||||
Notice.error(err.message || err.toString());
|
||||
}
|
||||
|
||||
@@ -21,6 +21,7 @@ import delayManager from "@/services/delay";
|
||||
|
||||
interface Props {
|
||||
sx?: SxProps;
|
||||
url?: string;
|
||||
groupName: string;
|
||||
headState: HeadState;
|
||||
onLocation: () => void;
|
||||
@@ -29,7 +30,7 @@ interface Props {
|
||||
}
|
||||
|
||||
export const ProxyHead = (props: Props) => {
|
||||
const { sx = {}, groupName, headState, onHeadState } = props;
|
||||
const { sx = {}, url, groupName, headState, onHeadState } = props;
|
||||
|
||||
const { showType, sortType, filterText, textState, testUrl } = headState;
|
||||
|
||||
@@ -45,7 +46,10 @@ export const ProxyHead = (props: Props) => {
|
||||
const { verge } = useVerge();
|
||||
|
||||
useEffect(() => {
|
||||
delayManager.setUrl(groupName, testUrl || verge?.default_latency_test!);
|
||||
delayManager.setUrl(
|
||||
groupName,
|
||||
testUrl || url || verge?.default_latency_test!
|
||||
);
|
||||
}, [groupName, testUrl, verge?.default_latency_test]);
|
||||
|
||||
return (
|
||||
|
||||
@@ -129,6 +129,7 @@ export const ProxyRender = (props: RenderProps) => {
|
||||
return (
|
||||
<ProxyHead
|
||||
sx={{ pl: 2, pr: 3, mt: indent ? 1 : 0.5, mb: 1 }}
|
||||
url={group.testUrl}
|
||||
groupName={group.name}
|
||||
headState={headState!}
|
||||
onLocation={() => onLocation(group)}
|
||||
|
||||
@@ -24,7 +24,6 @@ export const NetworkInterfaceViewer = forwardRef<DialogRef>((props, ref) => {
|
||||
useEffect(() => {
|
||||
if (!open) return;
|
||||
getNetworkInterfacesInfo().then((res) => {
|
||||
console.log(res);
|
||||
setNetworkInterfaces(res);
|
||||
});
|
||||
}, [open]);
|
||||
@@ -115,7 +114,7 @@ const AddressDisplay = (props: { label: string; content: string }) => {
|
||||
<Box
|
||||
sx={({ palette }) => ({
|
||||
borderRadius: "8px",
|
||||
padding: "2px",
|
||||
padding: "2px 2px 2px 8px",
|
||||
background:
|
||||
palette.mode === "dark"
|
||||
? alpha(palette.background.paper, 0.3)
|
||||
|
||||
@@ -24,7 +24,7 @@ export const WebUIViewer = forwardRef<DialogRef>((props, ref) => {
|
||||
|
||||
const webUIList = verge?.web_ui_list || [
|
||||
"https://metacubex.github.io/metacubexd/#/setup?http=true&hostname=%host&port=%port&secret=%secret",
|
||||
"https://yacd.metacubex.one/?host=%host&port=%port&secret=%secret",
|
||||
"https://yacd.metacubex.one/?hostname=%host&port=%port&secret=%secret",
|
||||
];
|
||||
|
||||
const handleAdd = useLockFn(async (value: string) => {
|
||||
|
||||
@@ -28,7 +28,7 @@ interface Props {
|
||||
onDelete: (uid: string) => void;
|
||||
}
|
||||
|
||||
let eventListener: UnlistenFn | null = null;
|
||||
let eventListener: UnlistenFn = () => {};
|
||||
|
||||
export const TestItem = (props: Props) => {
|
||||
const { itemData, onEdit, onDelete: onDeleteItem } = props;
|
||||
@@ -90,9 +90,7 @@ export const TestItem = (props: Props) => {
|
||||
];
|
||||
|
||||
const listenTsetEvent = async () => {
|
||||
if (eventListener !== null) {
|
||||
eventListener();
|
||||
}
|
||||
eventListener();
|
||||
eventListener = await listen("verge://test-all", () => {
|
||||
onDelay();
|
||||
});
|
||||
@@ -100,7 +98,7 @@ export const TestItem = (props: Props) => {
|
||||
|
||||
useEffect(() => {
|
||||
listenTsetEvent();
|
||||
}, []);
|
||||
}, [url]);
|
||||
|
||||
return (
|
||||
<Box
|
||||
|
||||
@@ -202,7 +202,6 @@ export async function checkService() {
|
||||
}
|
||||
|
||||
export async function installService(passwd: string) {
|
||||
console.log(passwd);
|
||||
return invoke<void>("install_service", { passwd });
|
||||
}
|
||||
|
||||
|
||||
1
src/services/types.d.ts
vendored
1
src/services/types.d.ts
vendored
@@ -59,6 +59,7 @@ interface IProxyItem {
|
||||
time: string;
|
||||
delay: number;
|
||||
}[];
|
||||
testUrl?: string;
|
||||
all?: string[];
|
||||
now?: string;
|
||||
hidden?: boolean;
|
||||
|
||||
Reference in New Issue
Block a user