[INFO] cloning repository https://github.com/MatsDK/CLI_File_Explorer [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/MatsDK/CLI_File_Explorer" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FMatsDK%2FCLI_File_Explorer", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FMatsDK%2FCLI_File_Explorer'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] eb93beefbe8d6dff45df0497f9c37595306138a2 [INFO] linting MatsDK/CLI_File_Explorer against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FMatsDK%2FCLI_File_Explorer" "/workspace/builds/worker-1-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-1-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/MatsDK/CLI_File_Explorer [INFO] finished tweaking git repo https://github.com/MatsDK/CLI_File_Explorer [INFO] tweaked toml for git repo https://github.com/MatsDK/CLI_File_Explorer written to /workspace/builds/worker-1-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/MatsDK/CLI_File_Explorer 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 git repo https://github.com/MatsDK/CLI_File_Explorer 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] Blocking waiting for file lock on package cache [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded ryu v1.0.6 [INFO] [stderr] Downloaded ncurses v5.101.0 [INFO] [stderr] Downloaded pkg-config v0.3.22 [INFO] [stderr] Downloaded libc v0.2.108 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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] fa04ce5306a570a7e3d7427a0105fe5f9ed53e75c46061487803632d130b30ef [INFO] running `Command { std: "docker" "start" "-a" "fa04ce5306a570a7e3d7427a0105fe5f9ed53e75c46061487803632d130b30ef", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "fa04ce5306a570a7e3d7427a0105fe5f9ed53e75c46061487803632d130b30ef", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "fa04ce5306a570a7e3d7427a0105fe5f9ed53e75c46061487803632d130b30ef", kill_on_drop: false }` [INFO] [stdout] fa04ce5306a570a7e3d7427a0105fe5f9ed53e75c46061487803632d130b30ef [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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] 1c56f7335ab2dc54992f17e104c7f8f2c8276bb97fafe37ce1c59dfd57c7402a [INFO] running `Command { std: "docker" "start" "-a" "1c56f7335ab2dc54992f17e104c7f8f2c8276bb97fafe37ce1c59dfd57c7402a", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.32 [INFO] [stderr] Compiling syn v1.0.82 [INFO] [stderr] Compiling serde_derive v1.0.130 [INFO] [stderr] Compiling serde v1.0.130 [INFO] [stderr] Compiling pkg-config v0.3.22 [INFO] [stderr] Compiling libc v0.2.108 [INFO] [stderr] Compiling ryu v1.0.6 [INFO] [stderr] Compiling serde_json v1.0.72 [INFO] [stderr] Checking itoa v0.4.8 [INFO] [stderr] Compiling ncurses v5.101.0 [INFO] [stderr] Compiling quote v1.0.10 [INFO] [stderr] Checking rust-command-line-app v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/main.rs:71:24 [INFO] [stdout] | [INFO] [stdout] 71 | addstr(&err); [INFO] [stdout] | ^^^^ help: change this to: `err` [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: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:74:68 [INFO] [stdout] | [INFO] [stdout] 74 | let bottom = format!("height: {} width: {}", height.to_string(), width.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] = note: `#[warn(clippy::to_string_in_format_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:74:87 [INFO] [stdout] | [INFO] [stdout] 74 | let bottom = format!("height: {} width: {}", height.to_string(), width.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`i32` -> `i32`) [INFO] [stdout] --> src/main.rs:87:16 [INFO] [stdout] | [INFO] [stdout] 87 | mv(idx as i32, 1); [INFO] [stdout] | ^^^^^^^^^^ help: try: `idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [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/main.rs:105:9 [INFO] [stdout] | [INFO] [stdout] 105 | / match self.command { [INFO] [stdout] 106 | | CommandType::Error(_) => { [INFO] [stdout] 107 | | self.command = CommandType::None; [INFO] [stdout] 108 | | self.input_value = String::from(""); [INFO] [stdout] ... | [INFO] [stdout] 111 | | _ => {} [INFO] [stdout] 112 | | } [INFO] [stdout] | |_________^ [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] help: try [INFO] [stdout] | [INFO] [stdout] 105 ~ if let CommandType::Error(_) = self.command { [INFO] [stdout] 106 + self.command = CommandType::None; [INFO] [stdout] 107 + self.input_value = String::from(""); [INFO] [stdout] 108 + self.input_cursor = 0; [INFO] [stdout] 109 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:115:20 [INFO] [stdout] | [INFO] [stdout] 115 | 127 => if self.input_value.len() != 0 { // BACKSPACE [INFO] [stdout] | ____________________^ [INFO] [stdout] 116 | | self.input_value.remove(self.input_value.len() - 1); [INFO] [stdout] 117 | | self.input_cursor -= 1; [INFO] [stdout] 118 | | }, [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 115 ~ 127f self.input_value.len() != 0 => { // BACKSPACE [INFO] [stdout] 116 | self.input_value.remove(self.input_value.len() - 1); [INFO] [stdout] 117 ~ self.input_cursor -= 1;, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:115:23 [INFO] [stdout] | [INFO] [stdout] 115 | 127 => if self.input_value.len() != 0 { // BACKSPACE [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!self.input_value.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/main.rs:193:37 [INFO] [stdout] | [INFO] [stdout] 193 | ... r#type: format!("{}", found.unwrap().r#type), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `found.unwrap().r#type.to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] = note: `#[warn(clippy::useless_format)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/main.rs:201:37 [INFO] [stdout] | [INFO] [stdout] 201 | ... r#type: format!("{}", found.unwrap().r#type), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `found.unwrap().r#type.to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/main.rs:258:13 [INFO] [stdout] | [INFO] [stdout] 258 | return (path.to_string(), "".to_string()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 258 - return (path.to_string(), "".to_string()); [INFO] [stdout] 258 + (path.to_string(), "".to_string()) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/main.rs:306:13 [INFO] [stdout] | [INFO] [stdout] 306 | return (real_path, "/".to_string()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 306 - return (real_path, "/".to_string()); [INFO] [stdout] 306 + (real_path, "/".to_string()) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:276:19 [INFO] [stdout] | [INFO] [stdout] 276 | while split.len() != 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!split.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/main.rs:322:28 [INFO] [stdout] | [INFO] [stdout] 322 | x.push_str(&*e.name); [INFO] [stdout] | ^^^^^^^^ help: try: `&e.name` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] = note: `#[warn(clippy::explicit_auto_deref)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:328:48 [INFO] [stdout] | [INFO] [stdout] 328 | r#type: format!("{}l", (*e.r#type).to_string()), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: use this: `&(*e.r#type)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/main.rs:336:28 [INFO] [stdout] | [INFO] [stdout] 336 | x.push_str(&*e.name); [INFO] [stdout] | ^^^^^^^^ help: try: `&e.name` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/main.rs:424:81 [INFO] [stdout] | [INFO] [stdout] 424 | fn list_down(file_curr: &mut usize, top_offset: &mut i32, max_y: &i32, entries: &Vec) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 424 - fn list_down(file_curr: &mut usize, top_offset: &mut i32, max_y: &i32, entries: &Vec) { [INFO] [stdout] 424 + fn list_down(file_curr: &mut usize, top_offset: &mut i32, max_y: &i32, entries: &[tree::Entry]) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:425:8 [INFO] [stdout] | [INFO] [stdout] 425 | if entries.len() > 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `i32` [INFO] [stdout] --> src/main.rs:429:34 [INFO] [stdout] | [INFO] [stdout] 429 | if (*file_curr as i32) > x.try_into().unwrap() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider removing `.try_into()` [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:486:20 [INFO] [stdout] | [INFO] [stdout] 486 | if !select_start.is_none() && [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: try: `select_start.is_some()` [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 `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:510:28 [INFO] [stdout] | [INFO] [stdout] 510 | 'd' => if entries.len() != 0 { ui.command = CommandType::Delete }, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 510 - 'd' => if entries.len() != 0 { ui.command = CommandType::Delete }, [INFO] [stdout] 510 + 'd'f entries.len() != 0 => { ui.command = CommandType::Delete, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:528:29 [INFO] [stdout] | [INFO] [stdout] 528 | ... '\n' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | _______________^ [INFO] [stdout] 529 | | ... ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] 530 | | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] 531 | | ... ui.set_entries(&mut entries); [INFO] [stdout] ... | [INFO] [stdout] 536 | | ... ui.set_parent_path(); [INFO] [stdout] 537 | | ... } [INFO] [stdout] | |_______^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 528 ~ '\n'f entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") => { [INFO] [stdout] 529 | ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] ... [INFO] [stdout] 535 | [INFO] [stdout] 536 ~ ui.set_parent_path(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:538:28 [INFO] [stdout] | [INFO] [stdout] 538 | ... 'l' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | ______________^ [INFO] [stdout] 539 | | ... ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] 540 | | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] 541 | | ... ui.set_entries(&mut entries); [INFO] [stdout] ... | [INFO] [stdout] 546 | | ... ui.set_parent_path(); [INFO] [stdout] 547 | | ... }, [INFO] [stdout] | |_______^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 538 ~ 'l'f entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") => { [INFO] [stdout] 539 | ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] ... [INFO] [stdout] 545 | [INFO] [stdout] 546 ~ ui.set_parent_path();, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:510:31 [INFO] [stdout] | [INFO] [stdout] 510 | 'd' => if entries.len() != 0 { ui.command = CommandType::Delete }, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:528:32 [INFO] [stdout] | [INFO] [stdout] 528 | '\n' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:530:124 [INFO] [stdout] | [INFO] [stdout] 530 | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:538:31 [INFO] [stdout] | [INFO] [stdout] 538 | 'l' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:540:124 [INFO] [stdout] | [INFO] [stdout] 540 | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/main.rs:71:24 [INFO] [stdout] | [INFO] [stdout] 71 | addstr(&err); [INFO] [stdout] | ^^^^ help: change this to: `err` [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: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:74:68 [INFO] [stdout] | [INFO] [stdout] 74 | let bottom = format!("height: {} width: {}", height.to_string(), width.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] = note: `#[warn(clippy::to_string_in_format_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:74:87 [INFO] [stdout] | [INFO] [stdout] 74 | let bottom = format!("height: {} width: {}", height.to_string(), width.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`i32` -> `i32`) [INFO] [stdout] --> src/main.rs:87:16 [INFO] [stdout] | [INFO] [stdout] 87 | mv(idx as i32, 1); [INFO] [stdout] | ^^^^^^^^^^ help: try: `idx` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [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/main.rs:105:9 [INFO] [stdout] | [INFO] [stdout] 105 | / match self.command { [INFO] [stdout] 106 | | CommandType::Error(_) => { [INFO] [stdout] 107 | | self.command = CommandType::None; [INFO] [stdout] 108 | | self.input_value = String::from(""); [INFO] [stdout] ... | [INFO] [stdout] 111 | | _ => {} [INFO] [stdout] 112 | | } [INFO] [stdout] | |_________^ [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] help: try [INFO] [stdout] | [INFO] [stdout] 105 ~ if let CommandType::Error(_) = self.command { [INFO] [stdout] 106 + self.command = CommandType::None; [INFO] [stdout] 107 + self.input_value = String::from(""); [INFO] [stdout] 108 + self.input_cursor = 0; [INFO] [stdout] 109 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:115:20 [INFO] [stdout] | [INFO] [stdout] 115 | 127 => if self.input_value.len() != 0 { // BACKSPACE [INFO] [stdout] | ____________________^ [INFO] [stdout] 116 | | self.input_value.remove(self.input_value.len() - 1); [INFO] [stdout] 117 | | self.input_cursor -= 1; [INFO] [stdout] 118 | | }, [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 115 ~ 127f self.input_value.len() != 0 => { // BACKSPACE [INFO] [stdout] 116 | self.input_value.remove(self.input_value.len() - 1); [INFO] [stdout] 117 ~ self.input_cursor -= 1;, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:115:23 [INFO] [stdout] | [INFO] [stdout] 115 | 127 => if self.input_value.len() != 0 { // BACKSPACE [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!self.input_value.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/main.rs:193:37 [INFO] [stdout] | [INFO] [stdout] 193 | ... r#type: format!("{}", found.unwrap().r#type), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `found.unwrap().r#type.to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] = note: `#[warn(clippy::useless_format)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/main.rs:201:37 [INFO] [stdout] | [INFO] [stdout] 201 | ... r#type: format!("{}", found.unwrap().r#type), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `found.unwrap().r#type.to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/main.rs:258:13 [INFO] [stdout] | [INFO] [stdout] 258 | return (path.to_string(), "".to_string()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 258 - return (path.to_string(), "".to_string()); [INFO] [stdout] 258 + (path.to_string(), "".to_string()) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/main.rs:306:13 [INFO] [stdout] | [INFO] [stdout] 306 | return (real_path, "/".to_string()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 306 - return (real_path, "/".to_string()); [INFO] [stdout] 306 + (real_path, "/".to_string()) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:276:19 [INFO] [stdout] | [INFO] [stdout] 276 | while split.len() != 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!split.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/main.rs:322:28 [INFO] [stdout] | [INFO] [stdout] 322 | x.push_str(&*e.name); [INFO] [stdout] | ^^^^^^^^ help: try: `&e.name` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] = note: `#[warn(clippy::explicit_auto_deref)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:328:48 [INFO] [stdout] | [INFO] [stdout] 328 | r#type: format!("{}l", (*e.r#type).to_string()), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: use this: `&(*e.r#type)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: deref which would be done by auto-deref [INFO] [stdout] --> src/main.rs:336:28 [INFO] [stdout] | [INFO] [stdout] 336 | x.push_str(&*e.name); [INFO] [stdout] | ^^^^^^^^ help: try: `&e.name` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/main.rs:424:81 [INFO] [stdout] | [INFO] [stdout] 424 | fn list_down(file_curr: &mut usize, top_offset: &mut i32, max_y: &i32, entries: &Vec) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 424 - fn list_down(file_curr: &mut usize, top_offset: &mut i32, max_y: &i32, entries: &Vec) { [INFO] [stdout] 424 + fn list_down(file_curr: &mut usize, top_offset: &mut i32, max_y: &i32, entries: &[tree::Entry]) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:425:8 [INFO] [stdout] | [INFO] [stdout] 425 | if entries.len() > 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `i32` [INFO] [stdout] --> src/main.rs:429:34 [INFO] [stdout] | [INFO] [stdout] 429 | if (*file_curr as i32) > x.try_into().unwrap() { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider removing `.try_into()` [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/main.rs:486:20 [INFO] [stdout] | [INFO] [stdout] 486 | if !select_start.is_none() && [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: try: `select_start.is_some()` [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 `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:510:28 [INFO] [stdout] | [INFO] [stdout] 510 | 'd' => if entries.len() != 0 { ui.command = CommandType::Delete }, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 510 - 'd' => if entries.len() != 0 { ui.command = CommandType::Delete }, [INFO] [stdout] 510 + 'd'f entries.len() != 0 => { ui.command = CommandType::Delete, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:528:29 [INFO] [stdout] | [INFO] [stdout] 528 | ... '\n' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | _______________^ [INFO] [stdout] 529 | | ... ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] 530 | | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] 531 | | ... ui.set_entries(&mut entries); [INFO] [stdout] ... | [INFO] [stdout] 536 | | ... ui.set_parent_path(); [INFO] [stdout] 537 | | ... } [INFO] [stdout] | |_______^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 528 ~ '\n'f entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") => { [INFO] [stdout] 529 | ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] ... [INFO] [stdout] 535 | [INFO] [stdout] 536 ~ ui.set_parent_path(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/main.rs:538:28 [INFO] [stdout] | [INFO] [stdout] 538 | ... 'l' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | ______________^ [INFO] [stdout] 539 | | ... ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] 540 | | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] 541 | | ... ui.set_entries(&mut entries); [INFO] [stdout] ... | [INFO] [stdout] 546 | | ... ui.set_parent_path(); [INFO] [stdout] 547 | | ... }, [INFO] [stdout] | |_______^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 538 ~ 'l'f entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") => { [INFO] [stdout] 539 | ui.curr_path = format!("{}{}{}", ui.curr_path, [INFO] [stdout] ... [INFO] [stdout] 545 | [INFO] [stdout] 546 ~ ui.set_parent_path();, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:510:31 [INFO] [stdout] | [INFO] [stdout] 510 | 'd' => if entries.len() != 0 { ui.command = CommandType::Delete }, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:528:32 [INFO] [stdout] | [INFO] [stdout] 528 | '\n' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:530:124 [INFO] [stdout] | [INFO] [stdout] 530 | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/main.rs:538:31 [INFO] [stdout] | [INFO] [stdout] 538 | 'l' => if entries.len() != 0 && (entries[file_curr].r#type == "d" || entries[file_curr].r#type == "dl") { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!entries.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> src/main.rs:540:124 [INFO] [stdout] | [INFO] [stdout] 540 | ... { if ui.curr_path == "/" { "" } else { "/" } }, entries[file_curr].name.to_string()); [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 10.13s [INFO] running `Command { std: "docker" "inspect" "1c56f7335ab2dc54992f17e104c7f8f2c8276bb97fafe37ce1c59dfd57c7402a", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "1c56f7335ab2dc54992f17e104c7f8f2c8276bb97fafe37ce1c59dfd57c7402a", kill_on_drop: false }` [INFO] [stdout] 1c56f7335ab2dc54992f17e104c7f8f2c8276bb97fafe37ce1c59dfd57c7402a