ClaudeProjects

works.iterative.claude.core.log.ClaudeProjects

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def baseDir(configDirOverride: Option[Path], home: Path): Path

Resolves the Claude projects base directory from an optional config override and home dir.

Resolves the Claude projects base directory from an optional config override and home dir.

Claude stores conversation logs under ~/.claude/projects/ by default. The CLAUDE_CONFIG_DIR environment variable, when set to a non-empty value, replaces ~/.claude entirely — so the projects directory becomes $CLAUDE_CONFIG_DIR/projects.

Important: empty strings in configDirOverride must be filtered out by the caller before constructing an os.Path (treat empty string as absent). Shell ~ expansion is not performed on CLAUDE_CONFIG_DIR values.

Value parameters

configDirOverride

resolved value of CLAUDE_CONFIG_DIR, None if unset or empty

home

the user's home directory (use os.home in production code)

Attributes

def projectDirFor(cwd: Path, configDirOverride: Option[Path], home: Path): Path

Resolves the project-specific subdirectory under the Claude projects base for cwd.

Resolves the project-specific subdirectory under the Claude projects base for cwd.

Encodes cwd using ProjectPathEncoder.encode and appends it to the base directory.

Value parameters

configDirOverride

resolved value of CLAUDE_CONFIG_DIR, None if unset or empty

cwd

the working directory path to encode

home

the user's home directory (use os.home in production code)

Attributes

def resolveConfigDir(env: String => Option[String]): Option[Path]

Resolves the CLAUDE_CONFIG_DIR override from an env lookup function.

Resolves the CLAUDE_CONFIG_DIR override from an env lookup function.

Reads CLAUDE_CONFIG_DIR via the injected env accessor and treats an empty string as unset. No shell ~ expansion is performed on the value.

Value parameters

env

lookup function that returns Some(value) when the variable is set

Attributes