(state: BackState)
| 453 | } |
| 454 | |
| 455 | export function openFlashpointManager(state: BackState): void { |
| 456 | const cwd = path.join(state.config.flashpointPath, 'Manager'); |
| 457 | const fpmPath = 'FlashpointManager.exe'; |
| 458 | const updatesReady = state.componentStatuses.filter(c => c.state === ComponentState.NEEDS_UPDATE).length > 0; |
| 459 | exitApp(state, async () => { |
| 460 | const args = updatesReady ? ['/update', '/launcher'] : ['/launcher']; |
| 461 | const child = child_process.spawn(fpmPath, args, { detached: true, cwd, stdio: ['ignore', 'ignore', 'ignore'] }); |
| 462 | child.unref(); |
| 463 | await promiseSleep(2500); |
| 464 | }); |
| 465 | } |
| 466 | |
| 467 | export function compareSemVerVersions(v1: string, v2: string): number { |
| 468 | const v1Parts = v1.split('.').map(part => parseInt(part)); |
no test coverage detected