Fix Windows mpv logging and add log export (#88)

This commit is contained in:
2026-05-26 00:31:38 -07:00
committed by GitHub
parent 43ebc7d371
commit 11c196821d
150 changed files with 2748 additions and 582 deletions
+24
View File
@@ -0,0 +1,24 @@
import { exportLogsArchiveForCurrentUser } from '../../src/main/runtime/log-export.js';
import type { ExportLogsResult } from '../../src/main/runtime/log-export.js';
import type { LauncherCommandContext } from './context.js';
interface LogsCommandDeps {
exportLogsArchive(): ExportLogsResult;
}
const defaultDeps: LogsCommandDeps = {
exportLogsArchive: () => exportLogsArchiveForCurrentUser(),
};
export function runLogsCommand(
context: LauncherCommandContext,
deps: LogsCommandDeps = defaultDeps,
): boolean {
if (!context.args.logsExport) {
return false;
}
const result = deps.exportLogsArchive();
context.processAdapter.writeStdout(`${result.zipPath}\n`);
return true;
}