[INFO] fetching crate async-git 0.0.0-squat-name... [INFO] linting async-git-0.0.0-squat-name against nightly for clippy-nonminimal_bool-denied [INFO] extracting crate async-git 0.0.0-squat-name into /workspace/builds/worker-0-tc1/source [INFO] started tweaking crates.io crate async-git 0.0.0-squat-name [INFO] finished tweaking crates.io crate async-git 0.0.0-squat-name [INFO] tweaked toml for crates.io crate async-git 0.0.0-squat-name written to /workspace/builds/worker-0-tc1/source/Cargo.toml [INFO] validating manifest of crates.io crate async-git 0.0.0-squat-name on toolchain nightly [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate crates.io crate async-git 0.0.0-squat-name already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded thiserror-impl v1.0.15 [INFO] [stderr] Downloaded futures v0.3.4 [INFO] [stderr] Downloaded async-compression v0.3.2 [INFO] [stderr] Downloaded thiserror v1.0.15 [INFO] [stderr] Downloaded futures-io v0.3.4 [INFO] [stderr] Downloaded tokio v0.2.18 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 7fb554f8a5b65fa4d46888af1c11614c6d6ef12556fba47a316d60a9b8221090 [INFO] running `Command { std: "docker" "start" "-a" "7fb554f8a5b65fa4d46888af1c11614c6d6ef12556fba47a316d60a9b8221090", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "7fb554f8a5b65fa4d46888af1c11614c6d6ef12556fba47a316d60a9b8221090", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "7fb554f8a5b65fa4d46888af1c11614c6d6ef12556fba47a316d60a9b8221090", kill_on_drop: false }` [INFO] [stdout] 7fb554f8a5b65fa4d46888af1c11614c6d6ef12556fba47a316d60a9b8221090 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "clippy" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] bdeb3bf613d2f278d378184226b98c3ac03141b7170fd88956b47ca2eb6db5ed [INFO] running `Command { std: "docker" "start" "-a" "bdeb3bf613d2f278d378184226b98c3ac03141b7170fd88956b47ca2eb6db5ed", kill_on_drop: false }` [INFO] [stderr] Compiling syn v1.0.18 [INFO] [stderr] Checking futures-core v0.3.4 [INFO] [stderr] Compiling crc32fast v1.2.0 [INFO] [stderr] Checking bytes v0.4.12 [INFO] [stderr] Checking futures-io v0.3.4 [INFO] [stderr] Checking futures-sink v0.3.4 [INFO] [stderr] Checking adler32 v1.0.4 [INFO] [stderr] Checking futures-task v0.3.4 [INFO] [stderr] Checking clap v2.33.0 [INFO] [stderr] Checking futures-channel v0.3.4 [INFO] [stderr] Checking miniz_oxide v0.3.6 [INFO] [stderr] Checking block-buffer v0.7.3 [INFO] [stderr] Checking digest v0.8.1 [INFO] [stderr] Checking fake-simd v0.1.2 [INFO] [stderr] Checking tokio-io v0.1.13 [INFO] [stderr] Checking sha-1 v0.8.2 [INFO] [stderr] Checking flate2 v1.0.14 [INFO] [stderr] Checking futures-util v0.3.4 [INFO] [stderr] Checking async-compression v0.3.2 [INFO] [stderr] Checking futures v0.3.4 [INFO] [stderr] Compiling syn-mid v0.5.0 [INFO] [stderr] Compiling proc-macro-error-attr v1.0.2 [INFO] [stderr] Compiling tokio-macros v0.2.5 [INFO] [stderr] Compiling thiserror-impl v1.0.15 [INFO] [stderr] Compiling proc-macro-error v1.0.2 [INFO] [stderr] Checking tokio v0.2.18 [INFO] [stderr] Compiling structopt-derive v0.4.7 [INFO] [stderr] Checking thiserror v1.0.15 [INFO] [stderr] Checking structopt v0.3.14 [INFO] [stderr] Checking async-git v0.0.0-squat-name (/opt/rustwide/workdir) [INFO] [stdout] warning: unused variable: `size` [INFO] [stdout] --> src/plumbing/commit.rs:22:13 [INFO] [stdout] | [INFO] [stdout] 22 | let size = { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_size` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `w` [INFO] [stdout] --> src/plumbing/commit.rs:85:53 [INFO] [stdout] | [INFO] [stdout] 85 | pub async fn write(self, w: W) -> Result<(), IOError> { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_w` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `options` [INFO] [stdout] --> src/plumbing/interrogators/rev_parse.rs:4:22 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn rev_parse_cmd(options: RevParseOptions) {} [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_options` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `size` [INFO] [stdout] --> src/plumbing/commit.rs:22:13 [INFO] [stdout] | [INFO] [stdout] 22 | let size = { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_size` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `w` [INFO] [stdout] --> src/plumbing/commit.rs:85:53 [INFO] [stdout] | [INFO] [stdout] 85 | pub async fn write(self, w: W) -> Result<(), IOError> { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_w` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `options` [INFO] [stdout] --> src/porcelain/log.rs:9:22 [INFO] [stdout] | [INFO] [stdout] 9 | pub async fn log_cmd(options: LogOptions) -> Result<()> { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_options` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `options` [INFO] [stdout] --> src/plumbing/interrogators/rev_parse.rs:4:22 [INFO] [stdout] | [INFO] [stdout] 4 | pub fn rev_parse_cmd(options: RevParseOptions) {} [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_options` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `tree`, `parents`, `author`, `committer`, `gpgsig`, and `message` are never read [INFO] [stdout] --> src/plumbing/commit.rs:11:5 [INFO] [stdout] | [INFO] [stdout] 10 | pub struct Commit { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 11 | tree: Oid, [INFO] [stdout] | ^^^^ [INFO] [stdout] 12 | parents: Vec, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] 13 | author: String, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 14 | committer: String, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] 15 | gpgsig: Option, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 16 | message: String, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Commit` has derived impls for the traits `Debug` and `Clone`, but these are intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `target` is never read [INFO] [stdout] --> src/plumbing/ref.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct Ref { [INFO] [stdout] | --- field in this struct [INFO] [stdout] 5 | target: Option, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `template` is never read [INFO] [stdout] --> src/porcelain/init.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 11 | pub struct InitOptions { [INFO] [stdout] | ----------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 14 | template: Option, [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `InitOptions` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `commit` is never read [INFO] [stdout] --> src/porcelain/log.rs:6:5 [INFO] [stdout] | [INFO] [stdout] 5 | pub struct LogOptions { [INFO] [stdout] | ---------- field in this struct [INFO] [stdout] 6 | commit: Oid, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `LogOptions` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ZlibIO` is never used [INFO] [stdout] --> src/util/mod.rs:17:11 [INFO] [stdout] | [INFO] [stdout] 17 | pub trait ZlibIO {} [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/plumbing/commit.rs:42:53 [INFO] [stdout] | [INFO] [stdout] 42 | "tree" => tree = Some(Oid::from_str(&value)?), [INFO] [stdout] | ^^^^^^ help: change this to: `value` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/plumbing/commit.rs:43:56 [INFO] [stdout] | [INFO] [stdout] 43 | "parent" => parents.push(Oid::from_str(&value)?), [INFO] [stdout] | ^^^^^^ help: change this to: `value` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: stripping a prefix manually [INFO] [stdout] --> src/plumbing/commit.rs:59:30 [INFO] [stdout] | [INFO] [stdout] 59 | prev_line += &this_line[1..]; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: the prefix was tested here [INFO] [stdout] --> src/plumbing/commit.rs:58:13 [INFO] [stdout] | [INFO] [stdout] 58 | if this_line.starts_with(" ") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_strip [INFO] [stdout] = note: `#[warn(clippy::manual_strip)]` on by default [INFO] [stdout] help: try using the `strip_prefix` method [INFO] [stdout] | [INFO] [stdout] 58 ~ if let Some() = this_line.strip_prefix(" ") { [INFO] [stdout] 59 ~ prev_line += ; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` branch is empty [INFO] [stdout] --> src/plumbing/ref.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 11 | if string.starts_with("ref") {} [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: you can remove it: `string.starts_with("ref");` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_ifs [INFO] [stdout] = note: `#[warn(clippy::needless_ifs)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enclosing `Ok` and `?` operator are unneeded [INFO] [stdout] --> src/plumbing/repo.rs:29:9 [INFO] [stdout] | [INFO] [stdout] 29 | Ok(Ref::parse(head_ref.trim())?) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_question_mark [INFO] [stdout] = note: `#[warn(clippy::needless_question_mark)]` on by default [INFO] [stdout] help: remove the enclosing `Ok` and `?` operator [INFO] [stdout] | [INFO] [stdout] 29 - Ok(Ref::parse(head_ref.trim())?) [INFO] [stdout] 29 + Ref::parse(head_ref.trim()) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/plumbing/repo.rs:58:16 [INFO] [stdout] | [INFO] [stdout] 58 | if !Oid::from_str(&contents).is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Oid::from_str(&contents).is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/plumbing/repo.rs:58:31 [INFO] [stdout] | [INFO] [stdout] 58 | if !Oid::from_str(&contents).is_ok() { [INFO] [stdout] | ^^^^^^^^^ help: change this to: `contents` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/plumbing/repo.rs:104:24 [INFO] [stdout] | [INFO] [stdout] 104 | } else if dot_git.is_dir() { [INFO] [stdout] | ________________________^ [INFO] [stdout] 105 | | if Repository::is_repo(&dot_git).await? { [INFO] [stdout] 106 | | return Ok(Some(dot_git)); [INFO] [stdout] 107 | | } [INFO] [stdout] 108 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] = note: `#[warn(clippy::collapsible_if)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 104 ~ } else if dot_git.is_dir() [INFO] [stdout] 105 ~ && Repository::is_repo(&dot_git).await? { [INFO] [stdout] 106 | return Ok(Some(dot_git)); [INFO] [stdout] 107 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `options` [INFO] [stdout] --> src/porcelain/log.rs:9:22 [INFO] [stdout] | [INFO] [stdout] 9 | pub async fn log_cmd(options: LogOptions) -> Result<()> { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_options` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let` [INFO] [stdout] --> src/porcelain/show.rs:22:9 [INFO] [stdout] | [INFO] [stdout] 22 | / match &parsed_object { [INFO] [stdout] 23 | | ParsedObject::Commit(commit) => show_commit(commit), [INFO] [stdout] 24 | | _ => (), [INFO] [stdout] 25 | | } [INFO] [stdout] | |_________^ help: try: `if let ParsedObject::Commit(commit) = &parsed_object { show_commit(commit) }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match [INFO] [stdout] = note: `#[warn(clippy::single_match)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `tree`, `parents`, `author`, `committer`, `gpgsig`, and `message` are never read [INFO] [stdout] --> src/plumbing/commit.rs:11:5 [INFO] [stdout] | [INFO] [stdout] 10 | pub struct Commit { [INFO] [stdout] | ------ fields in this struct [INFO] [stdout] 11 | tree: Oid, [INFO] [stdout] | ^^^^ [INFO] [stdout] 12 | parents: Vec, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] 13 | author: String, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 14 | committer: String, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] 15 | gpgsig: Option, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 16 | message: String, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Commit` has derived impls for the traits `Debug` and `Clone`, but these are intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `target` is never read [INFO] [stdout] --> src/plumbing/ref.rs:5:5 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct Ref { [INFO] [stdout] | --- field in this struct [INFO] [stdout] 5 | target: Option, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `template` is never read [INFO] [stdout] --> src/porcelain/init.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 11 | pub struct InitOptions { [INFO] [stdout] | ----------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 14 | template: Option, [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `InitOptions` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `commit` is never read [INFO] [stdout] --> src/porcelain/log.rs:6:5 [INFO] [stdout] | [INFO] [stdout] 5 | pub struct LogOptions { [INFO] [stdout] | ---------- field in this struct [INFO] [stdout] 6 | commit: Oid, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `LogOptions` has a derived impl for the trait `Debug`, but this is intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: trait `ZlibIO` is never used [INFO] [stdout] --> src/util/mod.rs:17:11 [INFO] [stdout] | [INFO] [stdout] 17 | pub trait ZlibIO {} [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/plumbing/commit.rs:42:53 [INFO] [stdout] | [INFO] [stdout] 42 | "tree" => tree = Some(Oid::from_str(&value)?), [INFO] [stdout] | ^^^^^^ help: change this to: `value` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/plumbing/commit.rs:43:56 [INFO] [stdout] | [INFO] [stdout] 43 | "parent" => parents.push(Oid::from_str(&value)?), [INFO] [stdout] | ^^^^^^ help: change this to: `value` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: stripping a prefix manually [INFO] [stdout] --> src/plumbing/commit.rs:59:30 [INFO] [stdout] | [INFO] [stdout] 59 | prev_line += &this_line[1..]; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: the prefix was tested here [INFO] [stdout] --> src/plumbing/commit.rs:58:13 [INFO] [stdout] | [INFO] [stdout] 58 | if this_line.starts_with(" ") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_strip [INFO] [stdout] = note: `#[warn(clippy::manual_strip)]` on by default [INFO] [stdout] help: try using the `strip_prefix` method [INFO] [stdout] | [INFO] [stdout] 58 ~ if let Some() = this_line.strip_prefix(" ") { [INFO] [stdout] 59 ~ prev_line += ; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` branch is empty [INFO] [stdout] --> src/plumbing/ref.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 11 | if string.starts_with("ref") {} [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: you can remove it: `string.starts_with("ref");` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_ifs [INFO] [stdout] = note: `#[warn(clippy::needless_ifs)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: enclosing `Ok` and `?` operator are unneeded [INFO] [stdout] --> src/plumbing/repo.rs:29:9 [INFO] [stdout] | [INFO] [stdout] 29 | Ok(Ref::parse(head_ref.trim())?) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_question_mark [INFO] [stdout] = note: `#[warn(clippy::needless_question_mark)]` on by default [INFO] [stdout] help: remove the enclosing `Ok` and `?` operator [INFO] [stdout] | [INFO] [stdout] 29 - Ok(Ref::parse(head_ref.trim())?) [INFO] [stdout] 29 + Ref::parse(head_ref.trim()) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/plumbing/repo.rs:58:16 [INFO] [stdout] | [INFO] [stdout] 58 | if !Oid::from_str(&contents).is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Oid::from_str(&contents).is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/plumbing/repo.rs:58:31 [INFO] [stdout] | [INFO] [stdout] 58 | if !Oid::from_str(&contents).is_ok() { [INFO] [stdout] | ^^^^^^^^^ help: change this to: `contents` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` statement can be collapsed [INFO] [stdout] --> src/plumbing/repo.rs:104:24 [INFO] [stdout] | [INFO] [stdout] 104 | } else if dot_git.is_dir() { [INFO] [stdout] | ________________________^ [INFO] [stdout] 105 | | if Repository::is_repo(&dot_git).await? { [INFO] [stdout] 106 | | return Ok(Some(dot_git)); [INFO] [stdout] 107 | | } [INFO] [stdout] 108 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if [INFO] [stdout] = note: `#[warn(clippy::collapsible_if)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 104 ~ } else if dot_git.is_dir() [INFO] [stdout] 105 ~ && Repository::is_repo(&dot_git).await? { [INFO] [stdout] 106 | return Ok(Some(dot_git)); [INFO] [stdout] 107 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let` [INFO] [stdout] --> src/porcelain/show.rs:22:9 [INFO] [stdout] | [INFO] [stdout] 22 | / match &parsed_object { [INFO] [stdout] 23 | | ParsedObject::Commit(commit) => show_commit(commit), [INFO] [stdout] 24 | | _ => (), [INFO] [stdout] 25 | | } [INFO] [stdout] | |_________^ help: try: `if let ParsedObject::Commit(commit) = &parsed_object { show_commit(commit) }` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match [INFO] [stdout] = note: `#[warn(clippy::single_match)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 15.45s [INFO] running `Command { std: "docker" "inspect" "bdeb3bf613d2f278d378184226b98c3ac03141b7170fd88956b47ca2eb6db5ed", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "bdeb3bf613d2f278d378184226b98c3ac03141b7170fd88956b47ca2eb6db5ed", kill_on_drop: false }` [INFO] [stdout] bdeb3bf613d2f278d378184226b98c3ac03141b7170fd88956b47ca2eb6db5ed