fix: clippy lint

This commit is contained in:
Slinetrac
2025-11-09 23:23:03 +08:00
parent 221a1e89eb
commit 0dcdd7fed6
8 changed files with 23 additions and 18 deletions

View File

@@ -520,7 +520,7 @@ impl EventDrivenProxyManager {
use crate::utils::dirs;
#[allow(unused_imports)] // creation_flags必须
use std::os::windows::process::CommandExt;
use std::os::windows::process::CommandExt as _;
use tokio::process::Command;
let binary_path = match dirs::service_path() {

View File

@@ -37,7 +37,7 @@ async fn uninstall_service() -> Result<()> {
use deelevate::{PrivilegeLevel, Token};
use runas::Command as RunasCommand;
use std::os::windows::process::CommandExt;
use std::os::windows::process::CommandExt as _;
let binary_path = dirs::service_path()?;
let uninstall_path = binary_path.with_file_name("clash-verge-service-uninstall.exe");
@@ -72,7 +72,7 @@ async fn install_service() -> Result<()> {
use deelevate::{PrivilegeLevel, Token};
use runas::Command as RunasCommand;
use std::os::windows::process::CommandExt;
use std::os::windows::process::CommandExt as _;
let binary_path = dirs::service_path()?;
let install_path = binary_path.with_file_name("clash-verge-service-install.exe");

View File

@@ -59,7 +59,7 @@ async fn execute_sysproxy_command(args: Vec<std::string::String>) -> Result<()>
use crate::utils::dirs;
use anyhow::bail;
#[allow(unused_imports)] // Required for .creation_flags() method
use std::os::windows::process::CommandExt;
use std::os::windows::process::CommandExt as _;
use tokio::process::Command;
let binary_path = dirs::service_path()?;