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

Method upload_change_file

atomic-remote/src/http/upload.rs:522–529  ·  view source on GitHub ↗

Upload a change file by reading directly from disk. This is a convenience wrapper around [`upload_change_streamed`](Self::upload_change_streamed) that streams the file from disk instead of loading it entirely into memory. Suitable for change files of any size. # Arguments `hash` - The base32-encoded hash of the change. `view` - The target view name. `path` - Path to the `.change` file on disk.

(
        &self,
        hash: &str,
        view: &str,
        path: &Path,
    )

Source from the content-addressed store, hash-verified

520 /// Returns an error if the file can't be read, the upload fails, or
521 /// the server rejects the change.
522 pub async fn upload_change_file(
523 &self,
524 hash: &str,
525 view: &str,
526 path: &Path,
527 ) -> RemoteResult<()> {
528 self.upload_change_streamed(hash, view, path).await
529 }
530}
531
532#[cfg(test)]

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected