fix: write bat with UTF-8 to preserve Chinese path; use chcp 65001
This commit is contained in:
parent
220a66b1c7
commit
890755251d
@ -101,9 +101,10 @@ function Invoke-Start {
|
||||
if ($ffArgs) {
|
||||
$ffPath = (Get-Command $ffmpeg -ErrorAction SilentlyContinue).Source
|
||||
if (-not $ffPath) { $ffPath = $ffmpeg }
|
||||
$ffCmd = "`"$ffPath`" $($ffArgs -join ' ')"
|
||||
Start-Process "cmd" -ArgumentList "/k", $ffCmd
|
||||
Write-Host " [START] ffmpeg (cmd窗口)" -ForegroundColor Green
|
||||
$bat = Join-Path $edgeDir "scripts\ffmpeg-push.bat"
|
||||
"@echo off`r`nchcp 65001 >nul`r`n`"$ffPath`" $($ffArgs -join ' ')" | Out-File -FilePath $bat -Encoding UTF8
|
||||
Start-Process "cmd" -ArgumentList "/k", $bat
|
||||
Write-Host " [START] ffmpeg (bat窗口)" -ForegroundColor Green
|
||||
}
|
||||
|
||||
# 3. Media server (runs on RK3588, not local)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user