refactor(launcher): split CLI flow into command modules

Isolate process-side effects behind adapter seams and keep wrapper behavior stable while improving command-level testability.
This commit is contained in:
2026-02-21 17:14:58 -08:00
parent 05be13be9e
commit c749430c77
14 changed files with 773 additions and 372 deletions

11
launcher/config-path.ts Normal file
View File

@@ -0,0 +1,11 @@
import fs from 'node:fs';
import os from 'node:os';
import { resolveConfigFilePath } from '../src/config/path-resolution.js';
export function resolveMainConfigPath(): string {
return resolveConfigFilePath({
xdgConfigHome: process.env.XDG_CONFIG_HOME,
homeDir: os.homedir(),
existsSync: fs.existsSync,
});
}