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

Function whiteout_path

atomic-repository/src/oci.rs:288–293  ·  view source on GitHub ↗

Encode the OCI whiteout entry name for a deleted path.

(path: &str)

Source from the content-addressed store, hash-verified

286
287/// Encode the OCI whiteout entry name for a deleted path.
288fn whiteout_path(path: &str) -> String {
289 match path.rfind('/') {
290 Some(idx) => format!("{}/.wh.{}", &path[..idx], &path[idx + 1..]),
291 None => format!(".wh.{path}"),
292 }
293}
294
295/// Strip the `sha256:` prefix from a digest, yielding the bare hex used as a
296/// blob filename.

Callers 1

layer_from_entriesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected