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

Function projection_signature

atomic-cli/src/commands/git/shim.rs:1544–1552  ·  view source on GitHub ↗

The projection commit's committer signature: Git config first, then the repository's configured default author, then the system identity. The projection commits are DERIVED artifacts of Atomic's verified state — with no Git config (a fresh machine or an isolated test HOME) they must not refuse; they commit as the system rather than fabricating user attribution (review CB-9C hermeticity).

(
    git: &GitRepository,
)

Source from the content-addressed store, hash-verified

1542/// not refuse; they commit as the system rather than fabricating user
1543/// attribution (review CB-9C hermeticity).
1544pub(crate) fn projection_signature(
1545 git: &GitRepository,
1546) -> Result<git2::Signature<'static>, CliError> {
1547 if let Ok(signature) = git.signature() {
1548 return Ok(signature);
1549 }
1550 git2::Signature::now("atomic", "atomic@invalid")
1551 .map_err(|error| git_error(format!("cannot build the projection signature: {error}")))
1552}
1553
1554fn git_head_paths(git: &GitRepository) -> CliResult<BTreeSet<String>> {
1555 let tree = git

Callers 2

project_atomic_to_gitFunction · 0.85

Calls 2

signatureMethod · 0.80
git_errorFunction · 0.70

Tested by

no test coverage detected