Fix hidden Muninn launcher generation
This commit is contained in:
parent
616f047842
commit
d3b2173e84
2 changed files with 7 additions and 7 deletions
|
|
@ -47,10 +47,10 @@ if (`$obsArgs -like " --no-obs-target") {
|
|||
`$arguments += @("--audio-device", "$AudioDevice", "--ffmpeg", "$Ffmpeg", "--loopback-script", "$LoopbackScript", "--log-root", "$LogRoot")
|
||||
`$encodedArguments = (`$arguments | ConvertTo-Json -Compress)
|
||||
`$psLines = @(
|
||||
"`$ErrorActionPreference = ""Stop""",
|
||||
"`$arguments = '$encodedArguments' | ConvertFrom-Json",
|
||||
"`$process = Start-Process -FilePath ""$MuninnExe"" -ArgumentList `$arguments -WorkingDirectory ""`$muninnDir"" -WindowStyle Hidden -PassThru -RedirectStandardOutput ""$LogRoot\muninn-activate.out.log"" -RedirectStandardError ""$LogRoot\muninn-activate.err.log""",
|
||||
"`$process.Id | Set-Content -Encoding ASCII -LiteralPath ""`$pidPath"""
|
||||
'`$ErrorActionPreference = "Stop"',
|
||||
'`$arguments = ''$encodedArguments'' | ConvertFrom-Json',
|
||||
'`$process = Start-Process -FilePath "$MuninnExe" -ArgumentList `$arguments -WindowStyle Hidden -PassThru -RedirectStandardOutput "$LogRoot\muninn-activate.out.log" -RedirectStandardError "$LogRoot\muninn-activate.err.log"',
|
||||
'`$process.Id | Set-Content -Encoding ASCII -LiteralPath "$LogRoot\muninn-activate.pid"'
|
||||
)
|
||||
Set-Content -LiteralPath `$psLauncher -Value `$psLines -Encoding ASCII
|
||||
`$lines = @(
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@ New-Item -ItemType Directory -Force -Path (Split-Path -Parent "$StorePath") | Ou
|
|||
`$psLauncher = Join-Path `$muninnDir "start-muninn-serve.ps1"
|
||||
`$pidPath = Join-Path "$LogRoot" "muninn-serve.pid"
|
||||
`$psLines = @(
|
||||
"`$ErrorActionPreference = ""Stop""",
|
||||
"`$process = Start-Process -FilePath ""$MuninnExe"" -ArgumentList @(""serve"", ""--store"", ""$StorePath"", ""--log-root"", ""$LogRoot"", ""--host"", ""raven"", ""--interval-seconds"", ""15"") -WorkingDirectory ""`$muninnDir"" -WindowStyle Hidden -PassThru -RedirectStandardOutput ""$LogRoot\muninn-serve.out.log"" -RedirectStandardError ""$LogRoot\muninn-serve.err.log""",
|
||||
"`$process.Id | Set-Content -Encoding ASCII -LiteralPath ""`$pidPath"""
|
||||
'`$ErrorActionPreference = "Stop"',
|
||||
'`$process = Start-Process -FilePath "$MuninnExe" -ArgumentList @("serve", "--store", "$StorePath", "--log-root", "$LogRoot", "--host", "raven", "--interval-seconds", "15") -WindowStyle Hidden -PassThru -RedirectStandardOutput "$LogRoot\muninn-serve.out.log" -RedirectStandardError "$LogRoot\muninn-serve.err.log"',
|
||||
'`$process.Id | Set-Content -Encoding ASCII -LiteralPath "$LogRoot\muninn-serve.pid"'
|
||||
)
|
||||
Set-Content -LiteralPath `$psLauncher -Value `$psLines -Encoding ASCII
|
||||
`$lines = @(
|
||||
|
|
|
|||
Loading…
Reference in a new issue