Skip to content

Commit 6e12c1e

Browse files
committed
fix clippy and nightly build
1 parent c57543b commit 6e12c1e

File tree

7 files changed

+15
-20
lines changed

7 files changed

+15
-20
lines changed

asyncgit/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222
#![allow(
2323
clippy::module_name_repetitions,
2424
clippy::must_use_candidate,
25-
clippy::missing_errors_doc
25+
clippy::missing_errors_doc,
26+
clippy::empty_docs
2627
)]
2728
//TODO:
2829
#![allow(

filetreelist/src/lib.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,12 @@
1515
#![deny(clippy::panic)]
1616
#![deny(clippy::match_like_matches_macro)]
1717
#![deny(clippy::needless_update)]
18-
#![allow(clippy::module_name_repetitions)]
19-
#![allow(clippy::must_use_candidate)]
20-
#![allow(clippy::missing_errors_doc)]
18+
#![allow(
19+
clippy::module_name_repetitions,
20+
clippy::must_use_candidate,
21+
clippy::missing_errors_doc,
22+
clippy::empty_docs
23+
)]
2124

2225
mod error;
2326
mod filetree;

git2-hooks/src/error.rs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,20 @@
11
use thiserror::Error;
22

3-
///
3+
/// crate specific error type
44
#[derive(Error, Debug)]
55
pub enum HooksError {
6-
///
76
#[error("git error:{0}")]
87
Git(#[from] git2::Error),
98

10-
///
119
#[error("io error:{0}")]
1210
Io(#[from] std::io::Error),
1311

14-
///
1512
#[error("path string conversion error")]
1613
PathToString,
1714

18-
///
1915
#[error("shellexpand error:{0}")]
2016
ShellExpand(#[from] shellexpand::LookupError<std::env::VarError>),
2117
}
2218

23-
///
19+
/// crate specific `Result` type
2420
pub type Result<T> = std::result::Result<T, HooksError>;

git2-hooks/src/lib.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ pub const HOOK_PREPARE_COMMIT_MSG: &str = "prepare-commit-msg";
4646

4747
const HOOK_COMMIT_MSG_TEMP_FILE: &str = "COMMIT_EDITMSG";
4848

49-
///
5049
#[derive(Debug, PartialEq, Eq)]
5150
pub enum HookResult {
5251
/// No hook found
@@ -171,7 +170,6 @@ pub fn hooks_post_commit(
171170
hook.run_hook(&[])
172171
}
173172

174-
///
175173
pub enum PrepareCommitMsgSource {
176174
Message,
177175
Template,

git2-testing/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use git2::Repository;
22
use tempfile::TempDir;
33

4-
///
4+
/// initialize test repo in temp path
55
pub fn repo_init_empty() -> (TempDir, Repository) {
66
init_log();
77

@@ -18,7 +18,7 @@ pub fn repo_init_empty() -> (TempDir, Repository) {
1818
(td, repo)
1919
}
2020

21-
///
21+
/// initialize test repo in temp path with an empty first commit
2222
pub fn repo_init() -> (TempDir, Repository) {
2323
init_log();
2424

scopetime/src/lib.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
//! simple macro to insert a scope based runtime measure that logs the result
22
33
#![forbid(unsafe_code)]
4-
#![forbid(missing_docs)]
54
#![deny(unused_imports)]
65
#![deny(clippy::unwrap_used)]
76
#![deny(clippy::perf)]
87

98
use std::time::Instant;
109

11-
///
1210
pub struct ScopeTimeLog<'a> {
1311
title: &'a str,
1412
mod_path: &'a str,
@@ -17,9 +15,7 @@ pub struct ScopeTimeLog<'a> {
1715
time: Instant,
1816
}
1917

20-
///
2118
impl<'a> ScopeTimeLog<'a> {
22-
///
2319
pub fn new(
2420
mod_path: &'a str,
2521
title: &'a str,
@@ -49,7 +45,7 @@ impl<'a> Drop for ScopeTimeLog<'a> {
4945
}
5046
}
5147

52-
///
48+
/// measures runtime of scope and prints it into log
5349
#[cfg(feature = "enabled")]
5450
#[macro_export]
5551
macro_rules! scope_time {

src/main.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@
1919
#![allow(
2020
clippy::multiple_crate_versions,
2121
clippy::bool_to_int_with_if,
22-
clippy::module_name_repetitions
22+
clippy::module_name_repetitions,
23+
clippy::empty_docs
2324
)]
2425

2526
//TODO:

0 commit comments

Comments
 (0)