fix warnings and deny deprecated (#2753)

* fix gitoxide warning

* do not allow deprecated fn
This commit is contained in:
extrawurst
2025-10-28 18:03:19 +01:00
committed by GitHub
parent 88ace76db5
commit 6bb216c0d4
4 changed files with 16 additions and 39 deletions
+2 -1
View File
@@ -15,7 +15,8 @@ It wraps libraries like git2 and gix.
unused_must_use,
dead_code,
unstable_name_collisions,
unused_assignments
unused_assignments,
deprecated
)]
#![deny(clippy::all, clippy::perf, clippy::nursery, clippy::pedantic)]
#![deny(
+1 -1
View File
@@ -133,7 +133,7 @@ impl<'a> LogWalkerWithoutFilter<'a> {
// reason this is 2^14, so benchmarking might reveal that there’s better values.
repo.object_cache_size_if_unset(2_usize.pow(14));
let commit = repo.head()?.peel_to_commit_in_place()?;
let commit = repo.head()?.peel_to_commit()?;
let tips = [commit.id];
+12 -36
View File
@@ -369,12 +369,8 @@ mod tests {
let (remote_dir, _remote) = repo_init().unwrap();
let remote_path = remote_dir.path().to_str().unwrap();
let (repo_dir, _repo) = repo_clone(remote_path).unwrap();
let repo_path: &RepoPath = &repo_dir
.into_path()
.as_os_str()
.to_str()
.unwrap()
.into();
let repo_path: &RepoPath =
&repo_dir.keep().as_os_str().to_str().unwrap().into();
let remotes = get_remotes(repo_path).unwrap();
@@ -388,12 +384,8 @@ mod tests {
let (remote_dir, _remote) = repo_init().unwrap();
let remote_path = remote_dir.path().to_str().unwrap();
let (repo_dir, _repo) = repo_clone(remote_path).unwrap();
let repo_path: &RepoPath = &repo_dir
.into_path()
.as_os_str()
.to_str()
.unwrap()
.into();
let repo_path: &RepoPath =
&repo_dir.keep().as_os_str().to_str().unwrap().into();
debug_cmd_print(
repo_path,
@@ -418,12 +410,8 @@ mod tests {
let (remote_dir, _remote) = repo_init().unwrap();
let remote_path = remote_dir.path().to_str().unwrap();
let (repo_dir, _repo) = repo_clone(remote_path).unwrap();
let repo_path: &RepoPath = &repo_dir
.into_path()
.as_os_str()
.to_str()
.unwrap()
.into();
let repo_path: &RepoPath =
&repo_dir.keep().as_os_str().to_str().unwrap().into();
debug_cmd_print(
repo_path,
@@ -454,12 +442,8 @@ mod tests {
let (remote_dir, _remote) = repo_init().unwrap();
let remote_path = remote_dir.path().to_str().unwrap();
let (repo_dir, _repo) = repo_clone(remote_path).unwrap();
let repo_path: &RepoPath = &repo_dir
.into_path()
.as_os_str()
.to_str()
.unwrap()
.into();
let repo_path: &RepoPath =
&repo_dir.keep().as_os_str().to_str().unwrap().into();
debug_cmd_print(
repo_path,
@@ -494,12 +478,8 @@ mod tests {
let (remote_dir, _remote) = repo_init().unwrap();
let remote_path = remote_dir.path().to_str().unwrap();
let (repo_dir, repo) = repo_clone(remote_path).unwrap();
let repo_path: &RepoPath = &repo_dir
.into_path()
.as_os_str()
.to_str()
.unwrap()
.into();
let repo_path: &RepoPath =
&repo_dir.keep().as_os_str().to_str().unwrap().into();
debug_cmd_print(
repo_path,
@@ -530,12 +510,8 @@ mod tests {
let (remote_dir, _remote) = repo_init().unwrap();
let remote_path = remote_dir.path().to_str().unwrap();
let (repo_dir, repo) = repo_clone(remote_path).unwrap();
let repo_path: &RepoPath = &repo_dir
.into_path()
.as_os_str()
.to_str()
.unwrap()
.into();
let repo_path: &RepoPath =
&repo_dir.keep().as_os_str().to_str().unwrap().into();
debug_cmd_print(
repo_path,
+1 -1
View File
@@ -182,7 +182,7 @@ mod tests {
s.add_finalize().unwrap();
}
let repo_p = RepoPath::Path(dir.into_path());
let repo_p = RepoPath::Path(dir.keep());
let subs = get_submodules(&repo_p).unwrap();
assert_eq!(subs.len(), 1);