Update StackMonkey.ps1

This commit is contained in:
2025-06-29 03:28:01 -04:00
parent 76777b2826
commit afa652d007

View File

@@ -1485,16 +1485,16 @@ function Start-Server {
#endregion #endregion
# Only launch the UI if were in the default UI parameter set
# Only launch UI if not in silent mode if ($PSCmdlet.ParameterSetName -eq 'UI') {
if (-not $SilentInstall) { # now that $Port is defined, show it properly:
# open browser on whatever port you've set Write-Host "Starting ScriptMonkey UI on http://localhost:$Port/" -ForegroundColor Cyan
# Start-Process "microsoft-edge:http://localhost:$Port"
Start-Process "msedge.exe" -ArgumentList "--app=http://localhost:$Port" Start-Process "msedge.exe" -ArgumentList "--app=http://localhost:$Port"
# now start your server (this will block until you hit Exit in the UI) Start-Server # this will block until you hit Exit
Start-Server return
} }
# At the end of ScriptMonkey.ps1 # At the end of ScriptMonkey.ps1
if ($MyInvocation.ExpectingInput) { if ($MyInvocation.ExpectingInput) {
Invoke-ScriptMonkey @PSBoundParameters Invoke-ScriptMonkey @PSBoundParameters