mirror of
https://github.com/clash-verge-rev/clash-verge-rev
synced 2025-05-05 00:33:45 +08:00
chore: remove fast-dev profile and enhance dev profile settings
This commit is contained in:
parent
7383459b9a
commit
9d9dd73790
@ -3,8 +3,8 @@
|
||||
"version": "2.2.4-alpha.2",
|
||||
"license": "GPL-3.0-only",
|
||||
"scripts": {
|
||||
"dev": "cross-env RUST_BACKTRACE=1 tauri dev -f verge-dev -- --profile fast-dev",
|
||||
"dev:diff": "cross-env RUST_BACKTRACE=1 tauri dev -f verge-dev -- --profile fast-dev",
|
||||
"dev": "cross-env RUST_BACKTRACE=1 tauri dev -f verge-dev",
|
||||
"dev:diff": "cross-env RUST_BACKTRACE=1 tauri dev -f verge-dev",
|
||||
"build": "cross-env NODE_OPTIONS='--max-old-space-size=4096' tauri build",
|
||||
"build:fast": "cross-env NODE_OPTIONS='--max-old-space-size=4096' tauri build -- --profile fast-release",
|
||||
"tauri": "tauri",
|
||||
|
@ -104,6 +104,10 @@ strip = true
|
||||
|
||||
[profile.dev]
|
||||
incremental = true
|
||||
codegen-units = 256 # 增加编译单元,提升编译速度
|
||||
opt-level = 0 # 禁用优化,进一步提升编译速度
|
||||
debug = true # 保留调试信息
|
||||
strip = false # 不剥离符号,保留调试信息
|
||||
|
||||
[profile.fast-release]
|
||||
inherits = "release" # 继承 release 的配置
|
||||
@ -114,14 +118,6 @@ opt-level = 0 # 禁用优化,大幅提升编译速度
|
||||
debug = true # 保留调试信息
|
||||
strip = false # 不剥离符号,保留调试信息
|
||||
|
||||
[profile.fast-dev]
|
||||
inherits = "dev" # 继承 dev 的配置
|
||||
codegen-units = 256 # 增加编译单元,提升编译速度
|
||||
opt-level = 0 # 禁用优化,进一步提升编译速度
|
||||
incremental = true # 启用增量编译
|
||||
debug = true # 保留调试信息
|
||||
strip = false # 不剥离符号,保留调试信息
|
||||
|
||||
[lib]
|
||||
name = "app_lib"
|
||||
crate-type = ["staticlib", "cdylib", "rlib"]
|
||||
|
@ -9,5 +9,4 @@ pub mod timer;
|
||||
pub mod tray;
|
||||
pub mod win_uwp;
|
||||
|
||||
pub use self::core::*;
|
||||
pub use self::timer::Timer;
|
||||
pub use self::{core::*, timer::Timer};
|
||||
|
@ -79,16 +79,16 @@ pub fn clean() -> bool {
|
||||
// 1. 处理TUN模式
|
||||
let tun_success = if Config::verge().data().enable_tun_mode.unwrap_or(false) {
|
||||
let disable_tun = serde_json::json!({
|
||||
"tun": {
|
||||
"enable": false
|
||||
}
|
||||
});
|
||||
"tun": {
|
||||
"enable": false
|
||||
}
|
||||
});
|
||||
timeout(
|
||||
Duration::from_secs(1),
|
||||
MihomoManager::global().patch_configs(disable_tun),
|
||||
)
|
||||
.await
|
||||
.is_ok()
|
||||
.await
|
||||
.is_ok()
|
||||
} else {
|
||||
true
|
||||
};
|
||||
@ -98,7 +98,7 @@ pub fn clean() -> bool {
|
||||
Duration::from_secs(1),
|
||||
sysopt::Sysopt::global().reset_sysproxy(),
|
||||
)
|
||||
.await;
|
||||
.await;
|
||||
|
||||
let core_res = timeout(Duration::from_secs(1), CoreManager::global().stop_core()).await;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user