§5.5 identity resolution for projected commits: Atomic identity first, then the configured `[git.identity]` mapping, then a deterministic foreign DID.
(
repo: &Repository,
repo_root: &Path,
fallback_name: Option<&str>,
fallback_email: Option<&str>,
)
| 1713 | /// then the configured `[git.identity]` mapping, then a deterministic |
| 1714 | /// foreign DID. |
| 1715 | pub(crate) fn projection_author( |
| 1716 | repo: &Repository, |
| 1717 | repo_root: &Path, |
| 1718 | fallback_name: Option<&str>, |
| 1719 | fallback_email: Option<&str>, |
| 1720 | ) -> atomic_repository::ProjectionAuthor { |
| 1721 | let (name, email) = identity_author().unwrap_or_else(|| { |
| 1722 | ( |
| 1723 | fallback_name.unwrap_or("Atomic").to_string(), |
| 1724 | fallback_email.unwrap_or("atomic@localhost").to_string(), |
| 1725 | ) |
| 1726 | }); |
| 1727 | let did = identity_map(repo, repo_root).did_for_email(&email); |
| 1728 | atomic_repository::ProjectionAuthor { |
| 1729 | name, |
| 1730 | email, |
| 1731 | did, |
| 1732 | agent_did: None, |
| 1733 | } |
| 1734 | } |
| 1735 | |
| 1736 | fn identity_author() -> Option<(String, String)> { |
| 1737 | use atomic_identity::IdentityStore; |
no test coverage detected