Skip to main content

build_source_pack

Function build_source_pack 

Source
pub fn build_source_pack<W>(
    builder: StreamingPackBuilder<W>,
    source: &impl ObjectSource,
    selected: &State,
    max_objects: usize,
    max_decoded_bytes: u64,
) -> Result<(W, PackStats), HeddleError>
where W: Write + Read + Seek + SyncData,
Expand description

Build an exact selected-source pack without consulting State history, provenance, attachments, or linked spools. Full canonical trees keep private delta bases out of the pack. The caller owns revision authorization and the temporary output directory; discard that directory on failure.

Object bytes stream into the builder one object at a time. Blob header lengths are checked before reading where the source supports that probe. No object repository, CLI, network, or async runtime dependency is required.