Expand description
Index management for void repositories.
The index tracks staged files with their content hashes and filesystem metadata (mtime, size) for fast dirty detection.
Structs§
- Index
Entry - Index entry for a tracked file.
- Rebuild
Result - Result of rebuilding the index.
- Workspace
Index - Workspace index snapshot.
Functions§
- entry_
matches_ file - Check if a file matches its index entry (slow path: hash if stat differs).
- entry_
matches_ stat - Check if a file matches its index entry using stat only (fast path, no hash).
- index_
entry_ from_ file - Create an IndexEntry from a file path (reads metadata + hashes content).
- index_
entry_ from_ file_ with_ content - Create an IndexEntry from a file path AND return the file content.
- read_
index - Reads the encrypted workspace index from disk.
- rebuild_
index - Rebuild index from HEAD commit state + working tree scan.
- write_
index - Writes the encrypted workspace index to disk.
- write_
workspace_ index - Writes a WorkspaceIndex directly to disk.