MCPcopy Index your code
hub / github.com/codeaashu/claude-code / getAutoMemPathSetting

Function getAutoMemPathSetting

src/memdir/paths.ts:179–186  ·  view source on GitHub ↗

* Settings.json override for the full auto-memory directory path. * Supports ~/ expansion for user convenience. * * SECURITY: projectSettings (.claude/settings.json committed to the repo) is * intentionally excluded — a malicious repo could otherwise set * autoMemoryDirectory: "~/.ssh" and gain

()

Source from the content-addressed store, hash-verified

177 * the same pattern as hasSkipDangerousModePermissionPrompt() etc.
178 */
179function getAutoMemPathSetting(): string | undefined {
180 const dir =
181 getSettingsForSource('policySettings')?.autoMemoryDirectory ??
182 getSettingsForSource('flagSettings')?.autoMemoryDirectory ??
183 getSettingsForSource('localSettings')?.autoMemoryDirectory ??
184 getSettingsForSource('userSettings')?.autoMemoryDirectory
185 return validateMemoryPath(dir, true)
186}
187
188/**
189 * Check if CLAUDE_COWORK_MEMORY_PATH_OVERRIDE is set to a valid override.

Callers 1

paths.tsFile · 0.85

Calls 2

getSettingsForSourceFunction · 0.85
validateMemoryPathFunction · 0.85

Tested by

no test coverage detected