radicle-surf: refactor the design: part 3

- Detect renames in Diff by default.
- Remove Vcs trait.
- Move `history()` to be a regular method of RepositoryRef.
- Update design doc.

Signed-off-by: Han Xu <keepsimple@gmail.com>
This commit is contained in:
Han Xu
2022-10-18 22:31:38 -07:00
parent 207b55494e
commit a4bc76f2ea
6 changed files with 86 additions and 130 deletions
+2 -5
View File
@@ -30,10 +30,7 @@ use crate::{
file_system,
person::Person,
revision::Revision,
vcs::{
git::{self, BranchName, RepositoryRef, Rev},
Vcs,
},
vcs::git::{self, BranchName, RepositoryRef, Rev},
};
use radicle_git_ext::Oid;
@@ -244,7 +241,7 @@ where
};
let stats = repo.get_stats(&rev)?;
let headers = repo.get_history(rev)?.iter().map(Header::from).collect();
let headers = repo.history(rev)?.iter().map(Header::from).collect();
Ok(Commits { headers, stats })
}