Functions§
- compute_
edit_ file_ diff - Return a formatted diff string for an edit_file operation without applying it. Lines prefixed “- “ are removals, “+ “ are additions. Returns Err if the search string cannot be located (caller falls through to normal tool dispatch).
- compute_
msr_ diff - Return a formatted diff string for a multi_search_replace operation without applying it.
- compute_
patch_ hunk_ diff - Return a formatted diff string for a patch_hunk operation without applying it.
- create_
directory - edit_
file - grep_
files - hematite_
dir - Returns the directory where Hematite’s runtime state (
.hematite/) should live. - inspect_
lines - is_
project_ workspace - Returns true if the workspace root looks like a real project.
A bare
.gitalone (e.g. accidentalgit initin the home folder) doesn’t count — at least one explicit build/package marker must also be present. - is_
sovereign_ directory - Returns true if
pathis a known sovereign OS directory (Desktop, Downloads, Documents, Pictures, Videos, Music). These directories should not accumulate.hematite/workspace state — they use the global~/.hematite/instead. - list_
files - multi_
search_ replace - open_
in_ system_ editor - patch_
hunk - pop_
ghost_ ledger - read_
file - tail_
file - workspace_
root - Resolve the workspace root by looking upward for common markers.
- write_
file