fix: use Get-Command for PATH executables like ffmpeg
This commit is contained in:
parent
33fadd17bd
commit
51079466a3
@ -37,7 +37,8 @@ function Write-Banner {
|
||||
|
||||
function Start-Detached {
|
||||
param([string]$Name, [string]$Exe, [string[]]$Args)
|
||||
if (-not (Test-Path $Exe)) {
|
||||
$found = (Test-Path $Exe) -or (Get-Command $Exe -ErrorAction SilentlyContinue)
|
||||
if (-not $found) {
|
||||
Write-Host " [SKIP] $Name : 未找到 $Exe" -ForegroundColor Yellow
|
||||
return $null
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user