[INFO] fetching crate funzzy 1.5.0... [INFO] linting funzzy-1.5.0 against nightly for clippy-nonminimal_bool-denied [INFO] extracting crate funzzy 1.5.0 into /workspace/builds/worker-4-tc1/source [INFO] started tweaking crates.io crate funzzy 1.5.0 [INFO] removed 0 missing tests [INFO] finished tweaking crates.io crate funzzy 1.5.0 [INFO] tweaked toml for crates.io crate funzzy 1.5.0 written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] validating manifest of crates.io crate funzzy 1.5.0 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 funzzy 1.5.0 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] warning: file `/workspace/builds/worker-4-tc1/source/src/main.rs` found to be present in multiple build targets: [INFO] [stderr] * `bin` target `funzzy` [INFO] [stderr] * `bin` target `fzz` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded inotify v0.7.1 [INFO] [stderr] Downloaded anstyle v1.0.9 [INFO] [stderr] Downloaded notify v4.0.18 [INFO] [stderr] Downloaded fsevent v0.4.0 [INFO] [stderr] Downloaded serde v1.0.213 [INFO] [stderr] Downloaded docopt v1.1.1 [INFO] [stderr] Downloaded fsevent-sys v2.0.1 [INFO] [stderr] Downloaded notify-debouncer-mini v0.3.0 [INFO] [stderr] Downloaded serde_derive v1.0.213 [INFO] [stderr] Downloaded syn v2.0.85 [INFO] [stderr] Downloaded libc v0.2.161 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-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] eabfaad354bf45a2d07f7ad486cd5bfbf819f89d68ae0f1aeb310fb720e0bd00 [INFO] running `Command { std: "docker" "start" "-a" "eabfaad354bf45a2d07f7ad486cd5bfbf819f89d68ae0f1aeb310fb720e0bd00", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "eabfaad354bf45a2d07f7ad486cd5bfbf819f89d68ae0f1aeb310fb720e0bd00", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "eabfaad354bf45a2d07f7ad486cd5bfbf819f89d68ae0f1aeb310fb720e0bd00", kill_on_drop: false }` [INFO] [stdout] eabfaad354bf45a2d07f7ad486cd5bfbf819f89d68ae0f1aeb310fb720e0bd00 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-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] cdafe9647a8561fcc1b0389ccfd956e8744377746c7fa83bb61312cd8dc57fdb [INFO] running `Command { std: "docker" "start" "-a" "cdafe9647a8561fcc1b0389ccfd956e8744377746c7fa83bb61312cd8dc57fdb", kill_on_drop: false }` [INFO] [stderr] warning: file `/opt/rustwide/workdir/src/main.rs` found to be present in multiple build targets: [INFO] [stderr] * `bin` target `funzzy` [INFO] [stderr] * `bin` target `fzz` [INFO] [stderr] Compiling libc v0.2.161 [INFO] [stderr] Compiling proc-macro2 v1.0.89 [INFO] [stderr] Compiling memoffset v0.7.1 [INFO] [stderr] Compiling serde v1.0.213 [INFO] [stderr] Checking regex-automata v0.4.8 [INFO] [stderr] Checking glob v0.2.11 [INFO] [stderr] Checking predicates-core v1.0.8 [INFO] [stderr] Checking termtree v0.4.1 [INFO] [stderr] Checking anstyle v1.0.9 [INFO] [stderr] Compiling assert_cmd v2.0.16 [INFO] [stderr] Checking float-cmp v0.9.0 [INFO] [stderr] Checking predicates-tree v1.0.11 [INFO] [stderr] Compiling quote v1.0.37 [INFO] [stderr] Compiling syn v2.0.85 [INFO] [stderr] Checking inotify-sys v0.1.5 [INFO] [stderr] Checking net2 v0.2.39 [INFO] [stderr] Checking iovec v0.1.4 [INFO] [stderr] Checking filetime v0.2.25 [INFO] [stderr] Checking mio v0.8.11 [INFO] [stderr] Checking nix v0.26.4 [INFO] [stderr] Checking wait-timeout v0.2.0 [INFO] [stderr] Checking inotify v0.9.6 [INFO] [stderr] Checking inotify v0.7.1 [INFO] [stderr] Checking mio v0.6.23 [INFO] [stderr] Checking notify v6.1.1 [INFO] [stderr] Checking notify-debouncer-mini v0.3.0 [INFO] [stderr] Checking mio-extras v2.0.6 [INFO] [stderr] Checking regex v1.11.1 [INFO] [stderr] Checking bstr v1.10.0 [INFO] [stderr] Compiling serde_derive v1.0.213 [INFO] [stderr] Checking notify v4.0.18 [INFO] [stderr] Checking predicates v3.1.2 [INFO] [stderr] Checking docopt v1.1.1 [INFO] [stderr] Checking funzzy v1.5.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused import: `crate::stdout` [INFO] [stdout] --> src/rules.rs:474:9 [INFO] [stdout] | [INFO] [stdout] 474 | use crate::stdout; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::environment` [INFO] [stdout] --> src/stdout.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::environment; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::stdout` [INFO] [stdout] --> src/yaml.rs:169:9 [INFO] [stdout] | [INFO] [stdout] 169 | use crate::stdout; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_ok()` [INFO] [stdout] --> src/cli/init.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if let Ok(_) = File::open(&self.file_name) { [INFO] [stdout] | -------^^^^^------------------------------ help: try: `if File::open(&self.file_name).is_ok()` [INFO] [stdout] | [INFO] [stdout] = note: this will change drop order of the result, as well as all temporaries [INFO] [stdout] = note: add `#[allow(clippy::redundant_pattern_matching)]` if this is important [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [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] 13 - return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [INFO] [stdout] 13 + format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | return format!("Hint: {}", hint); [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] 15 - return format!("Hint: {}", hint); [INFO] [stdout] 15 + format!("Hint: {}", hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/errors.rs:78:21 [INFO] [stdout] | [INFO] [stdout] 78 | format!("{}", msg) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `msg.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: binary comparison to literal `Option::None` [INFO] [stdout] --> src/rules.rs:90:12 [INFO] [stdout] | [INFO] [stdout] 90 | if None == self.yaml { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.yaml.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/rules.rs:104:12 [INFO] [stdout] | [INFO] [stdout] 104 | if self.commands().len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.commands().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: length comparison to zero [INFO] [stdout] --> src/rules.rs:111:12 [INFO] [stdout] | [INFO] [stdout] 111 | if self.watch_patterns().len() == 0 && !self.run_on_init() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.watch_patterns().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/rules.rs:244:8 [INFO] [stdout] | [INFO] [stdout] 244 | if items.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `items.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: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:350:5 [INFO] [stdout] | [INFO] [stdout] 350 | return Ok(watches); [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] 350 - return Ok(watches); [INFO] [stdout] 350 + Ok(watches) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/rules.rs:328:9 [INFO] [stdout] | [INFO] [stdout] 328 | line_number = line_number + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `line_number += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:384:13 [INFO] [stdout] | [INFO] [stdout] 384 | return from_yaml(&content); [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] 384 - return from_yaml(&content); [INFO] [stdout] 384 + from_yaml(&content) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/rules.rs:406:45 [INFO] [stdout] | [INFO] [stdout] 406 | Pattern::new(&format!("**{}", pattern)).expect( [INFO] [stdout] | _____________________________________________^ [INFO] [stdout] 407 | | &vec![ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] ... | [INFO] [stdout] 423 | | .join("\n"), [INFO] [stdout] 424 | | ) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 406 ~ Pattern::new(&format!("**{}", pattern)).unwrap_or_else(|_| panic!("{}", vec![ [INFO] [stdout] 407 + format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string(), [INFO] [stdout] 421 + ] [INFO] [stdout] 422 + .join("\n"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/rules.rs:439:9 [INFO] [stdout] | [INFO] [stdout] 439 | / if let Err(err) = rule.validate() { [INFO] [stdout] 440 | | return Err(err); [INFO] [stdout] 441 | | } [INFO] [stdout] | |_________^ help: replace it with: `rule.validate()?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:68:56 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn print_time_elapsed(elapsed: std::time::Duration) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:91:43 [INFO] [stdout] | [INFO] [stdout] 91 | let errors: Vec> = results.iter().cloned().filter(|r| r.is_err()).collect(); [INFO] [stdout] | ^^^^^^^^^^^^^^-------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_err()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] = note: `#[warn(clippy::iter_overeager_cloned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:92:21 [INFO] [stdout] | [INFO] [stdout] 92 | let completed = results.iter().cloned().filter(|r| r.is_ok()).count(); [INFO] [stdout] | ^^^^^^^^^^^^^^------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_ok()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:120:22 [INFO] [stdout] | [INFO] [stdout] 120 | pub fn clear_screen() -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_ok()` [INFO] [stdout] --> src/cli/init.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if let Ok(_) = File::open(&self.file_name) { [INFO] [stdout] | -------^^^^^------------------------------ help: try: `if File::open(&self.file_name).is_ok()` [INFO] [stdout] | [INFO] [stdout] = note: this will change drop order of the result, as well as all temporaries [INFO] [stdout] = note: add `#[allow(clippy::redundant_pattern_matching)]` if this is important [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:19:20 [INFO] [stdout] | [INFO] [stdout] 19 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 20 | | .rules [INFO] [stdout] 21 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 22 | || .cloned() [INFO] [stdout] 23 | || .filter(|r| !r.ignore(path) && r.watch(path)) [INFO] [stdout] | ||_________________________________________________________^ [INFO] [stdout] | |_________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| !r.ignore(path) && r.watch(path)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:36:20 [INFO] [stdout] | [INFO] [stdout] 36 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 37 | | .rules [INFO] [stdout] 38 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 39 | || .cloned() [INFO] [stdout] 40 | || .filter(|r| r.run_on_init()) [INFO] [stdout] | ||________________________________________^ [INFO] [stdout] | |________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.run_on_init()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/watches.rs:56:14 [INFO] [stdout] | [INFO] [stdout] 56 | .map(|r| r.watch_absolute_paths()) [INFO] [stdout] | ______________^ [INFO] [stdout] 57 | | .flatten() [INFO] [stdout] | |______________________^ help: try replacing `map` with `flat_map` and remove the `.flatten()`: `flat_map(|r| r.watch_absolute_paths())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/workers.rs:48:32 [INFO] [stdout] | [INFO] [stdout] 48 | ... && !results.clone().into_iter().find(|r| r.is_err()).is_none()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `results.clone().into_iter().find(|r| r.is_err()).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: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [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] 13 - return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [INFO] [stdout] 13 + format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None` [INFO] [stdout] --> src/yaml.rs:11:35 [INFO] [stdout] | [INFO] [stdout] 11 | .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations [INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` on by default [INFO] [stdout] help: use `unwrap_or` instead [INFO] [stdout] | [INFO] [stdout] 11 - .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] 11 + .map(|i| String::from(i.as_str().unwrap_or("_invalid_value_"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | return format!("Hint: {}", hint); [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] 15 - return format!("Hint: {}", hint); [INFO] [stdout] 15 + format!("Hint: {}", hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:18:32 [INFO] [stdout] | [INFO] [stdout] 18 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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/yaml.rs:32:32 [INFO] [stdout] | [INFO] [stdout] 32 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:61:32 [INFO] [stdout] | [INFO] [stdout] 61 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:75:32 [INFO] [stdout] | [INFO] [stdout] 75 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: useless use of `format!` [INFO] [stdout] --> src/errors.rs:78:21 [INFO] [stdout] | [INFO] [stdout] 78 | format!("{}", msg) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `msg.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 `vec!` [INFO] [stdout] --> src/rules.rs:122:32 [INFO] [stdout] | [INFO] [stdout] 122 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 123 | | format!( [INFO] [stdout] 124 | | "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 125 | | name, watch_pattern [INFO] [stdout] ... | [INFO] [stdout] 128 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 129 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 122 ~ return Err([format!( [INFO] [stdout] 123 + "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 124 + name, watch_pattern [INFO] [stdout] 125 + ), [INFO] [stdout] 126 + format!(" {}", err), [INFO] [stdout] 127 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:139:32 [INFO] [stdout] | [INFO] [stdout] 139 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 140 | | format!( [INFO] [stdout] 141 | | "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 142 | | name, ignore_pattern [INFO] [stdout] ... | [INFO] [stdout] 145 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 146 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 139 ~ return Err([format!( [INFO] [stdout] 140 + "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 141 + name, ignore_pattern [INFO] [stdout] 142 + ), [INFO] [stdout] 143 + format!(" {}", err), [INFO] [stdout] 144 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:340:25 [INFO] [stdout] | [INFO] [stdout] 340 | / vec![ [INFO] [stdout] 341 | | "When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 342 | | "The output of command `find` is a good example", [INFO] [stdout] 343 | | ].join("\n"), [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 340 ~ ["When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 341 ~ "The output of command `find` is a good example"].join("\n"), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:407:10 [INFO] [stdout] | [INFO] [stdout] 407 | &vec![ [INFO] [stdout] | __________^ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] ... | [INFO] [stdout] 421 | | .to_string(), [INFO] [stdout] 422 | | ] [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 407 ~ &[format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:409:13 [INFO] [stdout] | [INFO] [stdout] 409 | / vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] 411 | | "Some example of valid patterns: ", [INFO] [stdout] 412 | | " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] ... | [INFO] [stdout] 418 | | " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 419 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 409 ~ ["", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/watcher.rs:24:28 [INFO] [stdout] | [INFO] [stdout] 24 | let warning = &vec![ [INFO] [stdout] | ____________________________^ [INFO] [stdout] 25 | | format!("unknown file/directory: '{}'", path), [INFO] [stdout] 26 | | format!("Different behaviour depending on the OS."), [INFO] [stdout] 27 | | format!("The watcher may not be triggered for this rule."), [INFO] [stdout] 28 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 24 ~ let warning = &[format!("unknown file/directory: '{}'", path), [INFO] [stdout] 25 + format!("Different behaviour depending on the OS."), [INFO] [stdout] 26 + format!("The watcher may not be triggered for this rule.")] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: binary comparison to literal `Option::None` [INFO] [stdout] --> src/rules.rs:90:12 [INFO] [stdout] | [INFO] [stdout] 90 | if None == self.yaml { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.yaml.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/rules.rs:104:12 [INFO] [stdout] | [INFO] [stdout] 104 | if self.commands().len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.commands().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: length comparison to zero [INFO] [stdout] --> src/rules.rs:111:12 [INFO] [stdout] | [INFO] [stdout] 111 | if self.watch_patterns().len() == 0 && !self.run_on_init() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.watch_patterns().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/rules.rs:244:8 [INFO] [stdout] | [INFO] [stdout] 244 | if items.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `items.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: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:350:5 [INFO] [stdout] | [INFO] [stdout] 350 | return Ok(watches); [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] 350 - return Ok(watches); [INFO] [stdout] 350 + Ok(watches) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/rules.rs:328:9 [INFO] [stdout] | [INFO] [stdout] 328 | line_number = line_number + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `line_number += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:384:13 [INFO] [stdout] | [INFO] [stdout] 384 | return from_yaml(&content); [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] 384 - return from_yaml(&content); [INFO] [stdout] 384 + from_yaml(&content) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/rules.rs:406:45 [INFO] [stdout] | [INFO] [stdout] 406 | Pattern::new(&format!("**{}", pattern)).expect( [INFO] [stdout] | _____________________________________________^ [INFO] [stdout] 407 | | &vec![ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] ... | [INFO] [stdout] 423 | | .join("\n"), [INFO] [stdout] 424 | | ) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 406 ~ Pattern::new(&format!("**{}", pattern)).unwrap_or_else(|_| panic!("{}", vec![ [INFO] [stdout] 407 + format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string(), [INFO] [stdout] 421 + ] [INFO] [stdout] 422 + .join("\n"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/rules.rs:439:9 [INFO] [stdout] | [INFO] [stdout] 439 | / if let Err(err) = rule.validate() { [INFO] [stdout] 440 | | return Err(err); [INFO] [stdout] 441 | | } [INFO] [stdout] | |_________^ help: replace it with: `rule.validate()?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:496:9 [INFO] [stdout] | [INFO] [stdout] 496 | assert_eq!(true, rule.watch("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_assert_comparison)]` on by default [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 496 - assert_eq!(true, rule.watch("tests/foo.rs")); [INFO] [stdout] 496 + assert!(rule.watch("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:499:9 [INFO] [stdout] | [INFO] [stdout] 499 | assert_eq!(true, rule2.watch("src/foo.rsx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 499 - assert_eq!(true, rule2.watch("src/foo.rsx")); [INFO] [stdout] 499 + assert!(rule2.watch("src/foo.rsx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:500:9 [INFO] [stdout] | [INFO] [stdout] 500 | assert_eq!(true, rule2.watch("src/bar/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 500 - assert_eq!(true, rule2.watch("src/bar/foo.rs")); [INFO] [stdout] 500 + assert!(rule2.watch("src/bar/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:501:9 [INFO] [stdout] | [INFO] [stdout] 501 | assert_eq!(true, rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 501 - assert_eq!(true, rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] 501 + assert!(rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:502:9 [INFO] [stdout] | [INFO] [stdout] 502 | assert_eq!(true, rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 502 - assert_eq!(true, rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] 502 + assert!(rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:503:9 [INFO] [stdout] | [INFO] [stdout] 503 | assert_eq!(true, rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 503 - assert_eq!(true, rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] 503 + assert!(rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:504:9 [INFO] [stdout] | [INFO] [stdout] 504 | assert_eq!(true, rule2.watch("src/bar/foo.abc")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 504 - assert_eq!(true, rule2.watch("src/bar/foo.abc")); [INFO] [stdout] 504 + assert!(rule2.watch("src/bar/foo.abc")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:505:9 [INFO] [stdout] | [INFO] [stdout] 505 | assert_eq!(true, rule2.watch("src/bar/foo.abx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 505 - assert_eq!(true, rule2.watch("src/bar/foo.abx")); [INFO] [stdout] 505 + assert!(rule2.watch("src/bar/foo.abx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:507:9 [INFO] [stdout] | [INFO] [stdout] 507 | assert_eq!(false, rule2.watch("src/bar/foo.ab")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 507 - assert_eq!(false, rule2.watch("src/bar/foo.ab")); [INFO] [stdout] 507 + assert!(!rule2.watch("src/bar/foo.ab")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:521:9 [INFO] [stdout] | [INFO] [stdout] 521 | assert_eq!(false, rule.watch("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 521 - assert_eq!(false, rule.watch("tests/foo.rs")); [INFO] [stdout] 521 + assert!(!rule.watch("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:580:9 [INFO] [stdout] | [INFO] [stdout] 580 | assert_eq!(true, rule.ignore("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 580 - assert_eq!(true, rule.ignore("tests/foo.rs")); [INFO] [stdout] 580 + assert!(rule.ignore("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:595:9 [INFO] [stdout] | [INFO] [stdout] 595 | assert_eq!(false, rule.ignore("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 595 - assert_eq!(false, rule.ignore("tests/foo.rs")); [INFO] [stdout] 595 + assert!(!rule.ignore("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/rules.rs:668:34 [INFO] [stdout] | [INFO] [stdout] 668 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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: useless use of `format!` [INFO] [stdout] --> src/rules.rs:683:34 [INFO] [stdout] | [INFO] [stdout] 683 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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: useless use of `format!` [INFO] [stdout] --> src/rules.rs:717:34 [INFO] [stdout] | [INFO] [stdout] 717 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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 unit return type [INFO] [stdout] --> src/stdout.rs:68:56 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn print_time_elapsed(elapsed: std::time::Duration) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:91:43 [INFO] [stdout] | [INFO] [stdout] 91 | let errors: Vec> = results.iter().cloned().filter(|r| r.is_err()).collect(); [INFO] [stdout] | ^^^^^^^^^^^^^^-------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_err()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] = note: `#[warn(clippy::iter_overeager_cloned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:92:21 [INFO] [stdout] | [INFO] [stdout] 92 | let completed = results.iter().cloned().filter(|r| r.is_ok()).count(); [INFO] [stdout] | ^^^^^^^^^^^^^^------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_ok()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:120:22 [INFO] [stdout] | [INFO] [stdout] 120 | pub fn clear_screen() -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:19:20 [INFO] [stdout] | [INFO] [stdout] 19 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 20 | | .rules [INFO] [stdout] 21 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 22 | || .cloned() [INFO] [stdout] 23 | || .filter(|r| !r.ignore(path) && r.watch(path)) [INFO] [stdout] | ||_________________________________________________________^ [INFO] [stdout] | |_________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| !r.ignore(path) && r.watch(path)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:36:20 [INFO] [stdout] | [INFO] [stdout] 36 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 37 | | .rules [INFO] [stdout] 38 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 39 | || .cloned() [INFO] [stdout] 40 | || .filter(|r| r.run_on_init()) [INFO] [stdout] | ||________________________________________^ [INFO] [stdout] | |________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.run_on_init()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/watches.rs:56:14 [INFO] [stdout] | [INFO] [stdout] 56 | .map(|r| r.watch_absolute_paths()) [INFO] [stdout] | ______________^ [INFO] [stdout] 57 | | .flatten() [INFO] [stdout] | |______________________^ help: try replacing `map` with `flat_map` and remove the `.flatten()`: `flat_map(|r| r.watch_absolute_paths())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` 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/watches.rs:111:53 [INFO] [stdout] | [INFO] [stdout] 111 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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/watches.rs:127:53 [INFO] [stdout] | [INFO] [stdout] 127 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:138:53 [INFO] [stdout] | [INFO] [stdout] 138 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:155:53 [INFO] [stdout] | [INFO] [stdout] 155 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:171:53 [INFO] [stdout] | [INFO] [stdout] 171 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:195:53 [INFO] [stdout] | [INFO] [stdout] 195 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:212:53 [INFO] [stdout] | [INFO] [stdout] 212 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:226:53 [INFO] [stdout] | [INFO] [stdout] 226 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:250:53 [INFO] [stdout] | [INFO] [stdout] 250 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:289:53 [INFO] [stdout] | [INFO] [stdout] 289 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:312:13 [INFO] [stdout] | [INFO] [stdout] 312 | / &r#" [INFO] [stdout] 313 | | - name: run tests [INFO] [stdout] 314 | | run: [ [INFO] [stdout] 315 | | "yarn test {{filepath}}", [INFO] [stdout] 316 | | change: 'src/**' [INFO] [stdout] 317 | | "# [INFO] [stdout] | |__________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 312 ~ r#" [INFO] [stdout] 313 + - name: run tests [INFO] [stdout] 314 + run: [ [INFO] [stdout] 315 + "yarn test {{filepath}}", [INFO] [stdout] 316 + change: 'src/**' [INFO] [stdout] 317 + "# [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:322:13 [INFO] [stdout] | [INFO] [stdout] 322 | / &r#" [INFO] [stdout] 323 | | - name: other [INFO] [stdout] 324 | | run: 'cargo test' [INFO] [stdout] 325 | | change: 'test/**' [INFO] [stdout] 326 | | "# [INFO] [stdout] | |__________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 322 ~ r#" [INFO] [stdout] 323 + - name: other [INFO] [stdout] 324 + run: 'cargo test' [INFO] [stdout] 325 + change: 'test/**' [INFO] [stdout] 326 + "# [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/workers.rs:48:32 [INFO] [stdout] | [INFO] [stdout] 48 | ... && !results.clone().into_iter().find(|r| r.is_err()).is_none()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `results.clone().into_iter().find(|r| r.is_err()).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: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None` [INFO] [stdout] --> src/yaml.rs:11:35 [INFO] [stdout] | [INFO] [stdout] 11 | .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations [INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` on by default [INFO] [stdout] help: use `unwrap_or` instead [INFO] [stdout] | [INFO] [stdout] 11 - .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] 11 + .map(|i| String::from(i.as_str().unwrap_or("_invalid_value_"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:18:32 [INFO] [stdout] | [INFO] [stdout] 18 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:32:32 [INFO] [stdout] | [INFO] [stdout] 32 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:61:32 [INFO] [stdout] | [INFO] [stdout] 61 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:75:32 [INFO] [stdout] | [INFO] [stdout] 75 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:122:32 [INFO] [stdout] | [INFO] [stdout] 122 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 123 | | format!( [INFO] [stdout] 124 | | "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 125 | | name, watch_pattern [INFO] [stdout] ... | [INFO] [stdout] 128 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 129 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 122 ~ return Err([format!( [INFO] [stdout] 123 + "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 124 + name, watch_pattern [INFO] [stdout] 125 + ), [INFO] [stdout] 126 + format!(" {}", err), [INFO] [stdout] 127 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:139:32 [INFO] [stdout] | [INFO] [stdout] 139 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 140 | | format!( [INFO] [stdout] 141 | | "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 142 | | name, ignore_pattern [INFO] [stdout] ... | [INFO] [stdout] 145 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 146 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 139 ~ return Err([format!( [INFO] [stdout] 140 + "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 141 + name, ignore_pattern [INFO] [stdout] 142 + ), [INFO] [stdout] 143 + format!(" {}", err), [INFO] [stdout] 144 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:340:25 [INFO] [stdout] | [INFO] [stdout] 340 | / vec![ [INFO] [stdout] 341 | | "When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 342 | | "The output of command `find` is a good example", [INFO] [stdout] 343 | | ].join("\n"), [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 340 ~ ["When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 341 ~ "The output of command `find` is a good example"].join("\n"), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:407:10 [INFO] [stdout] | [INFO] [stdout] 407 | &vec![ [INFO] [stdout] | __________^ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] ... | [INFO] [stdout] 421 | | .to_string(), [INFO] [stdout] 422 | | ] [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 407 ~ &[format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:409:13 [INFO] [stdout] | [INFO] [stdout] 409 | / vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] 411 | | "Some example of valid patterns: ", [INFO] [stdout] 412 | | " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] ... | [INFO] [stdout] 418 | | " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 419 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 409 ~ ["", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:746:13 [INFO] [stdout] | [INFO] [stdout] 746 | / vec![ [INFO] [stdout] 747 | | "name: my tests", [INFO] [stdout] 748 | | "run: cargo tests {{filepath}}", [INFO] [stdout] 749 | | "change: tests/**", [INFO] [stdout] 750 | | "run_on_init: true", [INFO] [stdout] 751 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 746 ~ ["name: my tests", [INFO] [stdout] 747 + "run: cargo tests {{filepath}}", [INFO] [stdout] 748 + "change: tests/**", [INFO] [stdout] 749 + "run_on_init: true"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:774:13 [INFO] [stdout] | [INFO] [stdout] 774 | / vec![ [INFO] [stdout] 775 | | "Failed to load configuration at line:", [INFO] [stdout] 776 | | "| run: 'cargo tests'", [INFO] [stdout] 777 | | "|> change: **/*", [INFO] [stdout] ... | [INFO] [stdout] 780 | | "Hint: Check for wrong types, any missing quotes for glob pattern or incorrect identation", [INFO] [stdout] 781 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 774 ~ ["Failed to load configuration at line:", [INFO] [stdout] 775 + "| run: 'cargo tests'", [INFO] [stdout] 776 + "|> change: **/*", [INFO] [stdout] 777 + "| ", [INFO] [stdout] 778 + "Reason: while scanning an anchor or alias, did not find expected alphabetic or numeric character at line 8 column 19", [INFO] [stdout] 779 + "Hint: Check for wrong types, any missing quotes for glob pattern or incorrect identation"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:792:13 [INFO] [stdout] | [INFO] [stdout] 792 | / vec![ [INFO] [stdout] 793 | | "Configuration file is invalid! There are no rules to watch", [INFO] [stdout] 794 | | "Hint: Make sure to declare at least one rule. Try to run `fzz init` to generate a new configuration from scratch", [INFO] [stdout] 795 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 792 ~ ["Configuration file is invalid! There are no rules to watch", [INFO] [stdout] 793 + "Hint: Make sure to declare at least one rule. Try to run `fzz init` to generate a new configuration from scratch"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:809:13 [INFO] [stdout] | [INFO] [stdout] 809 | / vec![ [INFO] [stdout] 810 | | "Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 811 | | "```yaml", [INFO] [stdout] 812 | | "on:", [INFO] [stdout] ... | [INFO] [stdout] 816 | | "Hint: Make sure to declare the rules as a list without any root property", [INFO] [stdout] 817 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 809 ~ ["Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 810 + "```yaml", [INFO] [stdout] 811 + "on:", [INFO] [stdout] 812 + " - name: foo", [INFO] [stdout] 813 + " run: echo foo", [INFO] [stdout] 814 + "```", [INFO] [stdout] 815 + "Hint: Make sure to declare the rules as a list without any root property"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/watcher.rs:24:28 [INFO] [stdout] | [INFO] [stdout] 24 | let warning = &vec![ [INFO] [stdout] | ____________________________^ [INFO] [stdout] 25 | | format!("unknown file/directory: '{}'", path), [INFO] [stdout] 26 | | format!("Different behaviour depending on the OS."), [INFO] [stdout] 27 | | format!("The watcher may not be triggered for this rule."), [INFO] [stdout] 28 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 24 ~ let warning = &[format!("unknown file/directory: '{}'", path), [INFO] [stdout] 25 + format!("Different behaviour depending on the OS."), [INFO] [stdout] 26 + format!("The watcher may not be triggered for this rule.")] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_example` is never used [INFO] [stdout] --> tests/./common/lib.rs:28:8 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: call to `set_readonly` with argument `false` [INFO] [stdout] --> tests/command_init_errors.rs:53:13 [INFO] [stdout] | [INFO] [stdout] 53 | perms.set_readonly(false); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: on Unix platforms this results in the file being world writable [INFO] [stdout] = help: you can set the desired permissions using `PermissionsExt`. For more information, see [INFO] [stdout] https://doc.rust-lang.org/std/os/unix/fs/trait.PermissionsExt.html [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#permissions_set_readonly_false [INFO] [stdout] = note: `#[warn(clippy::permissions_set_readonly_false)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/command_init_errors.rs:28:17 [INFO] [stdout] | [INFO] [stdout] 28 | / vec![ [INFO] [stdout] 29 | | "\u{1b}[31mError\u{1b}[0m: Command failed to execute", [INFO] [stdout] 30 | | "Configuration file already exists (.watch.yaml)", [INFO] [stdout] 31 | | "", [INFO] [stdout] 32 | | ] [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 28 ~ ["\u{1b}[31mError\u{1b}[0m: Command failed to execute", [INFO] [stdout] 29 + "Configuration file already exists (.watch.yaml)", [INFO] [stdout] 30 + ""] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/command_init_errors.rs:65:17 [INFO] [stdout] | [INFO] [stdout] 65 | / vec![ [INFO] [stdout] 66 | | "Error: Command failed to execute", [INFO] [stdout] 67 | | "Failed to create the configuration file", [INFO] [stdout] 68 | | "Reason: Permission denied (os error 13)", [INFO] [stdout] 69 | | "Hint: Check if you have permission to write in the current folder", [INFO] [stdout] 70 | | "", [INFO] [stdout] 71 | | ] [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 65 ~ ["Error: Command failed to execute", [INFO] [stdout] 66 + "Failed to create the configuration file", [INFO] [stdout] 67 + "Reason: Permission denied (os error 13)", [INFO] [stdout] 68 + "Hint: Check if you have permission to write in the current folder", [INFO] [stdout] 69 + ""] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watcher_reloads_config_file.rs:14:29 [INFO] [stdout] | [INFO] [stdout] 14 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 15 | | .arg("--non-block") [INFO] [stdout] 16 | | .spawn() [INFO] [stdout] 17 | | .expect("failed to spawn child"); [INFO] [stdout] | |________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_example` is never used [INFO] [stdout] --> tests/./common/lib.rs:28:8 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/watching_configured_errors.rs:22:9 [INFO] [stdout] | [INFO] [stdout] 22 | / vec![ [INFO] [stdout] 23 | | "Error: Failed to read default config file", [INFO] [stdout] 24 | | "Couldn\'t open configuration file: \'.watch.yaml\'", [INFO] [stdout] 25 | | "Reason: No such file or directory (os error 2)", [INFO] [stdout] 26 | | "Hint: Check if the file exists and if the path is correct. Try `fzz init` to create a new configuration file", [INFO] [stdout] 27 | | "", [INFO] [stdout] 28 | | ] [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 22 ~ ["Error: Failed to read default config file", [INFO] [stdout] 23 + "Couldn\'t open configuration file: \'.watch.yaml\'", [INFO] [stdout] 24 + "Reason: No such file or directory (os error 2)", [INFO] [stdout] 25 + "Hint: Check if the file exists and if the path is correct. Try `fzz init` to create a new configuration file", [INFO] [stdout] 26 + ""] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/watching_configured_errors.rs:46:13 [INFO] [stdout] | [INFO] [stdout] 46 | / vec![ [INFO] [stdout] 47 | | "Error: Failed to read config file", [INFO] [stdout] 48 | | "Missing \'name\' in rule", [INFO] [stdout] 49 | | "```yaml", [INFO] [stdout] ... | [INFO] [stdout] 54 | | "", [INFO] [stdout] 55 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 46 ~ ["Error: Failed to read config file", [INFO] [stdout] 47 + "Missing \'name\' in rule", [INFO] [stdout] 48 + "```yaml", [INFO] [stdout] 49 + "foo: bla", [INFO] [stdout] 50 + "run: bar", [INFO] [stdout] 51 + "```", [INFO] [stdout] 52 + "Hint: Check for typos or wrong identation", [INFO] [stdout] 53 + ""] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/watching_configured_errors.rs:73:13 [INFO] [stdout] | [INFO] [stdout] 73 | / vec![ [INFO] [stdout] 74 | | "Error: Failed to read config file", [INFO] [stdout] 75 | | "Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 76 | | "```yaml", [INFO] [stdout] ... | [INFO] [stdout] 83 | | "", [INFO] [stdout] 84 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 73 ~ ["Error: Failed to read config file", [INFO] [stdout] 74 + "Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 75 + "```yaml", [INFO] [stdout] 76 + "on:", [INFO] [stdout] 77 + " - name: foobar", [INFO] [stdout] 78 + " run: echo hello", [INFO] [stdout] 79 + " change: hello/*", [INFO] [stdout] 80 + "```", [INFO] [stdout] 81 + "Hint: Make sure to declare the rules as a list without any root property", [INFO] [stdout] 82 + ""] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_configured_rules.rs:15:29 [INFO] [stdout] | [INFO] [stdout] 15 | let mut child = fzz_cmd.arg("-V").spawn().expect("failed to spawn child"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_configured_rules.rs:83:29 [INFO] [stdout] | [INFO] [stdout] 83 | let mut child = fzz_cmd.spawn().expect("failed to spawn process"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::stdout` [INFO] [stdout] --> src/rules.rs:474:9 [INFO] [stdout] | [INFO] [stdout] 474 | use crate::stdout; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_configured_rules.rs:233:29 [INFO] [stdout] | [INFO] [stdout] 233 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 234 | | .arg("-t") [INFO] [stdout] 235 | | .arg("@invalid") [INFO] [stdout] 236 | | .arg("-V") [INFO] [stdout] 237 | | .spawn() [INFO] [stdout] 238 | | .expect("failed to spawn child"); [INFO] [stdout] | |________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_with_verbose_flag.rs:14:29 [INFO] [stdout] | [INFO] [stdout] 14 | let mut child = fzz_cmd.arg("-V").spawn().expect("failed to spawn child"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::environment` [INFO] [stdout] --> src/stdout.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::environment; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::stdout` [INFO] [stdout] --> src/yaml.rs:169:9 [INFO] [stdout] | [INFO] [stdout] 169 | use crate::stdout; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_with_fail_fast_flag.rs:17:29 [INFO] [stdout] | [INFO] [stdout] 17 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 18 | | .arg("--fail-fast") [INFO] [stdout] 19 | | .spawn() [INFO] [stdout] 20 | | .expect("failed to spawn sub process"); [INFO] [stdout] | |______________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_with_fail_fast_flag.rs:104:37 [INFO] [stdout] | [INFO] [stdout] 104 | let mut child = fzz_cmd.spawn().expect("failed to spawn sub process"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::stdout` [INFO] [stdout] --> src/rules.rs:474:9 [INFO] [stdout] | [INFO] [stdout] 474 | use crate::stdout; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::environment` [INFO] [stdout] --> src/stdout.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::environment; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_with_fail_fast_flag.rs:190:29 [INFO] [stdout] | [INFO] [stdout] 190 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 191 | | .arg("-nb") // --non-block + --fail-fast [INFO] [stdout] 192 | | .spawn() [INFO] [stdout] 193 | | .expect("failed to spawn sub process"); [INFO] [stdout] | |______________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_with_non_block_flag.rs:17:29 [INFO] [stdout] | [INFO] [stdout] 17 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 18 | | .arg("--non-block") [INFO] [stdout] 19 | | .spawn() [INFO] [stdout] 20 | | .expect("failed to spawn child"); [INFO] [stdout] | |________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::stdout` [INFO] [stdout] --> src/yaml.rs:169:9 [INFO] [stdout] | [INFO] [stdout] 169 | use crate::stdout; [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/tasks_that_run_on_init.rs:20:37 [INFO] [stdout] | [INFO] [stdout] 20 | let mut child = fzz_cmd.spawn().expect("failed to spawn child"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_with_non_block_flag.rs:115:37 [INFO] [stdout] | [INFO] [stdout] 115 | let mut child = fzz_cmd.spawn().expect("failed to spawn child"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Stdio`, `thread::sleep`, and `time::Duration` [INFO] [stdout] --> tests/./common/lib.rs:8:24 [INFO] [stdout] | [INFO] [stdout] 8 | process::{Command, Stdio}, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 9 | thread::sleep, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] 10 | time::Duration, [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:33:5 [INFO] [stdout] | [INFO] [stdout] 33 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit expression [INFO] [stdout] --> tests/./common/lib.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 42 | () [INFO] [stdout] | ^^ help: remove the final `()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_example` is never used [INFO] [stdout] --> tests/./common/lib.rs:28:8 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watcher_does_not_die_with_failing_tasks.rs:16:29 [INFO] [stdout] | [INFO] [stdout] 16 | let mut child = fzz_cmd.spawn().expect("failed to spawn sub process"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_arbitrary_files_running_arbitrary_commands.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | let files = Command::new("find") [INFO] [stdout] | _____________________^ [INFO] [stdout] 12 | | .arg(".") [INFO] [stdout] 13 | | .arg("-name") [INFO] [stdout] 14 | | .arg("*.txt") [INFO] [stdout] 15 | | .stdout(Stdio::piped()) [INFO] [stdout] 16 | | .spawn() [INFO] [stdout] 17 | | .expect("failed to run find"); [INFO] [stdout] | |_________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_arbitrary_files_running_arbitrary_commands.rs:19:25 [INFO] [stdout] | [INFO] [stdout] 19 | let mut child = fzz_cmd [INFO] [stdout] | _________________________^ [INFO] [stdout] 20 | | .arg("echo 'running arbitrary command'") [INFO] [stdout] 21 | | .stdin(files.stdout.expect("failed to open stdin")) [INFO] [stdout] 22 | | .spawn() [INFO] [stdout] 23 | | .expect("Failed to spawn grep command"); [INFO] [stdout] | |___________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_example` is never used [INFO] [stdout] --> tests/./common/lib.rs:28:8 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_arbitrary_files_running_arbitrary_commands.rs:77:25 [INFO] [stdout] | [INFO] [stdout] 77 | let files = Command::new("find") [INFO] [stdout] | _________________________^ [INFO] [stdout] 78 | | .arg(".") [INFO] [stdout] 79 | | .arg("-name") [INFO] [stdout] 80 | | .arg("*.txt") [INFO] [stdout] 81 | | .stdout(Stdio::piped()) [INFO] [stdout] 82 | | .spawn() [INFO] [stdout] 83 | | .expect("failed to run find"); [INFO] [stdout] | |_____________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_arbitrary_files_running_arbitrary_commands.rs:85:29 [INFO] [stdout] | [INFO] [stdout] 85 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 86 | | .arg("echo 'this file changed: {{filepath}}'") [INFO] [stdout] 87 | | .arg("-V") // DEBUG [INFO] [stdout] 88 | | .stdin(files.stdout.expect("failed to open stdin")) [INFO] [stdout] 89 | | .spawn() [INFO] [stdout] 90 | | .expect("Failed to spawn grep command"); [INFO] [stdout] | |_______________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_arbitrary_files_running_arbitrary_commands.rs:144:21 [INFO] [stdout] | [INFO] [stdout] 144 | let files = Command::new("find") [INFO] [stdout] | _____________________^ [INFO] [stdout] 145 | | .arg(".") [INFO] [stdout] 146 | | .arg("-name") [INFO] [stdout] 147 | | .arg("*.txt") [INFO] [stdout] 148 | | .stdout(Stdio::piped()) [INFO] [stdout] 149 | | .spawn() [INFO] [stdout] 150 | | .expect("failed to run find"); [INFO] [stdout] | |_________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_arbitrary_files_running_arbitrary_commands.rs:151:25 [INFO] [stdout] | [INFO] [stdout] 151 | let mut child = fzz_cmd [INFO] [stdout] | _________________________^ [INFO] [stdout] 152 | | .arg("watch") [INFO] [stdout] 153 | | .arg("echo 'it runs on init by default'") [INFO] [stdout] 154 | | .stdin(files.stdout.expect("failed to open stdin")) [INFO] [stdout] 155 | | .spawn() [INFO] [stdout] 156 | | .expect("Failed to spawn grep command"); [INFO] [stdout] | |___________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_arbitrary_files_running_arbitrary_commands.rs:181:25 [INFO] [stdout] | [INFO] [stdout] 181 | let mut child = fzz_cmd [INFO] [stdout] | _________________________^ [INFO] [stdout] 182 | | .arg("watch") [INFO] [stdout] 183 | | .arg("'echo fooo'") [INFO] [stdout] 184 | | .spawn() [INFO] [stdout] 185 | | .expect("Failed to spawn grep command"); [INFO] [stdout] | |___________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/read_stdin_error.rs:19:13 [INFO] [stdout] | [INFO] [stdout] 19 | / vec![ [INFO] [stdout] 20 | | "Error: Failed to read stdin", [INFO] [stdout] 21 | | "Reason: Timed out waiting for input.", [INFO] [stdout] 22 | | "Hint: Did you forget to pipe an output of a command? Try `find . | fzz 'echo \"changed: {{filepath}}\"'`", [INFO] [stdout] 23 | | "", [INFO] [stdout] 24 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 19 ~ ["Error: Failed to read stdin", [INFO] [stdout] 20 + "Reason: Timed out waiting for input.", [INFO] [stdout] 21 + "Hint: Did you forget to pipe an output of a command? Try `find . | fzz 'echo \"changed: {{filepath}}\"'`", [INFO] [stdout] 22 + ""] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/read_stdin_error.rs:46:13 [INFO] [stdout] | [INFO] [stdout] 46 | / vec![ [INFO] [stdout] 47 | | "Error: Failed to get rules from stdin", [INFO] [stdout] 48 | | "Unknown path \'total", //... 8' line 1 [INFO] [stdout] 49 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 46 ~ ["Error: Failed to get rules from stdin", [INFO] [stdout] 47 + "Unknown path \'total"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> tests/read_stdin_error.rs:53:13 [INFO] [stdout] | [INFO] [stdout] 53 | / vec![ [INFO] [stdout] 54 | | "Reason: No such file or directory (os error 2)", [INFO] [stdout] 55 | | "Hint: When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 56 | | "The output of command `find` is a good example", [INFO] [stdout] 57 | | "", [INFO] [stdout] 58 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 53 ~ ["Reason: No such file or directory (os error 2)", [INFO] [stdout] 54 + "Hint: When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 55 + "The output of command `find` is a good example", [INFO] [stdout] 56 + ""] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `output_file_path` [INFO] [stdout] --> tests/./common/lib.rs:37:23 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_output_file_path` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `handler` [INFO] [stdout] --> tests/./common/lib.rs:37:47 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_handler` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_example` is never used [INFO] [stdout] --> tests/./common/lib.rs:28:8 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/watching_filtered_tasks_with_target_flag.rs:17:29 [INFO] [stdout] | [INFO] [stdout] 17 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 18 | | .arg("--target") [INFO] [stdout] 19 | | .arg("@quick") [INFO] [stdout] 20 | | .spawn() [INFO] [stdout] 21 | | .expect("failed to spawn child"); [INFO] [stdout] | |________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `with_output` is never used [INFO] [stdout] --> tests/./common/lib.rs:37:8 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: needless `fn main` in doctest [INFO] [stdout] --> tests/./common/./macros.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | /// fn main() { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main [INFO] [stdout] = note: `#[warn(clippy::needless_doctest_main)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:28:41 [INFO] [stdout] | [INFO] [stdout] 28 | pub fn with_example(_: Options, _: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:30:34 [INFO] [stdout] | [INFO] [stdout] 30 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:37:58 [INFO] [stdout] | [INFO] [stdout] 37 | pub fn with_output(output_file_path: &str, handler: F) -> () [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> tests/./common/lib.rs:39:34 [INFO] [stdout] | [INFO] [stdout] 39 | F: FnOnce(&mut Command, File) -> (), [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/tasks_with_filepath_template.rs:16:29 [INFO] [stdout] | [INFO] [stdout] 16 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 17 | | .arg("-t") [INFO] [stdout] 18 | | .arg("@absolute") [INFO] [stdout] 19 | | .spawn() [INFO] [stdout] 20 | | .expect("failed to spawn child"); [INFO] [stdout] | |________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] = note: `#[warn(clippy::zombie_processes)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: spawned process is never `wait()`ed on [INFO] [stdout] --> tests/tasks_with_filepath_template.rs:104:29 [INFO] [stdout] | [INFO] [stdout] 104 | let mut child = fzz_cmd [INFO] [stdout] | _____________________________^ [INFO] [stdout] 105 | | .arg("-t") [INFO] [stdout] 106 | | .arg("@relative") [INFO] [stdout] 107 | | .spawn() [INFO] [stdout] 108 | | .expect("failed to spawn child"); [INFO] [stdout] | |________________________________________________^ [INFO] [stdout] | [INFO] [stdout] = help: consider calling `.wait()` [INFO] [stdout] = note: not doing so might leave behind zombie processes [INFO] [stdout] = note: see https://doc.rust-lang.org/stable/std/process/struct.Child.html#warning [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zombie_processes [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/workers.rs:16:23 [INFO] [stdout] | [INFO] [stdout] 16 | FinishedExecution(Duration), [INFO] [stdout] | ----------------- ^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this variant [INFO] [stdout] | [INFO] [stdout] = note: `WorkerEvent` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field [INFO] [stdout] | [INFO] [stdout] 16 - FinishedExecution(Duration), [INFO] [stdout] 16 + FinishedExecution(()), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_ok()` [INFO] [stdout] --> src/cli/init.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if let Ok(_) = File::open(&self.file_name) { [INFO] [stdout] | -------^^^^^------------------------------ help: try: `if File::open(&self.file_name).is_ok()` [INFO] [stdout] | [INFO] [stdout] = note: this will change drop order of the result, as well as all temporaries [INFO] [stdout] = note: add `#[allow(clippy::redundant_pattern_matching)]` if this is important [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [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] 13 - return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [INFO] [stdout] 13 + format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | return format!("Hint: {}", hint); [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] 15 - return format!("Hint: {}", hint); [INFO] [stdout] 15 + format!("Hint: {}", hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: all variants have the same postfix: `Error` [INFO] [stdout] --> src/errors.rs:22:1 [INFO] [stdout] | [INFO] [stdout] 22 | / pub enum FzzError { [INFO] [stdout] 23 | | IoConfigError(String, Option), [INFO] [stdout] 24 | | IoStdinError(String, Hint), [INFO] [stdout] 25 | | InvalidConfigError(String, Option, Hint), [INFO] [stdout] ... | [INFO] [stdout] 28 | | GenericError(String), [INFO] [stdout] 29 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: remove the postfixes and use full paths to the variants instead of glob imports [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#enum_variant_names [INFO] [stdout] = note: `#[warn(clippy::enum_variant_names)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/errors.rs:78:21 [INFO] [stdout] | [INFO] [stdout] 78 | format!("{}", msg) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `msg.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: binary comparison to literal `Option::None` [INFO] [stdout] --> src/rules.rs:90:12 [INFO] [stdout] | [INFO] [stdout] 90 | if None == self.yaml { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.yaml.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/rules.rs:104:12 [INFO] [stdout] | [INFO] [stdout] 104 | if self.commands().len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.commands().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: length comparison to zero [INFO] [stdout] --> src/rules.rs:111:12 [INFO] [stdout] | [INFO] [stdout] 111 | if self.watch_patterns().len() == 0 && !self.run_on_init() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.watch_patterns().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/rules.rs:244:8 [INFO] [stdout] | [INFO] [stdout] 244 | if items.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `items.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: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:350:5 [INFO] [stdout] | [INFO] [stdout] 350 | return Ok(watches); [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] 350 - return Ok(watches); [INFO] [stdout] 350 + Ok(watches) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/rules.rs:328:9 [INFO] [stdout] | [INFO] [stdout] 328 | line_number = line_number + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `line_number += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:384:13 [INFO] [stdout] | [INFO] [stdout] 384 | return from_yaml(&content); [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] 384 - return from_yaml(&content); [INFO] [stdout] 384 + from_yaml(&content) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/rules.rs:406:45 [INFO] [stdout] | [INFO] [stdout] 406 | Pattern::new(&format!("**{}", pattern)).expect( [INFO] [stdout] | _____________________________________________^ [INFO] [stdout] 407 | | &vec![ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] ... | [INFO] [stdout] 423 | | .join("\n"), [INFO] [stdout] 424 | | ) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 406 ~ Pattern::new(&format!("**{}", pattern)).unwrap_or_else(|_| panic!("{}", vec![ [INFO] [stdout] 407 + format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string(), [INFO] [stdout] 421 + ] [INFO] [stdout] 422 + .join("\n"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/rules.rs:439:9 [INFO] [stdout] | [INFO] [stdout] 439 | / if let Err(err) = rule.validate() { [INFO] [stdout] 440 | | return Err(err); [INFO] [stdout] 441 | | } [INFO] [stdout] | |_________^ help: replace it with: `rule.validate()?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:68:56 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn print_time_elapsed(elapsed: std::time::Duration) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:91:43 [INFO] [stdout] | [INFO] [stdout] 91 | let errors: Vec> = results.iter().cloned().filter(|r| r.is_err()).collect(); [INFO] [stdout] | ^^^^^^^^^^^^^^-------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_err()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] = note: `#[warn(clippy::iter_overeager_cloned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:92:21 [INFO] [stdout] | [INFO] [stdout] 92 | let completed = results.iter().cloned().filter(|r| r.is_ok()).count(); [INFO] [stdout] | ^^^^^^^^^^^^^^------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_ok()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:120:22 [INFO] [stdout] | [INFO] [stdout] 120 | pub fn clear_screen() -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:19:20 [INFO] [stdout] | [INFO] [stdout] 19 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 20 | | .rules [INFO] [stdout] 21 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 22 | || .cloned() [INFO] [stdout] 23 | || .filter(|r| !r.ignore(path) && r.watch(path)) [INFO] [stdout] | ||_________________________________________________________^ [INFO] [stdout] | |_________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| !r.ignore(path) && r.watch(path)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:36:20 [INFO] [stdout] | [INFO] [stdout] 36 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 37 | | .rules [INFO] [stdout] 38 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 39 | || .cloned() [INFO] [stdout] 40 | || .filter(|r| r.run_on_init()) [INFO] [stdout] | ||________________________________________^ [INFO] [stdout] | |________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.run_on_init()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/watches.rs:56:14 [INFO] [stdout] | [INFO] [stdout] 56 | .map(|r| r.watch_absolute_paths()) [INFO] [stdout] | ______________^ [INFO] [stdout] 57 | | .flatten() [INFO] [stdout] | |______________________^ help: try replacing `map` with `flat_map` and remove the `.flatten()`: `flat_map(|r| r.watch_absolute_paths())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/workers.rs:48:32 [INFO] [stdout] | [INFO] [stdout] 48 | ... && !results.clone().into_iter().find(|r| r.is_err()).is_none()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `results.clone().into_iter().find(|r| r.is_err()).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: unnecessary closure used to substitute value for `Option::None` [INFO] [stdout] --> src/yaml.rs:11:35 [INFO] [stdout] | [INFO] [stdout] 11 | .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations [INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` on by default [INFO] [stdout] help: use `unwrap_or` instead [INFO] [stdout] | [INFO] [stdout] 11 - .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] 11 + .map(|i| String::from(i.as_str().unwrap_or("_invalid_value_"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:18:32 [INFO] [stdout] | [INFO] [stdout] 18 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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/yaml.rs:32:32 [INFO] [stdout] | [INFO] [stdout] 32 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:61:32 [INFO] [stdout] | [INFO] [stdout] 61 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:75:32 [INFO] [stdout] | [INFO] [stdout] 75 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/main.rs:206:36 [INFO] [stdout] | [INFO] [stdout] 206 | let filtered = rules [INFO] [stdout] | _____________________________________^ [INFO] [stdout] 207 | | .iter() [INFO] [stdout] | | ________________________________- [INFO] [stdout] 208 | || .cloned() [INFO] [stdout] 209 | || .filter(|r| r.name.contains(target)) [INFO] [stdout] | ||____________________________________________________________^ [INFO] [stdout] | |____________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.name.contains(target)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/workers.rs:16:23 [INFO] [stdout] | [INFO] [stdout] 16 | FinishedExecution(Duration), [INFO] [stdout] | ----------------- ^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this variant [INFO] [stdout] | [INFO] [stdout] = note: `WorkerEvent` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field [INFO] [stdout] | [INFO] [stdout] 16 - FinishedExecution(Duration), [INFO] [stdout] 16 + FinishedExecution(()), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_ok()` [INFO] [stdout] --> src/cli/init.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if let Ok(_) = File::open(&self.file_name) { [INFO] [stdout] | -------^^^^^------------------------------ help: try: `if File::open(&self.file_name).is_ok()` [INFO] [stdout] | [INFO] [stdout] = note: this will change drop order of the result, as well as all temporaries [INFO] [stdout] = note: add `#[allow(clippy::redundant_pattern_matching)]` if this is important [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:251:22 [INFO] [stdout] | [INFO] [stdout] 251 | &vec![ [INFO] [stdout] | ______________________^ [INFO] [stdout] 252 | | "The config file has changed while an instance was running.", [INFO] [stdout] 253 | | &format!("Config file: {}", file_changed), [INFO] [stdout] 254 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 251 ~ &["The config file has changed while an instance was running.", [INFO] [stdout] 252 + &format!("Config file: {}", file_changed)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:300:17 [INFO] [stdout] | [INFO] [stdout] 300 | / vec![ [INFO] [stdout] 301 | | "Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 302 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 303 | | ] [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 300 ~ ["Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 301 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:326:25 [INFO] [stdout] | [INFO] [stdout] 326 | / vec![ [INFO] [stdout] 327 | | "Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 328 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 329 | | ] [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 326 ~ ["Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 327 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:122:32 [INFO] [stdout] | [INFO] [stdout] 122 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 123 | | format!( [INFO] [stdout] 124 | | "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 125 | | name, watch_pattern [INFO] [stdout] ... | [INFO] [stdout] 128 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 129 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 122 ~ return Err([format!( [INFO] [stdout] 123 + "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 124 + name, watch_pattern [INFO] [stdout] 125 + ), [INFO] [stdout] 126 + format!(" {}", err), [INFO] [stdout] 127 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:139:32 [INFO] [stdout] | [INFO] [stdout] 139 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 140 | | format!( [INFO] [stdout] 141 | | "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 142 | | name, ignore_pattern [INFO] [stdout] ... | [INFO] [stdout] 145 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 146 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 139 ~ return Err([format!( [INFO] [stdout] 140 + "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 141 + name, ignore_pattern [INFO] [stdout] 142 + ), [INFO] [stdout] 143 + format!(" {}", err), [INFO] [stdout] 144 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:340:25 [INFO] [stdout] | [INFO] [stdout] 340 | / vec![ [INFO] [stdout] 341 | | "When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 342 | | "The output of command `find` is a good example", [INFO] [stdout] 343 | | ].join("\n"), [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 340 ~ ["When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 341 ~ "The output of command `find` is a good example"].join("\n"), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:407:10 [INFO] [stdout] | [INFO] [stdout] 407 | &vec![ [INFO] [stdout] | __________^ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] ... | [INFO] [stdout] 421 | | .to_string(), [INFO] [stdout] 422 | | ] [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 407 ~ &[format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:409:13 [INFO] [stdout] | [INFO] [stdout] 409 | / vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] 411 | | "Some example of valid patterns: ", [INFO] [stdout] 412 | | " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] ... | [INFO] [stdout] 418 | | " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 419 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 409 ~ ["", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/watcher.rs:24:28 [INFO] [stdout] | [INFO] [stdout] 24 | let warning = &vec![ [INFO] [stdout] | ____________________________^ [INFO] [stdout] 25 | | format!("unknown file/directory: '{}'", path), [INFO] [stdout] 26 | | format!("Different behaviour depending on the OS."), [INFO] [stdout] 27 | | format!("The watcher may not be triggered for this rule."), [INFO] [stdout] 28 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 24 ~ let warning = &[format!("unknown file/directory: '{}'", path), [INFO] [stdout] 25 + format!("Different behaviour depending on the OS."), [INFO] [stdout] 26 + format!("The watcher may not be triggered for this rule.")] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [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] 13 - return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [INFO] [stdout] 13 + format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | return format!("Hint: {}", hint); [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] 15 - return format!("Hint: {}", hint); [INFO] [stdout] 15 + format!("Hint: {}", hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: all variants have the same postfix: `Error` [INFO] [stdout] --> src/errors.rs:22:1 [INFO] [stdout] | [INFO] [stdout] 22 | / pub enum FzzError { [INFO] [stdout] 23 | | IoConfigError(String, Option), [INFO] [stdout] 24 | | IoStdinError(String, Hint), [INFO] [stdout] 25 | | InvalidConfigError(String, Option, Hint), [INFO] [stdout] ... | [INFO] [stdout] 28 | | GenericError(String), [INFO] [stdout] 29 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: remove the postfixes and use full paths to the variants instead of glob imports [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#enum_variant_names [INFO] [stdout] = note: `#[warn(clippy::enum_variant_names)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/errors.rs:78:21 [INFO] [stdout] | [INFO] [stdout] 78 | format!("{}", msg) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `msg.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: binary comparison to literal `Option::None` [INFO] [stdout] --> src/rules.rs:90:12 [INFO] [stdout] | [INFO] [stdout] 90 | if None == self.yaml { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.yaml.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/rules.rs:104:12 [INFO] [stdout] | [INFO] [stdout] 104 | if self.commands().len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.commands().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: length comparison to zero [INFO] [stdout] --> src/rules.rs:111:12 [INFO] [stdout] | [INFO] [stdout] 111 | if self.watch_patterns().len() == 0 && !self.run_on_init() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.watch_patterns().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/rules.rs:244:8 [INFO] [stdout] | [INFO] [stdout] 244 | if items.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `items.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: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:350:5 [INFO] [stdout] | [INFO] [stdout] 350 | return Ok(watches); [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] 350 - return Ok(watches); [INFO] [stdout] 350 + Ok(watches) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/rules.rs:328:9 [INFO] [stdout] | [INFO] [stdout] 328 | line_number = line_number + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `line_number += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:384:13 [INFO] [stdout] | [INFO] [stdout] 384 | return from_yaml(&content); [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] 384 - return from_yaml(&content); [INFO] [stdout] 384 + from_yaml(&content) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/rules.rs:406:45 [INFO] [stdout] | [INFO] [stdout] 406 | Pattern::new(&format!("**{}", pattern)).expect( [INFO] [stdout] | _____________________________________________^ [INFO] [stdout] 407 | | &vec![ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] ... | [INFO] [stdout] 423 | | .join("\n"), [INFO] [stdout] 424 | | ) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 406 ~ Pattern::new(&format!("**{}", pattern)).unwrap_or_else(|_| panic!("{}", vec![ [INFO] [stdout] 407 + format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string(), [INFO] [stdout] 421 + ] [INFO] [stdout] 422 + .join("\n"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/rules.rs:439:9 [INFO] [stdout] | [INFO] [stdout] 439 | / if let Err(err) = rule.validate() { [INFO] [stdout] 440 | | return Err(err); [INFO] [stdout] 441 | | } [INFO] [stdout] | |_________^ help: replace it with: `rule.validate()?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:496:9 [INFO] [stdout] | [INFO] [stdout] 496 | assert_eq!(true, rule.watch("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_assert_comparison)]` on by default [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 496 - assert_eq!(true, rule.watch("tests/foo.rs")); [INFO] [stdout] 496 + assert!(rule.watch("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:499:9 [INFO] [stdout] | [INFO] [stdout] 499 | assert_eq!(true, rule2.watch("src/foo.rsx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 499 - assert_eq!(true, rule2.watch("src/foo.rsx")); [INFO] [stdout] 499 + assert!(rule2.watch("src/foo.rsx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:500:9 [INFO] [stdout] | [INFO] [stdout] 500 | assert_eq!(true, rule2.watch("src/bar/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 500 - assert_eq!(true, rule2.watch("src/bar/foo.rs")); [INFO] [stdout] 500 + assert!(rule2.watch("src/bar/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:501:9 [INFO] [stdout] | [INFO] [stdout] 501 | assert_eq!(true, rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 501 - assert_eq!(true, rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] 501 + assert!(rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:502:9 [INFO] [stdout] | [INFO] [stdout] 502 | assert_eq!(true, rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 502 - assert_eq!(true, rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] 502 + assert!(rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:503:9 [INFO] [stdout] | [INFO] [stdout] 503 | assert_eq!(true, rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 503 - assert_eq!(true, rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] 503 + assert!(rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:504:9 [INFO] [stdout] | [INFO] [stdout] 504 | assert_eq!(true, rule2.watch("src/bar/foo.abc")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 504 - assert_eq!(true, rule2.watch("src/bar/foo.abc")); [INFO] [stdout] 504 + assert!(rule2.watch("src/bar/foo.abc")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:505:9 [INFO] [stdout] | [INFO] [stdout] 505 | assert_eq!(true, rule2.watch("src/bar/foo.abx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 505 - assert_eq!(true, rule2.watch("src/bar/foo.abx")); [INFO] [stdout] 505 + assert!(rule2.watch("src/bar/foo.abx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:507:9 [INFO] [stdout] | [INFO] [stdout] 507 | assert_eq!(false, rule2.watch("src/bar/foo.ab")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 507 - assert_eq!(false, rule2.watch("src/bar/foo.ab")); [INFO] [stdout] 507 + assert!(!rule2.watch("src/bar/foo.ab")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:521:9 [INFO] [stdout] | [INFO] [stdout] 521 | assert_eq!(false, rule.watch("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 521 - assert_eq!(false, rule.watch("tests/foo.rs")); [INFO] [stdout] 521 + assert!(!rule.watch("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:580:9 [INFO] [stdout] | [INFO] [stdout] 580 | assert_eq!(true, rule.ignore("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 580 - assert_eq!(true, rule.ignore("tests/foo.rs")); [INFO] [stdout] 580 + assert!(rule.ignore("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:595:9 [INFO] [stdout] | [INFO] [stdout] 595 | assert_eq!(false, rule.ignore("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 595 - assert_eq!(false, rule.ignore("tests/foo.rs")); [INFO] [stdout] 595 + assert!(!rule.ignore("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/rules.rs:668:34 [INFO] [stdout] | [INFO] [stdout] 668 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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: useless use of `format!` [INFO] [stdout] --> src/rules.rs:683:34 [INFO] [stdout] | [INFO] [stdout] 683 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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: useless use of `format!` [INFO] [stdout] --> src/rules.rs:717:34 [INFO] [stdout] | [INFO] [stdout] 717 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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 unit return type [INFO] [stdout] --> src/stdout.rs:68:56 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn print_time_elapsed(elapsed: std::time::Duration) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:91:43 [INFO] [stdout] | [INFO] [stdout] 91 | let errors: Vec> = results.iter().cloned().filter(|r| r.is_err()).collect(); [INFO] [stdout] | ^^^^^^^^^^^^^^-------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_err()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] = note: `#[warn(clippy::iter_overeager_cloned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:92:21 [INFO] [stdout] | [INFO] [stdout] 92 | let completed = results.iter().cloned().filter(|r| r.is_ok()).count(); [INFO] [stdout] | ^^^^^^^^^^^^^^------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_ok()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:120:22 [INFO] [stdout] | [INFO] [stdout] 120 | pub fn clear_screen() -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:19:20 [INFO] [stdout] | [INFO] [stdout] 19 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 20 | | .rules [INFO] [stdout] 21 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 22 | || .cloned() [INFO] [stdout] 23 | || .filter(|r| !r.ignore(path) && r.watch(path)) [INFO] [stdout] | ||_________________________________________________________^ [INFO] [stdout] | |_________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| !r.ignore(path) && r.watch(path)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:36:20 [INFO] [stdout] | [INFO] [stdout] 36 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 37 | | .rules [INFO] [stdout] 38 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 39 | || .cloned() [INFO] [stdout] 40 | || .filter(|r| r.run_on_init()) [INFO] [stdout] | ||________________________________________^ [INFO] [stdout] | |________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.run_on_init()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/watches.rs:56:14 [INFO] [stdout] | [INFO] [stdout] 56 | .map(|r| r.watch_absolute_paths()) [INFO] [stdout] | ______________^ [INFO] [stdout] 57 | | .flatten() [INFO] [stdout] | |______________________^ help: try replacing `map` with `flat_map` and remove the `.flatten()`: `flat_map(|r| r.watch_absolute_paths())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` 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/watches.rs:111:53 [INFO] [stdout] | [INFO] [stdout] 111 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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/watches.rs:127:53 [INFO] [stdout] | [INFO] [stdout] 127 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:138:53 [INFO] [stdout] | [INFO] [stdout] 138 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:155:53 [INFO] [stdout] | [INFO] [stdout] 155 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:171:53 [INFO] [stdout] | [INFO] [stdout] 171 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:195:53 [INFO] [stdout] | [INFO] [stdout] 195 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:212:53 [INFO] [stdout] | [INFO] [stdout] 212 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:226:53 [INFO] [stdout] | [INFO] [stdout] 226 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:250:53 [INFO] [stdout] | [INFO] [stdout] 250 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:289:53 [INFO] [stdout] | [INFO] [stdout] 289 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:312:13 [INFO] [stdout] | [INFO] [stdout] 312 | / &r#" [INFO] [stdout] 313 | | - name: run tests [INFO] [stdout] 314 | | run: [ [INFO] [stdout] 315 | | "yarn test {{filepath}}", [INFO] [stdout] 316 | | change: 'src/**' [INFO] [stdout] 317 | | "# [INFO] [stdout] | |__________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 312 ~ r#" [INFO] [stdout] 313 + - name: run tests [INFO] [stdout] 314 + run: [ [INFO] [stdout] 315 + "yarn test {{filepath}}", [INFO] [stdout] 316 + change: 'src/**' [INFO] [stdout] 317 + "# [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:322:13 [INFO] [stdout] | [INFO] [stdout] 322 | / &r#" [INFO] [stdout] 323 | | - name: other [INFO] [stdout] 324 | | run: 'cargo test' [INFO] [stdout] 325 | | change: 'test/**' [INFO] [stdout] 326 | | "# [INFO] [stdout] | |__________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 322 ~ r#" [INFO] [stdout] 323 + - name: other [INFO] [stdout] 324 + run: 'cargo test' [INFO] [stdout] 325 + change: 'test/**' [INFO] [stdout] 326 + "# [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/workers.rs:48:32 [INFO] [stdout] | [INFO] [stdout] 48 | ... && !results.clone().into_iter().find(|r| r.is_err()).is_none()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `results.clone().into_iter().find(|r| r.is_err()).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: unnecessary closure used to substitute value for `Option::None` [INFO] [stdout] --> src/yaml.rs:11:35 [INFO] [stdout] | [INFO] [stdout] 11 | .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations [INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` on by default [INFO] [stdout] help: use `unwrap_or` instead [INFO] [stdout] | [INFO] [stdout] 11 - .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] 11 + .map(|i| String::from(i.as_str().unwrap_or("_invalid_value_"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:18:32 [INFO] [stdout] | [INFO] [stdout] 18 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:32:32 [INFO] [stdout] | [INFO] [stdout] 32 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:61:32 [INFO] [stdout] | [INFO] [stdout] 61 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:75:32 [INFO] [stdout] | [INFO] [stdout] 75 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: field `0` is never read [INFO] [stdout] --> src/workers.rs:16:23 [INFO] [stdout] | [INFO] [stdout] 16 | FinishedExecution(Duration), [INFO] [stdout] | ----------------- ^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this variant [INFO] [stdout] | [INFO] [stdout] = note: `WorkerEvent` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field [INFO] [stdout] | [INFO] [stdout] 16 - FinishedExecution(Duration), [INFO] [stdout] 16 + FinishedExecution(()), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/main.rs:206:36 [INFO] [stdout] | [INFO] [stdout] 206 | let filtered = rules [INFO] [stdout] | _____________________________________^ [INFO] [stdout] 207 | | .iter() [INFO] [stdout] | | ________________________________- [INFO] [stdout] 208 | || .cloned() [INFO] [stdout] 209 | || .filter(|r| r.name.contains(target)) [INFO] [stdout] | ||____________________________________________________________^ [INFO] [stdout] | |____________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.name.contains(target)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_ok()` [INFO] [stdout] --> src/cli/init.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if let Ok(_) = File::open(&self.file_name) { [INFO] [stdout] | -------^^^^^------------------------------ help: try: `if File::open(&self.file_name).is_ok()` [INFO] [stdout] | [INFO] [stdout] = note: this will change drop order of the result, as well as all temporaries [INFO] [stdout] = note: add `#[allow(clippy::redundant_pattern_matching)]` if this is important [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:251:22 [INFO] [stdout] | [INFO] [stdout] 251 | &vec![ [INFO] [stdout] | ______________________^ [INFO] [stdout] 252 | | "The config file has changed while an instance was running.", [INFO] [stdout] 253 | | &format!("Config file: {}", file_changed), [INFO] [stdout] 254 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 251 ~ &["The config file has changed while an instance was running.", [INFO] [stdout] 252 + &format!("Config file: {}", file_changed)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:300:17 [INFO] [stdout] | [INFO] [stdout] 300 | / vec![ [INFO] [stdout] 301 | | "Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 302 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 303 | | ] [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 300 ~ ["Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 301 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:326:25 [INFO] [stdout] | [INFO] [stdout] 326 | / vec![ [INFO] [stdout] 327 | | "Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 328 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 329 | | ] [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 326 ~ ["Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 327 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:122:32 [INFO] [stdout] | [INFO] [stdout] 122 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 123 | | format!( [INFO] [stdout] 124 | | "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 125 | | name, watch_pattern [INFO] [stdout] ... | [INFO] [stdout] 128 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 129 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 122 ~ return Err([format!( [INFO] [stdout] 123 + "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 124 + name, watch_pattern [INFO] [stdout] 125 + ), [INFO] [stdout] 126 + format!(" {}", err), [INFO] [stdout] 127 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:139:32 [INFO] [stdout] | [INFO] [stdout] 139 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 140 | | format!( [INFO] [stdout] 141 | | "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 142 | | name, ignore_pattern [INFO] [stdout] ... | [INFO] [stdout] 145 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 146 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 139 ~ return Err([format!( [INFO] [stdout] 140 + "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 141 + name, ignore_pattern [INFO] [stdout] 142 + ), [INFO] [stdout] 143 + format!(" {}", err), [INFO] [stdout] 144 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:340:25 [INFO] [stdout] | [INFO] [stdout] 340 | / vec![ [INFO] [stdout] 341 | | "When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 342 | | "The output of command `find` is a good example", [INFO] [stdout] 343 | | ].join("\n"), [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 340 ~ ["When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 341 ~ "The output of command `find` is a good example"].join("\n"), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:407:10 [INFO] [stdout] | [INFO] [stdout] 407 | &vec![ [INFO] [stdout] | __________^ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] ... | [INFO] [stdout] 421 | | .to_string(), [INFO] [stdout] 422 | | ] [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 407 ~ &[format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:409:13 [INFO] [stdout] | [INFO] [stdout] 409 | / vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] 411 | | "Some example of valid patterns: ", [INFO] [stdout] 412 | | " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] ... | [INFO] [stdout] 418 | | " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 419 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 409 ~ ["", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:746:13 [INFO] [stdout] | [INFO] [stdout] 746 | / vec![ [INFO] [stdout] 747 | | "name: my tests", [INFO] [stdout] 748 | | "run: cargo tests {{filepath}}", [INFO] [stdout] 749 | | "change: tests/**", [INFO] [stdout] 750 | | "run_on_init: true", [INFO] [stdout] 751 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 746 ~ ["name: my tests", [INFO] [stdout] 747 + "run: cargo tests {{filepath}}", [INFO] [stdout] 748 + "change: tests/**", [INFO] [stdout] 749 + "run_on_init: true"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:774:13 [INFO] [stdout] | [INFO] [stdout] 774 | / vec![ [INFO] [stdout] 775 | | "Failed to load configuration at line:", [INFO] [stdout] 776 | | "| run: 'cargo tests'", [INFO] [stdout] 777 | | "|> change: **/*", [INFO] [stdout] ... | [INFO] [stdout] 780 | | "Hint: Check for wrong types, any missing quotes for glob pattern or incorrect identation", [INFO] [stdout] 781 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 774 ~ ["Failed to load configuration at line:", [INFO] [stdout] 775 + "| run: 'cargo tests'", [INFO] [stdout] 776 + "|> change: **/*", [INFO] [stdout] 777 + "| ", [INFO] [stdout] 778 + "Reason: while scanning an anchor or alias, did not find expected alphabetic or numeric character at line 8 column 19", [INFO] [stdout] 779 + "Hint: Check for wrong types, any missing quotes for glob pattern or incorrect identation"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:792:13 [INFO] [stdout] | [INFO] [stdout] 792 | / vec![ [INFO] [stdout] 793 | | "Configuration file is invalid! There are no rules to watch", [INFO] [stdout] 794 | | "Hint: Make sure to declare at least one rule. Try to run `fzz init` to generate a new configuration from scratch", [INFO] [stdout] 795 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 792 ~ ["Configuration file is invalid! There are no rules to watch", [INFO] [stdout] 793 + "Hint: Make sure to declare at least one rule. Try to run `fzz init` to generate a new configuration from scratch"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:809:13 [INFO] [stdout] | [INFO] [stdout] 809 | / vec![ [INFO] [stdout] 810 | | "Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 811 | | "```yaml", [INFO] [stdout] 812 | | "on:", [INFO] [stdout] ... | [INFO] [stdout] 816 | | "Hint: Make sure to declare the rules as a list without any root property", [INFO] [stdout] 817 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 809 ~ ["Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 810 + "```yaml", [INFO] [stdout] 811 + "on:", [INFO] [stdout] 812 + " - name: foo", [INFO] [stdout] 813 + " run: echo foo", [INFO] [stdout] 814 + "```", [INFO] [stdout] 815 + "Hint: Make sure to declare the rules as a list without any root property"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/watcher.rs:24:28 [INFO] [stdout] | [INFO] [stdout] 24 | let warning = &vec![ [INFO] [stdout] | ____________________________^ [INFO] [stdout] 25 | | format!("unknown file/directory: '{}'", path), [INFO] [stdout] 26 | | format!("Different behaviour depending on the OS."), [INFO] [stdout] 27 | | format!("The watcher may not be triggered for this rule."), [INFO] [stdout] 28 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 24 ~ let warning = &[format!("unknown file/directory: '{}'", path), [INFO] [stdout] 25 + format!("Different behaviour depending on the OS."), [INFO] [stdout] 26 + format!("The watcher may not be triggered for this rule.")] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [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] 13 - return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [INFO] [stdout] 13 + format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | return format!("Hint: {}", hint); [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] 15 - return format!("Hint: {}", hint); [INFO] [stdout] 15 + format!("Hint: {}", hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: all variants have the same postfix: `Error` [INFO] [stdout] --> src/errors.rs:22:1 [INFO] [stdout] | [INFO] [stdout] 22 | / pub enum FzzError { [INFO] [stdout] 23 | | IoConfigError(String, Option), [INFO] [stdout] 24 | | IoStdinError(String, Hint), [INFO] [stdout] 25 | | InvalidConfigError(String, Option, Hint), [INFO] [stdout] ... | [INFO] [stdout] 28 | | GenericError(String), [INFO] [stdout] 29 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: remove the postfixes and use full paths to the variants instead of glob imports [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#enum_variant_names [INFO] [stdout] = note: `#[warn(clippy::enum_variant_names)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/errors.rs:78:21 [INFO] [stdout] | [INFO] [stdout] 78 | format!("{}", msg) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `msg.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: binary comparison to literal `Option::None` [INFO] [stdout] --> src/rules.rs:90:12 [INFO] [stdout] | [INFO] [stdout] 90 | if None == self.yaml { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.yaml.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/rules.rs:104:12 [INFO] [stdout] | [INFO] [stdout] 104 | if self.commands().len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.commands().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: length comparison to zero [INFO] [stdout] --> src/rules.rs:111:12 [INFO] [stdout] | [INFO] [stdout] 111 | if self.watch_patterns().len() == 0 && !self.run_on_init() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.watch_patterns().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/rules.rs:244:8 [INFO] [stdout] | [INFO] [stdout] 244 | if items.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `items.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: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:350:5 [INFO] [stdout] | [INFO] [stdout] 350 | return Ok(watches); [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] 350 - return Ok(watches); [INFO] [stdout] 350 + Ok(watches) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/rules.rs:328:9 [INFO] [stdout] | [INFO] [stdout] 328 | line_number = line_number + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `line_number += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:384:13 [INFO] [stdout] | [INFO] [stdout] 384 | return from_yaml(&content); [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] 384 - return from_yaml(&content); [INFO] [stdout] 384 + from_yaml(&content) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/rules.rs:406:45 [INFO] [stdout] | [INFO] [stdout] 406 | Pattern::new(&format!("**{}", pattern)).expect( [INFO] [stdout] | _____________________________________________^ [INFO] [stdout] 407 | | &vec![ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] ... | [INFO] [stdout] 423 | | .join("\n"), [INFO] [stdout] 424 | | ) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 406 ~ Pattern::new(&format!("**{}", pattern)).unwrap_or_else(|_| panic!("{}", vec![ [INFO] [stdout] 407 + format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string(), [INFO] [stdout] 421 + ] [INFO] [stdout] 422 + .join("\n"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/rules.rs:439:9 [INFO] [stdout] | [INFO] [stdout] 439 | / if let Err(err) = rule.validate() { [INFO] [stdout] 440 | | return Err(err); [INFO] [stdout] 441 | | } [INFO] [stdout] | |_________^ help: replace it with: `rule.validate()?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:68:56 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn print_time_elapsed(elapsed: std::time::Duration) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:91:43 [INFO] [stdout] | [INFO] [stdout] 91 | let errors: Vec> = results.iter().cloned().filter(|r| r.is_err()).collect(); [INFO] [stdout] | ^^^^^^^^^^^^^^-------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_err()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] = note: `#[warn(clippy::iter_overeager_cloned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:92:21 [INFO] [stdout] | [INFO] [stdout] 92 | let completed = results.iter().cloned().filter(|r| r.is_ok()).count(); [INFO] [stdout] | ^^^^^^^^^^^^^^------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_ok()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:120:22 [INFO] [stdout] | [INFO] [stdout] 120 | pub fn clear_screen() -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `0` is never read [INFO] [stdout] --> src/workers.rs:16:23 [INFO] [stdout] | [INFO] [stdout] 16 | FinishedExecution(Duration), [INFO] [stdout] | ----------------- ^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | field in this variant [INFO] [stdout] | [INFO] [stdout] = note: `WorkerEvent` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field [INFO] [stdout] | [INFO] [stdout] 16 - FinishedExecution(Duration), [INFO] [stdout] 16 + FinishedExecution(()), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant pattern matching, consider using `is_ok()` [INFO] [stdout] --> src/cli/init.rs:42:16 [INFO] [stdout] | [INFO] [stdout] 42 | if let Ok(_) = File::open(&self.file_name) { [INFO] [stdout] | -------^^^^^------------------------------ help: try: `if File::open(&self.file_name).is_ok()` [INFO] [stdout] | [INFO] [stdout] = note: this will change drop order of the result, as well as all temporaries [INFO] [stdout] = note: add `#[allow(clippy::redundant_pattern_matching)]` if this is important [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_pattern_matching [INFO] [stdout] = note: `#[warn(clippy::redundant_pattern_matching)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:19:20 [INFO] [stdout] | [INFO] [stdout] 19 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 20 | | .rules [INFO] [stdout] 21 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 22 | || .cloned() [INFO] [stdout] 23 | || .filter(|r| !r.ignore(path) && r.watch(path)) [INFO] [stdout] | ||_________________________________________________________^ [INFO] [stdout] | |_________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| !r.ignore(path) && r.watch(path)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:36:20 [INFO] [stdout] | [INFO] [stdout] 36 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 37 | | .rules [INFO] [stdout] 38 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 39 | || .cloned() [INFO] [stdout] 40 | || .filter(|r| r.run_on_init()) [INFO] [stdout] | ||________________________________________^ [INFO] [stdout] | |________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.run_on_init()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/watches.rs:56:14 [INFO] [stdout] | [INFO] [stdout] 56 | .map(|r| r.watch_absolute_paths()) [INFO] [stdout] | ______________^ [INFO] [stdout] 57 | | .flatten() [INFO] [stdout] | |______________________^ help: try replacing `map` with `flat_map` and remove the `.flatten()`: `flat_map(|r| r.watch_absolute_paths())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/workers.rs:48:32 [INFO] [stdout] | [INFO] [stdout] 48 | ... && !results.clone().into_iter().find(|r| r.is_err()).is_none()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `results.clone().into_iter().find(|r| r.is_err()).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: unnecessary closure used to substitute value for `Option::None` [INFO] [stdout] --> src/yaml.rs:11:35 [INFO] [stdout] | [INFO] [stdout] 11 | .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations [INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` on by default [INFO] [stdout] help: use `unwrap_or` instead [INFO] [stdout] | [INFO] [stdout] 11 - .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] 11 + .map(|i| String::from(i.as_str().unwrap_or("_invalid_value_"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:18:32 [INFO] [stdout] | [INFO] [stdout] 18 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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/yaml.rs:32:32 [INFO] [stdout] | [INFO] [stdout] 32 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:13:9 [INFO] [stdout] | [INFO] [stdout] 13 | return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [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] 13 - return format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint); [INFO] [stdout] 13 + format!("{}Hint{}: {}", stdout::BLUE, stdout::RESET, hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/errors.rs:15:9 [INFO] [stdout] | [INFO] [stdout] 15 | return format!("Hint: {}", hint); [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] 15 - return format!("Hint: {}", hint); [INFO] [stdout] 15 + format!("Hint: {}", hint) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:61:32 [INFO] [stdout] | [INFO] [stdout] 61 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: all variants have the same postfix: `Error` [INFO] [stdout] --> src/errors.rs:22:1 [INFO] [stdout] | [INFO] [stdout] 22 | / pub enum FzzError { [INFO] [stdout] 23 | | IoConfigError(String, Option), [INFO] [stdout] 24 | | IoStdinError(String, Hint), [INFO] [stdout] 25 | | InvalidConfigError(String, Option, Hint), [INFO] [stdout] ... | [INFO] [stdout] 28 | | GenericError(String), [INFO] [stdout] 29 | | } [INFO] [stdout] | |_^ [INFO] [stdout] | [INFO] [stdout] = help: remove the postfixes and use full paths to the variants instead of glob imports [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#enum_variant_names [INFO] [stdout] = note: `#[warn(clippy::enum_variant_names)]` 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/yaml.rs:75:32 [INFO] [stdout] | [INFO] [stdout] 75 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: useless use of `format!` [INFO] [stdout] --> src/errors.rs:78:21 [INFO] [stdout] | [INFO] [stdout] 78 | format!("{}", msg) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `msg.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: binary comparison to literal `Option::None` [INFO] [stdout] --> src/rules.rs:90:12 [INFO] [stdout] | [INFO] [stdout] 90 | if None == self.yaml { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: use `Option::is_none()` instead: `self.yaml.is_none()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none [INFO] [stdout] = note: `#[warn(clippy::partialeq_to_none)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/rules.rs:104:12 [INFO] [stdout] | [INFO] [stdout] 104 | if self.commands().len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.commands().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: length comparison to zero [INFO] [stdout] --> src/rules.rs:111:12 [INFO] [stdout] | [INFO] [stdout] 111 | if self.watch_patterns().len() == 0 && !self.run_on_init() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `self.watch_patterns().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/rules.rs:244:8 [INFO] [stdout] | [INFO] [stdout] 244 | if items.len() == 0 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `items.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: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:350:5 [INFO] [stdout] | [INFO] [stdout] 350 | return Ok(watches); [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] 350 - return Ok(watches); [INFO] [stdout] 350 + Ok(watches) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/rules.rs:328:9 [INFO] [stdout] | [INFO] [stdout] 328 | line_number = line_number + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `line_number += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/rules.rs:384:13 [INFO] [stdout] | [INFO] [stdout] 384 | return from_yaml(&content); [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] 384 - return from_yaml(&content); [INFO] [stdout] 384 + from_yaml(&content) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/main.rs:206:36 [INFO] [stdout] | [INFO] [stdout] 206 | let filtered = rules [INFO] [stdout] | _____________________________________^ [INFO] [stdout] 207 | | .iter() [INFO] [stdout] | | ________________________________- [INFO] [stdout] 208 | || .cloned() [INFO] [stdout] 209 | || .filter(|r| r.name.contains(target)) [INFO] [stdout] | ||____________________________________________________________^ [INFO] [stdout] | |____________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.name.contains(target)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function call inside of `expect` [INFO] [stdout] --> src/rules.rs:406:45 [INFO] [stdout] | [INFO] [stdout] 406 | Pattern::new(&format!("**{}", pattern)).expect( [INFO] [stdout] | _____________________________________________^ [INFO] [stdout] 407 | | &vec![ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] ... | [INFO] [stdout] 423 | | .join("\n"), [INFO] [stdout] 424 | | ) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#expect_fun_call [INFO] [stdout] = note: `#[warn(clippy::expect_fun_call)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 406 ~ Pattern::new(&format!("**{}", pattern)).unwrap_or_else(|_| panic!("{}", vec![ [INFO] [stdout] 407 + format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string(), [INFO] [stdout] 421 + ] [INFO] [stdout] 422 + .join("\n"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this block may be rewritten with the `?` operator [INFO] [stdout] --> src/rules.rs:439:9 [INFO] [stdout] | [INFO] [stdout] 439 | / if let Err(err) = rule.validate() { [INFO] [stdout] 440 | | return Err(err); [INFO] [stdout] 441 | | } [INFO] [stdout] | |_________^ help: replace it with: `rule.validate()?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] = note: `#[warn(clippy::question_mark)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:496:9 [INFO] [stdout] | [INFO] [stdout] 496 | assert_eq!(true, rule.watch("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_assert_comparison)]` on by default [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 496 - assert_eq!(true, rule.watch("tests/foo.rs")); [INFO] [stdout] 496 + assert!(rule.watch("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:499:9 [INFO] [stdout] | [INFO] [stdout] 499 | assert_eq!(true, rule2.watch("src/foo.rsx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 499 - assert_eq!(true, rule2.watch("src/foo.rsx")); [INFO] [stdout] 499 + assert!(rule2.watch("src/foo.rsx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:500:9 [INFO] [stdout] | [INFO] [stdout] 500 | assert_eq!(true, rule2.watch("src/bar/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 500 - assert_eq!(true, rule2.watch("src/bar/foo.rs")); [INFO] [stdout] 500 + assert!(rule2.watch("src/bar/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:501:9 [INFO] [stdout] | [INFO] [stdout] 501 | assert_eq!(true, rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 501 - assert_eq!(true, rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] 501 + assert!(rule2.watch("src/bar/foo.rsx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:502:9 [INFO] [stdout] | [INFO] [stdout] 502 | assert_eq!(true, rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 502 - assert_eq!(true, rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] 502 + assert!(rule2.watch("src/bar/foo.rs3")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:503:9 [INFO] [stdout] | [INFO] [stdout] 503 | assert_eq!(true, rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 503 - assert_eq!(true, rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] 503 + assert!(rule2.watch("src/bar/foo.rs&")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:251:22 [INFO] [stdout] | [INFO] [stdout] 251 | &vec![ [INFO] [stdout] | ______________________^ [INFO] [stdout] 252 | | "The config file has changed while an instance was running.", [INFO] [stdout] 253 | | &format!("Config file: {}", file_changed), [INFO] [stdout] 254 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 251 ~ &["The config file has changed while an instance was running.", [INFO] [stdout] 252 + &format!("Config file: {}", file_changed)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:300:17 [INFO] [stdout] | [INFO] [stdout] 300 | / vec![ [INFO] [stdout] 301 | | "Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 302 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 303 | | ] [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 300 ~ ["Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 301 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:504:9 [INFO] [stdout] | [INFO] [stdout] 504 | assert_eq!(true, rule2.watch("src/bar/foo.abc")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 504 - assert_eq!(true, rule2.watch("src/bar/foo.abc")); [INFO] [stdout] 504 + assert!(rule2.watch("src/bar/foo.abc")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:326:25 [INFO] [stdout] | [INFO] [stdout] 326 | / vec![ [INFO] [stdout] 327 | | "Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 328 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 329 | | ] [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 326 ~ ["Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 327 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:122:32 [INFO] [stdout] | [INFO] [stdout] 122 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 123 | | format!( [INFO] [stdout] 124 | | "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 125 | | name, watch_pattern [INFO] [stdout] ... | [INFO] [stdout] 128 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 129 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 122 ~ return Err([format!( [INFO] [stdout] 123 + "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 124 + name, watch_pattern [INFO] [stdout] 125 + ), [INFO] [stdout] 126 + format!(" {}", err), [INFO] [stdout] 127 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:139:32 [INFO] [stdout] | [INFO] [stdout] 139 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 140 | | format!( [INFO] [stdout] 141 | | "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 142 | | name, ignore_pattern [INFO] [stdout] ... | [INFO] [stdout] 145 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 146 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 139 ~ return Err([format!( [INFO] [stdout] 140 + "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 141 + name, ignore_pattern [INFO] [stdout] 142 + ), [INFO] [stdout] 143 + format!(" {}", err), [INFO] [stdout] 144 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:340:25 [INFO] [stdout] | [INFO] [stdout] 340 | / vec![ [INFO] [stdout] 341 | | "When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 342 | | "The output of command `find` is a good example", [INFO] [stdout] 343 | | ].join("\n"), [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 340 ~ ["When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 341 ~ "The output of command `find` is a good example"].join("\n"), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:505:9 [INFO] [stdout] | [INFO] [stdout] 505 | assert_eq!(true, rule2.watch("src/bar/foo.abx")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 505 - assert_eq!(true, rule2.watch("src/bar/foo.abx")); [INFO] [stdout] 505 + assert!(rule2.watch("src/bar/foo.abx")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:507:9 [INFO] [stdout] | [INFO] [stdout] 507 | assert_eq!(false, rule2.watch("src/bar/foo.ab")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 507 - assert_eq!(false, rule2.watch("src/bar/foo.ab")); [INFO] [stdout] 507 + assert!(!rule2.watch("src/bar/foo.ab")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:407:10 [INFO] [stdout] | [INFO] [stdout] 407 | &vec![ [INFO] [stdout] | __________^ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] ... | [INFO] [stdout] 421 | | .to_string(), [INFO] [stdout] 422 | | ] [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 407 ~ &[format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:409:13 [INFO] [stdout] | [INFO] [stdout] 409 | / vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] 411 | | "Some example of valid patterns: ", [INFO] [stdout] 412 | | " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] ... | [INFO] [stdout] 418 | | " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 419 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 409 ~ ["", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/watcher.rs:24:28 [INFO] [stdout] | [INFO] [stdout] 24 | let warning = &vec![ [INFO] [stdout] | ____________________________^ [INFO] [stdout] 25 | | format!("unknown file/directory: '{}'", path), [INFO] [stdout] 26 | | format!("Different behaviour depending on the OS."), [INFO] [stdout] 27 | | format!("The watcher may not be triggered for this rule."), [INFO] [stdout] 28 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 24 ~ let warning = &[format!("unknown file/directory: '{}'", path), [INFO] [stdout] 25 + format!("Different behaviour depending on the OS."), [INFO] [stdout] 26 + format!("The watcher may not be triggered for this rule.")] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:521:9 [INFO] [stdout] | [INFO] [stdout] 521 | assert_eq!(false, rule.watch("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 521 - assert_eq!(false, rule.watch("tests/foo.rs")); [INFO] [stdout] 521 + assert!(!rule.watch("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:580:9 [INFO] [stdout] | [INFO] [stdout] 580 | assert_eq!(true, rule.ignore("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 580 - assert_eq!(true, rule.ignore("tests/foo.rs")); [INFO] [stdout] 580 + assert!(rule.ignore("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/rules.rs:595:9 [INFO] [stdout] | [INFO] [stdout] 595 | assert_eq!(false, rule.ignore("tests/foo.rs")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [INFO] [stdout] help: replace it with `assert!(..)` [INFO] [stdout] | [INFO] [stdout] 595 - assert_eq!(false, rule.ignore("tests/foo.rs")); [INFO] [stdout] 595 + assert!(!rule.ignore("tests/foo.rs")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/rules.rs:668:34 [INFO] [stdout] | [INFO] [stdout] 668 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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: useless use of `format!` [INFO] [stdout] --> src/rules.rs:683:34 [INFO] [stdout] | [INFO] [stdout] 683 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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: useless use of `format!` [INFO] [stdout] --> src/rules.rs:717:34 [INFO] [stdout] | [INFO] [stdout] 717 | current_dir: format!("{}", "/foo/bar"), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"/foo/bar".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 unit return type [INFO] [stdout] --> src/stdout.rs:68:56 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn print_time_elapsed(elapsed: std::time::Duration) -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] = note: `#[warn(clippy::unused_unit)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:91:43 [INFO] [stdout] | [INFO] [stdout] 91 | let errors: Vec> = results.iter().cloned().filter(|r| r.is_err()).collect(); [INFO] [stdout] | ^^^^^^^^^^^^^^-------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_err()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] = note: `#[warn(clippy::iter_overeager_cloned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/stdout.rs:92:21 [INFO] [stdout] | [INFO] [stdout] 92 | let completed = results.iter().cloned().filter(|r| r.is_ok()).count(); [INFO] [stdout] | ^^^^^^^^^^^^^^------------------------------- [INFO] [stdout] | | [INFO] [stdout] | help: try: `.filter(|&r| r.is_ok()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded unit return type [INFO] [stdout] --> src/stdout.rs:120:22 [INFO] [stdout] | [INFO] [stdout] 120 | pub fn clear_screen() -> () { [INFO] [stdout] | ^^^^^^ help: remove the `-> ()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:19:20 [INFO] [stdout] | [INFO] [stdout] 19 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 20 | | .rules [INFO] [stdout] 21 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 22 | || .cloned() [INFO] [stdout] 23 | || .filter(|r| !r.ignore(path) && r.watch(path)) [INFO] [stdout] | ||_________________________________________________________^ [INFO] [stdout] | |_________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| !r.ignore(path) && r.watch(path)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/watches.rs:36:20 [INFO] [stdout] | [INFO] [stdout] 36 | let cmds = self [INFO] [stdout] | _____________________^ [INFO] [stdout] 37 | | .rules [INFO] [stdout] 38 | | .iter() [INFO] [stdout] | | ____________________- [INFO] [stdout] 39 | || .cloned() [INFO] [stdout] 40 | || .filter(|r| r.run_on_init()) [INFO] [stdout] | ||________________________________________^ [INFO] [stdout] | |________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.run_on_init()).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `map(..).flatten()` on `Iterator` [INFO] [stdout] --> src/watches.rs:56:14 [INFO] [stdout] | [INFO] [stdout] 56 | .map(|r| r.watch_absolute_paths()) [INFO] [stdout] | ______________^ [INFO] [stdout] 57 | | .flatten() [INFO] [stdout] | |______________________^ help: try replacing `map` with `flat_map` and remove the `.flatten()`: `flat_map(|r| r.watch_absolute_paths())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten [INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` 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/watches.rs:111:53 [INFO] [stdout] | [INFO] [stdout] 111 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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/watches.rs:127:53 [INFO] [stdout] | [INFO] [stdout] 127 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:138:53 [INFO] [stdout] | [INFO] [stdout] 138 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:155:53 [INFO] [stdout] | [INFO] [stdout] 155 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:171:53 [INFO] [stdout] | [INFO] [stdout] 171 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:195:53 [INFO] [stdout] | [INFO] [stdout] 195 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:212:53 [INFO] [stdout] | [INFO] [stdout] 212 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:226:53 [INFO] [stdout] | [INFO] [stdout] 226 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:250:53 [INFO] [stdout] | [INFO] [stdout] 250 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:289:53 [INFO] [stdout] | [INFO] [stdout] 289 | let watches = Watches::new(rules::from_yaml(&file_content).expect("Error parsing yaml")); [INFO] [stdout] | ^^^^^^^^^^^^^ help: change this to: `file_content` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:312:13 [INFO] [stdout] | [INFO] [stdout] 312 | / &r#" [INFO] [stdout] 313 | | - name: run tests [INFO] [stdout] 314 | | run: [ [INFO] [stdout] 315 | | "yarn test {{filepath}}", [INFO] [stdout] 316 | | change: 'src/**' [INFO] [stdout] 317 | | "# [INFO] [stdout] | |__________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 312 ~ r#" [INFO] [stdout] 313 + - name: run tests [INFO] [stdout] 314 + run: [ [INFO] [stdout] 315 + "yarn test {{filepath}}", [INFO] [stdout] 316 + change: 'src/**' [INFO] [stdout] 317 + "# [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/watches.rs:322:13 [INFO] [stdout] | [INFO] [stdout] 322 | / &r#" [INFO] [stdout] 323 | | - name: other [INFO] [stdout] 324 | | run: 'cargo test' [INFO] [stdout] 325 | | change: 'test/**' [INFO] [stdout] 326 | | "# [INFO] [stdout] | |__________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 322 ~ r#" [INFO] [stdout] 323 + - name: other [INFO] [stdout] 324 + run: 'cargo test' [INFO] [stdout] 325 + change: 'test/**' [INFO] [stdout] 326 + "# [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/workers.rs:48:32 [INFO] [stdout] | [INFO] [stdout] 48 | ... && !results.clone().into_iter().find(|r| r.is_err()).is_none()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `results.clone().into_iter().find(|r| r.is_err()).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: unnecessary closure used to substitute value for `Option::None` [INFO] [stdout] --> src/yaml.rs:11:35 [INFO] [stdout] | [INFO] [stdout] 11 | .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations [INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` on by default [INFO] [stdout] help: use `unwrap_or` instead [INFO] [stdout] | [INFO] [stdout] 11 - .map(|i| String::from(i.as_str().unwrap_or_else(|| "_invalid_value_"))) [INFO] [stdout] 11 + .map(|i| String::from(i.as_str().unwrap_or("_invalid_value_"))) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:18:32 [INFO] [stdout] | [INFO] [stdout] 18 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:32:32 [INFO] [stdout] | [INFO] [stdout] 32 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:61:32 [INFO] [stdout] | [INFO] [stdout] 61 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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 expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/yaml.rs:75:32 [INFO] [stdout] | [INFO] [stdout] 75 | yaml_to_string(&yaml, 0), [INFO] [stdout] | ^^^^^ help: change this to: `yaml` [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: unnecessarily eager cloning of iterator items [INFO] [stdout] --> src/main.rs:206:36 [INFO] [stdout] | [INFO] [stdout] 206 | let filtered = rules [INFO] [stdout] | _____________________________________^ [INFO] [stdout] 207 | | .iter() [INFO] [stdout] | | ________________________________- [INFO] [stdout] 208 | || .cloned() [INFO] [stdout] 209 | || .filter(|r| r.name.contains(target)) [INFO] [stdout] | ||____________________________________________________________^ [INFO] [stdout] | |____________________________________________________________| [INFO] [stdout] | help: try: `.filter(|&r| r.name.contains(target)).cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:251:22 [INFO] [stdout] | [INFO] [stdout] 251 | &vec![ [INFO] [stdout] | ______________________^ [INFO] [stdout] 252 | | "The config file has changed while an instance was running.", [INFO] [stdout] 253 | | &format!("Config file: {}", file_changed), [INFO] [stdout] 254 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] = note: `#[warn(clippy::useless_vec)]` on by default [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 251 ~ &["The config file has changed while an instance was running.", [INFO] [stdout] 252 + &format!("Config file: {}", file_changed)] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:300:17 [INFO] [stdout] | [INFO] [stdout] 300 | / vec![ [INFO] [stdout] 301 | | "Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 302 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 303 | | ] [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 300 ~ ["Hint: Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 301 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/main.rs:326:25 [INFO] [stdout] | [INFO] [stdout] 326 | / vec![ [INFO] [stdout] 327 | | "Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 328 | | "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string(), [INFO] [stdout] 329 | | ] [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 326 ~ ["Did you forget to pipe an output of a command?".to_string(), [INFO] [stdout] 327 + "Try `find . | fzz 'echo \"changed: {{filepath}}\"'`".to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:122:32 [INFO] [stdout] | [INFO] [stdout] 122 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 123 | | format!( [INFO] [stdout] 124 | | "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 125 | | name, watch_pattern [INFO] [stdout] ... | [INFO] [stdout] 128 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 129 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 122 ~ return Err([format!( [INFO] [stdout] 123 + "Rule '{}' contains an invalid `change` glob pattern '{}'.", [INFO] [stdout] 124 + name, watch_pattern [INFO] [stdout] 125 + ), [INFO] [stdout] 126 + format!(" {}", err), [INFO] [stdout] 127 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:139:32 [INFO] [stdout] | [INFO] [stdout] 139 | return Err(vec![ [INFO] [stdout] | ________________________________^ [INFO] [stdout] 140 | | format!( [INFO] [stdout] 141 | | "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 142 | | name, ignore_pattern [INFO] [stdout] ... | [INFO] [stdout] 145 | | " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned(), [INFO] [stdout] 146 | | ] [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 139 ~ return Err([format!( [INFO] [stdout] 140 + "Rule '{}' contains an invalid `ignore` glob pattern '{}'.", [INFO] [stdout] 141 + name, ignore_pattern [INFO] [stdout] 142 + ), [INFO] [stdout] 143 + format!(" {}", err), [INFO] [stdout] 144 + " Read more: https://en.wikipedia.org/wiki/Glob_(programming)".to_owned()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:340:25 [INFO] [stdout] | [INFO] [stdout] 340 | / vec![ [INFO] [stdout] 341 | | "When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 342 | | "The output of command `find` is a good example", [INFO] [stdout] 343 | | ].join("\n"), [INFO] [stdout] | |_________________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 340 ~ ["When using stdin, make sure to provide a list of valid files or directories.", [INFO] [stdout] 341 ~ "The output of command `find` is a good example"].join("\n"), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:407:10 [INFO] [stdout] | [INFO] [stdout] 407 | &vec![ [INFO] [stdout] | __________^ [INFO] [stdout] 408 | | format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 409 | | vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] ... | [INFO] [stdout] 421 | | .to_string(), [INFO] [stdout] 422 | | ] [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 407 ~ &[format!("Invalid glob pattern {}", pattern), [INFO] [stdout] 408 + vec![ [INFO] [stdout] 409 + "", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 418 + ] [INFO] [stdout] 419 + .join("\n") [INFO] [stdout] 420 + .to_string()] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:409:13 [INFO] [stdout] | [INFO] [stdout] 409 | / vec![ [INFO] [stdout] 410 | | "", [INFO] [stdout] 411 | | "Some example of valid patterns: ", [INFO] [stdout] 412 | | " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] ... | [INFO] [stdout] 418 | | " foo? - Matches foot or foo$ but not fools", [INFO] [stdout] 419 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 409 ~ ["", [INFO] [stdout] 410 + "Some example of valid patterns: ", [INFO] [stdout] 411 + " foo/**/* - Matches any file of any subfolder of foo", [INFO] [stdout] 412 + " * - Matches any string, of any length", [INFO] [stdout] 413 + " foo* - Matches any string beginning with foo", [INFO] [stdout] 414 + " *x* - Matches any string containing an x", [INFO] [stdout] 415 + " *.tar.gz - Matches any string ending with .tar.gz", [INFO] [stdout] 416 + " *.[ch] - Matches any string ending with .c or .h", [INFO] [stdout] 417 + " foo? - Matches foot or foo$ but not fools"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:746:13 [INFO] [stdout] | [INFO] [stdout] 746 | / vec![ [INFO] [stdout] 747 | | "name: my tests", [INFO] [stdout] 748 | | "run: cargo tests {{filepath}}", [INFO] [stdout] 749 | | "change: tests/**", [INFO] [stdout] 750 | | "run_on_init: true", [INFO] [stdout] 751 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 746 ~ ["name: my tests", [INFO] [stdout] 747 + "run: cargo tests {{filepath}}", [INFO] [stdout] 748 + "change: tests/**", [INFO] [stdout] 749 + "run_on_init: true"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:774:13 [INFO] [stdout] | [INFO] [stdout] 774 | / vec![ [INFO] [stdout] 775 | | "Failed to load configuration at line:", [INFO] [stdout] 776 | | "| run: 'cargo tests'", [INFO] [stdout] 777 | | "|> change: **/*", [INFO] [stdout] ... | [INFO] [stdout] 780 | | "Hint: Check for wrong types, any missing quotes for glob pattern or incorrect identation", [INFO] [stdout] 781 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 774 ~ ["Failed to load configuration at line:", [INFO] [stdout] 775 + "| run: 'cargo tests'", [INFO] [stdout] 776 + "|> change: **/*", [INFO] [stdout] 777 + "| ", [INFO] [stdout] 778 + "Reason: while scanning an anchor or alias, did not find expected alphabetic or numeric character at line 8 column 19", [INFO] [stdout] 779 + "Hint: Check for wrong types, any missing quotes for glob pattern or incorrect identation"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:792:13 [INFO] [stdout] | [INFO] [stdout] 792 | / vec![ [INFO] [stdout] 793 | | "Configuration file is invalid! There are no rules to watch", [INFO] [stdout] 794 | | "Hint: Make sure to declare at least one rule. Try to run `fzz init` to generate a new configuration from scratch", [INFO] [stdout] 795 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 792 ~ ["Configuration file is invalid! There are no rules to watch", [INFO] [stdout] 793 + "Hint: Make sure to declare at least one rule. Try to run `fzz init` to generate a new configuration from scratch"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/rules.rs:809:13 [INFO] [stdout] | [INFO] [stdout] 809 | / vec![ [INFO] [stdout] 810 | | "Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 811 | | "```yaml", [INFO] [stdout] 812 | | "on:", [INFO] [stdout] ... | [INFO] [stdout] 816 | | "Hint: Make sure to declare the rules as a list without any root property", [INFO] [stdout] 817 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 809 ~ ["Configuration file is invalid. Expected an Array/List of rules got: Hash", [INFO] [stdout] 810 + "```yaml", [INFO] [stdout] 811 + "on:", [INFO] [stdout] 812 + " - name: foo", [INFO] [stdout] 813 + " run: echo foo", [INFO] [stdout] 814 + "```", [INFO] [stdout] 815 + "Hint: Make sure to declare the rules as a list without any root property"] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `vec!` [INFO] [stdout] --> src/watcher.rs:24:28 [INFO] [stdout] | [INFO] [stdout] 24 | let warning = &vec![ [INFO] [stdout] | ____________________________^ [INFO] [stdout] 25 | | format!("unknown file/directory: '{}'", path), [INFO] [stdout] 26 | | format!("Different behaviour depending on the OS."), [INFO] [stdout] 27 | | format!("The watcher may not be triggered for this rule."), [INFO] [stdout] 28 | | ] [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec [INFO] [stdout] help: you can use an array directly [INFO] [stdout] | [INFO] [stdout] 24 ~ let warning = &[format!("unknown file/directory: '{}'", path), [INFO] [stdout] 25 + format!("Different behaviour depending on the OS."), [INFO] [stdout] 26 + format!("The watcher may not be triggered for this rule.")] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 16.53s [INFO] running `Command { std: "docker" "inspect" "cdafe9647a8561fcc1b0389ccfd956e8744377746c7fa83bb61312cd8dc57fdb", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "cdafe9647a8561fcc1b0389ccfd956e8744377746c7fa83bb61312cd8dc57fdb", kill_on_drop: false }` [INFO] [stdout] cdafe9647a8561fcc1b0389ccfd956e8744377746c7fa83bb61312cd8dc57fdb