MCPcopy
hub / github.com/claude-code-best/claude-code / getSettingsWithSources

Function getSettingsWithSources

src/utils/settings/settings.ts:836–848  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

834 * and `sources` are consistent even if the change detector hasn't fired yet.
835 */
836export function getSettingsWithSources(): SettingsWithSources {
837 // Reset both caches so getSettingsForSource (per-source cache) and
838 // getInitialSettings (session cache) agree on the current disk state.
839 resetSettingsCache()
840 const sources: SettingsWithSources['sources'] = []
841 for (const source of getEnabledSettingSources()) {
842 const settings = getSettingsForSource(source)
843 if (settings && Object.keys(settings).length > 0) {
844 sources.push({ source, settings })
845 }
846 }
847 return { effective: getInitialSettings(), sources }
848}
849
850/**
851 * Get merged settings and validation errors from all sources

Callers 1

runHeadlessStreamingFunction · 0.85

Calls 6

resetSettingsCacheFunction · 0.85
getEnabledSettingSourcesFunction · 0.85
getSettingsForSourceFunction · 0.85
getInitialSettingsFunction · 0.70
keysMethod · 0.65
pushMethod · 0.45

Tested by

no test coverage detected