MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / get_file_lines

Function get_file_lines

atomic-core/src/output/crdt.rs:309–311  ·  view source on GitHub ↗

Retrieve all lines for a file by path. This function reads the CRDT tables to reconstruct the file's content line by line, with token-level granularity. # Arguments `txn` - A mutable transaction for database access `path` - The file path to retrieve # Returns A vector of `Line` structs representing the file's content. Returns an empty vector if the file doesn't exist. # Example ```rust,igno

(txn: &mut T, path: &str)

Source from the content-addressed store, hash-verified

307/// }
308/// ```
309pub fn get_file_lines<T: MutTxnT>(txn: &mut T, path: &str) -> PristineResult<Vec<Line>> {
310 get_file_lines_with_options(txn, path, &RetrievalOptions::default())
311}
312
313/// Retrieve all lines for a file by path with options.
314///

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected