feat: control final tun config

This commit is contained in:
GyDi
2022-04-01 23:55:44 +08:00
parent 5b9e078061
commit cde17385b4
3 changed files with 56 additions and 57 deletions

View File

@@ -28,14 +28,6 @@ pub fn resolve_setup(app: &App) {
log_if_err!(clash.activate_enhanced(&profiles, true, true));
verge.init_sysproxy(clash.info.port.clone());
// enable tun mode
if verge.config.enable_tun_mode.clone().unwrap_or(false)
&& verge.cur_sysproxy.is_some()
&& verge.cur_sysproxy.as_ref().unwrap().enable
{
log::info!("enable tun mode");
clash.tun_mode(true).unwrap();
}
log_if_err!(verge.init_launch());