Ship the WeChat hot-update catalogs and the camp, TideWhale T2, UI atlas, and animation-lab work.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
[CmdletBinding(SupportsShouldProcess)]
|
||||
param([string]$TaskName = 'AIGame-AIServer', [switch]$UninstallTask)
|
||||
$ErrorActionPreference = 'Stop'
|
||||
$expected = [IO.Path]::GetFullPath((Join-Path $PSScriptRoot 'aiserver.exe'))
|
||||
if ($PSCmdlet.ShouldProcess($expected, 'Stop this release and its startup task')) {
|
||||
$task = Get-ScheduledTask -TaskName $TaskName -ErrorAction SilentlyContinue
|
||||
if ($task) {
|
||||
Stop-ScheduledTask -TaskName $TaskName
|
||||
if ($UninstallTask) { Unregister-ScheduledTask -TaskName $TaskName -Confirm:$false }
|
||||
}
|
||||
Get-CimInstance Win32_Process -Filter "Name='aiserver.exe'" | Where-Object {
|
||||
$_.ExecutablePath -and [IO.Path]::GetFullPath($_.ExecutablePath) -eq $expected
|
||||
} | ForEach-Object { Stop-Process -Id $_.ProcessId -Force }
|
||||
Write-Output 'Stopped. Database and logs preserved.'
|
||||
}
|
||||
Reference in New Issue
Block a user