pub fn diff_files(a: &RepoFile, b: &RepoFile) -> FileDiffExpand description
Compare two RepoFile values and produce a FileDiff.
Diffs the [main] section (if present in both files), then enumerates
repos by ID to find added, removed, modified, and unchanged repos.
ยงExamples
use dnf_repofile::{RepoFile, diff_files};
let a = RepoFile::parse("[repo]\nname=Old\nbaseurl=https://a.com/\n").unwrap();
let b = RepoFile::parse("[repo]\nname=New\nbaseurl=https://b.com/\n").unwrap();
let diff = diff_files(&a, &b);
assert!(diff.repos_modified.contains_key(
&dnf_repofile::RepoId::try_new("repo").unwrap()
));