Replies: 1 comment 3 replies
-
That's not very descriptive. You are also using two different launch parameters when executing As you can see here, when Streamlink Twitch GUI launches the chat application, it completely ignores any IO streams and spawns the child process in detached mode and it unreferences it. And that's already it. You can see the resolved launch arguments when starting Streamlink Twitch GUI with the I'm not a Windows user and don't know much powershell, so I can't help you with the script. Launching it manually with the parameters resolved by the Twitch GUI and adding debug messages should be the first step that you should do in order to figure this out. |
Beta Was this translation helpful? Give feedback.
-
I want to run a PowerShell script to do some stuff before/after running the chat client.
This works:
But I was wondering why if I try to use PowerShell directly, it doesn't work:
Thanks!
Edit:
Using, this also works:
This is better because when the file/folders path have any spaces you need to place " around it. In the initial example, that was not possible. (at least everything I've tried failed to work)
To make it work with PowerShell Preview I had to do this:
Notice that there is a space after: '(' and before: ')'
That's intentional, if you remove them the command doesn't work at all, super weird.
I'm 100% sure it's related to the space in 'Program Files' because if I use the short version of the path it works fine:
/c C:\PROGRA~1\PowerShell\7-preview\pwsh.exe -ExecutionPolicy Bypass "C:\Folder\Script Test.ps1" -channel "{channel}"
(the paths are the same)
Other useful arguments:
-WindowStyle Hidden
hide the console window (it still shows up for a second, but it's good enough)
-NoExit
Doesn't close the console, useful to see errors that close the console before you can see anything
Beta Was this translation helpful? Give feedback.
All reactions