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

Function read_link_bytes

atomic-repository/src/change_source/scan.rs:762–765  ·  view source on GitHub ↗
(path: &Path)

Source from the content-addressed store, hash-verified

760
761#[cfg(unix)]
762fn read_link_bytes(path: &Path) -> std::io::Result<Vec<u8>> {
763 use std::os::unix::ffi::OsStrExt;
764 fs::read_link(path).map(|target| target.as_os_str().as_bytes().to_vec())
765}
766
767#[cfg(not(unix))]
768fn read_link_bytes(_path: &Path) -> std::io::Result<Vec<u8>> {

Callers 1

read_canonical_contentFunction · 0.85

Calls 1

as_bytesMethod · 0.45

Tested by

no test coverage detected