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

Function write_workspace_metadata

atomic-cli/src/commands/git/shim.rs:3369–3381  ·  view source on GitHub ↗
(root: &Path, snapshot: &ShimSnapshot)

Source from the content-addressed store, hash-verified

3367}
3368
3369fn write_workspace_metadata(root: &Path, snapshot: &ShimSnapshot) -> CliResult<()> {
3370 checkpoint::write_verified_checkpoint(
3371 root,
3372 VerifiedCheckpointInput {
3373 view: &snapshot.view,
3374 atomic_state: &snapshot.atomic_state,
3375 git_head: &snapshot.git_head,
3376 git_tree: &snapshot.git_tree,
3377 },
3378 )
3379 .map(|_| ())
3380 .map_err(checkpoint_error)
3381}
3382
3383fn checkpoint_error(error: checkpoint::CheckpointError) -> CliError {
3384 git_error(error.to_string())

Callers 5

switch_transactionFunction · 0.85

Calls 1

Tested by

no test coverage detected