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

Method status_for_record

atomic-repository/src/repository/status.rs:41–52  ·  view source on GitHub ↗

Compute status for recording without scanning unrelated untracked files. Raw rename detection is the only record stage that consumes untracked entries. When it is enabled, defer the walk until the selected tracked status contains a deleted regular file. Untracked content hashes are also unnecessary because rename matching reads candidates on demand.

(
        &self,
        options: StatusOptions,
        detect_raw_renames: bool,
    )

Source from the content-addressed store, hash-verified

39 /// status contains a deleted regular file. Untracked content hashes are
40 /// also unnecessary because rename matching reads candidates on demand.
41 pub(crate) fn status_for_record(
42 &self,
43 options: StatusOptions,
44 detect_raw_renames: bool,
45 ) -> Result<RepositoryStatus, RepositoryError> {
46 let policy = if detect_raw_renames {
47 UntrackedScanPolicy::WhenRegularFileDeleted
48 } else {
49 UntrackedScanPolicy::Never
50 };
51 self.status_inner(options, policy, false)
52 }
53
54 fn status_inner(
55 &self,

Callers 1

recordMethod · 0.80

Calls 1

status_innerMethod · 0.80

Tested by

no test coverage detected