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

Function sits_under_deleted_path

atomic-cli/src/commands/git/parallel.rs:9559–9564  ·  view source on GitHub ↗

Whether `path` lies under a path this same commit vacates: a regular file or symlink replaced by a directory of the same name.

(path: &str, deleted: &HashSet<&str>)

Source from the content-addressed store, hash-verified

9557/// Whether `path` lies under a path this same commit vacates: a regular
9558/// file or symlink replaced by a directory of the same name.
9559fn sits_under_deleted_path(path: &str, deleted: &HashSet<&str>) -> bool {
9560 !deleted.is_empty()
9561 && path
9562 .rmatch_indices('/')
9563 .any(|(end, _)| deleted.contains(&path[..end]))
9564}
9565
9566/// The view a commit's Atomic claim is verified against and, when the view
9567/// holds it, the state the commit names.

Callers 2

Calls 2

is_emptyMethod · 0.45
containsMethod · 0.45

Tested by

no test coverage detected