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

Function head_tree_of

atomic-cli/src/commands/git/shadow.rs:942–948  ·  view source on GitHub ↗
(git_repo: &GitRepository)

Source from the content-addressed store, hash-verified

940}
941
942fn head_tree_of(git_repo: &GitRepository) -> Option<git2::Oid> {
943 git_repo
944 .head()
945 .ok()
946 .and_then(|head| head.peel_to_commit().ok())
947 .map(|commit| commit.tree_id())
948}
949
950/// Whether the Git index is a clean stage-0 image of the view's projected
951/// tree. Only `StagingState.index_manifest` projects to the index (RFC §3.4);

Callers

nothing calls this directly

Calls 2

okMethod · 0.45
headMethod · 0.45

Tested by

no test coverage detected