pub fn lean_ctx_data_dir() -> Result<PathBuf, String>Expand description
Resolve the lean-ctx data directory.
Priority order (backward-compatible XDG split, GH #408):
LEAN_CTX_DATA_DIRenv var (explicit override)~/.lean-ctxif it has actual data (legacy installs)$XDG_CONFIG_HOME/lean-ctxif it has actual data (pre-split installs that mixed data into the config dir — kept in place, never silently moved)$XDG_DATA_HOME/lean-ctx(default~/.local/share/lean-ctx) for fresh installs, so the config dir holds only config and stays RO-sandbox-safe.
An empty ~/.lean-ctx/ directory does NOT trigger legacy mode — this prevents
data directory splits when setup creates the dir before MCP writes stats.