/** * Return true only when the directory contains a durable Ruflo project marker. * * A bare `.claude/` is owned by Claude Code, and a bare `.claude-flow/` is not * sufficient either: startup-time policy/champion migration can create it * before this function runs. Treating that mutation as authorization caused a * read-only command in any Claude project to spawn a detached daemon (#2852). */ export declare function isRufloProject(projectRoot: string): boolean; /** * Walk up from `startDir` and return the NEAREST enclosing directory carrying * a Ruflo marker. Nearest-wins keeps a monorepo's independently-initialized * sub-project on its own state. * * A `.git` entry is a hard stop — the repository boundary. Without it the walk * could escape into an unrelated ancestor (a Ruflo project living at `$HOME`, * say) and hand every repo below it the same state. * * Returns the resolved `startDir` unchanged when no marker is found, which * preserves the previous cwd-relative behaviour outside a Ruflo project. */ export declare function resolveProjectRoot(startDir: string): string; /** * Anchor `dir` to its project root for durable state. Like resolveProjectRoot, * but a walk that lands on home or a filesystem root is rejected and `dir` is * returned instead — `~/.claude/settings.json` carrying a `claudeFlow` key * must not turn $HOME into every non-git directory's project. Mirrors the * guard cli-core's getProjectCwd() applies, so CLI commands and MCP tools * agree on the root. */ export declare function anchorToProjectRoot(dir: string): string; /** * The project root for the current process: anchorToProjectRoot(process.cwd()). * Not cached — the walk is a handful of stat calls, and tests spy on cwd. */ export declare function getProjectRoot(): string; //# sourceMappingURL=project-root.d.ts.map