mirror of
https://github.com/Finesssee/ProxyPilot.git
synced 2026-11-19 02:17:46 +00:00
17 lines
346 B
PowerShell
17 lines
346 B
PowerShell
Set-StrictMode -Version Latest
|
|
$ErrorActionPreference = "Stop"
|
|
|
|
$exeName = "cliproxyapi"
|
|
$procs = Get-Process -Name $exeName -ErrorAction SilentlyContinue
|
|
|
|
if (-not $procs) {
|
|
Write-Host "No running $exeName process found."
|
|
exit 0
|
|
}
|
|
|
|
$procs | ForEach-Object {
|
|
Write-Host "Stopping $exeName (PID $($_.Id))"
|
|
Stop-Process -Id $_.Id -Force
|
|
}
|
|
|