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

Function write_all

libatomic/src/daemon/services_agent.rs:3081–3088  ·  view source on GitHub ↗
(path: &std::path::Path, bytes: &[u8])

Source from the content-addressed store, hash-verified

3079}
3080
3081fn write_all(path: &std::path::Path, bytes: &[u8]) -> Result<(), Status> {
3082 if let Some(parent) = path.parent() {
3083 std::fs::create_dir_all(parent)
3084 .map_err(|e| domain_status(ErrorCode::Internal, format!("sidecar dir: {e}")))?;
3085 }
3086 std::fs::write(path, bytes)
3087 .map_err(|e| domain_status(ErrorCode::Internal, format!("sidecar write: {e}")))
3088}
3089
3090#[tonic::async_trait]
3091impl attestation_service_server::AttestationService for AttestationImpl {

Callers 2

write_ignoring_errorsFunction · 0.85
record_attestationMethod · 0.85

Calls 3

domain_statusFunction · 0.85
parentMethod · 0.80
writeFunction · 0.50

Tested by

no test coverage detected