The tree of commit `sha`, or `None` when it is not locally readable.
(git: &'r GitRepository, sha: &str)
| 1104 | |
| 1105 | /// The tree of commit `sha`, or `None` when it is not locally readable. |
| 1106 | fn commit_tree_of<'r>(git: &'r GitRepository, sha: &str) -> Option<git2::Tree<'r>> { |
| 1107 | let oid = git2::Oid::from_str(sha).ok()?; |
| 1108 | let commit = git.find_commit(oid).ok()?; |
| 1109 | commit.tree().ok() |
| 1110 | } |
| 1111 | |
| 1112 | #[derive(Clone)] |
| 1113 | pub(crate) struct VerifiedImportCommit { |