(config: Partial<QodexConfig>)
| 116 | } |
| 117 | |
| 118 | export async function saveUserConfig(config: Partial<QodexConfig>): Promise<void> { |
| 119 | await ensureQodexHome(); |
| 120 | await withLock(QODEX_CONFIG_FILE + '.lock', async () => { |
| 121 | const yamlText = yaml.dump(config, { indent: 2, lineWidth: 100 }); |
| 122 | await writeFileAtomic(QODEX_CONFIG_FILE, yamlText); |
| 123 | }); |
| 124 | } |
| 125 | |
| 126 | export async function configExists(): Promise<boolean> { |
| 127 | try { |
nothing calls this directly
no test coverage detected