(
repo: &atomic_repository::Repository,
view: &str,
git_sha: &str,
)
| 183 | |
| 184 | #[allow(dead_code)] |
| 185 | fn change_by_sha( |
| 186 | repo: &atomic_repository::Repository, |
| 187 | view: &str, |
| 188 | git_sha: &str, |
| 189 | ) -> atomic_core::change::Change { |
| 190 | let entries = repo.effective_history(Some(view)).unwrap(); |
| 191 | for entry in entries { |
| 192 | let change = repo.load_change(&entry.hash).unwrap(); |
| 193 | let sha = change |
| 194 | .unhashed |
| 195 | .as_ref() |
| 196 | .and_then(|value| value.get("git")) |
| 197 | .and_then(|git| git.get("sha")) |
| 198 | .and_then(|sha| sha.as_str()); |
| 199 | if sha == Some(git_sha) { |
| 200 | return change; |
| 201 | } |
| 202 | } |
| 203 | panic!("no imported change for git commit {git_sha}") |
| 204 | } |
| 205 | |
| 206 | fn frontier_closure_of( |
| 207 | repo: &atomic_repository::Repository, |
nothing calls this directly
no test coverage detected