[INFO] cloning repository https://github.com/claram97/messi-git [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/claram97/messi-git" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fclaram97%2Fmessi-git", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fclaram97%2Fmessi-git'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] a5cd83faf45e79887740dea80e86af440f655e1d [INFO] linting claram97/messi-git against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fclaram97%2Fmessi-git" "/workspace/builds/worker-5-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-5-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/claram97/messi-git [INFO] finished tweaking git repo https://github.com/claram97/messi-git [INFO] tweaked toml for git repo https://github.com/claram97/messi-git written to /workspace/builds/worker-5-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/claram97/messi-git on toolchain nightly [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/claram97/messi-git already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded system-deps v1.3.2 [INFO] [stderr] Downloaded thiserror-impl v1.0.50 [INFO] [stderr] Downloaded gdk-pixbuf-sys v0.10.0 [INFO] [stderr] Downloaded version-compare v0.0.10 [INFO] [stderr] Downloaded thiserror v1.0.50 [INFO] [stderr] Downloaded cairo-rs v0.9.1 [INFO] [stderr] Downloaded atk v0.9.0 [INFO] [stderr] Downloaded cairo-sys-rs v0.10.0 [INFO] [stderr] Downloaded gdk-sys v0.10.0 [INFO] [stderr] Downloaded gdk v0.13.2 [INFO] [stderr] Downloaded gio-sys v0.10.1 [INFO] [stderr] Downloaded gtk-sys v0.10.0 [INFO] [stderr] Downloaded glib v0.10.3 [INFO] [stderr] Downloaded strum_macros v0.18.0 [INFO] [stderr] Downloaded glib-macros v0.10.1 [INFO] [stderr] Downloaded glib-sys v0.10.1 [INFO] [stderr] Downloaded strum v0.18.0 [INFO] [stderr] Downloaded syn v2.0.38 [INFO] [stderr] Downloaded serde_derive v1.0.189 [INFO] [stderr] Downloaded gdk-pixbuf v0.9.0 [INFO] [stderr] Downloaded atk-sys v0.10.0 [INFO] [stderr] Downloaded gobject-sys v0.10.0 [INFO] [stderr] Downloaded gtk v0.9.2 [INFO] [stderr] Downloaded pango-sys v0.10.0 [INFO] [stderr] Downloaded pango v0.9.1 [INFO] [stderr] Downloaded serde v1.0.189 [INFO] [stderr] Downloaded gio v0.9.1 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-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] c4fb3dfdaf8cd3ea0676d3031ab33fbad29018559ae37e2d023d3cbab8d6969f [INFO] running `Command { std: "docker" "start" "-a" "c4fb3dfdaf8cd3ea0676d3031ab33fbad29018559ae37e2d023d3cbab8d6969f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "c4fb3dfdaf8cd3ea0676d3031ab33fbad29018559ae37e2d023d3cbab8d6969f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "c4fb3dfdaf8cd3ea0676d3031ab33fbad29018559ae37e2d023d3cbab8d6969f", kill_on_drop: false }` [INFO] [stdout] c4fb3dfdaf8cd3ea0676d3031ab33fbad29018559ae37e2d023d3cbab8d6969f [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5-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] 33d90adf4fc6cf8b87ee8c22da6436947d43215cf549bdc01100dd228e0e3951 [INFO] running `Command { std: "docker" "start" "-a" "33d90adf4fc6cf8b87ee8c22da6436947d43215cf549bdc01100dd228e0e3951", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.69 [INFO] [stderr] Compiling syn v1.0.109 [INFO] [stderr] Compiling serde v1.0.189 [INFO] [stderr] Compiling thiserror v1.0.50 [INFO] [stderr] Compiling unicode-segmentation v1.10.1 [INFO] [stderr] Compiling strum v0.18.0 [INFO] [stderr] Compiling version-compare v0.0.10 [INFO] [stderr] Compiling libc v0.2.149 [INFO] [stderr] Compiling futures-channel v0.3.28 [INFO] [stderr] Compiling futures-task v0.3.28 [INFO] [stderr] Compiling futures-util v0.3.28 [INFO] [stderr] Checking futures-sink v0.3.28 [INFO] [stderr] Checking memchr v2.6.4 [INFO] [stderr] Checking futures-io v0.3.28 [INFO] [stderr] Compiling anyhow v1.0.75 [INFO] [stderr] Compiling either v1.9.0 [INFO] [stderr] Compiling gio v0.9.1 [INFO] [stderr] Checking generic-array v0.14.7 [INFO] [stderr] Compiling itertools v0.9.0 [INFO] [stderr] Compiling gdk-pixbuf v0.9.0 [INFO] [stderr] Compiling pango v0.9.1 [INFO] [stderr] Compiling cairo-rs v0.9.1 [INFO] [stderr] Compiling num-traits v0.2.17 [INFO] [stderr] Compiling atk v0.9.0 [INFO] [stderr] Compiling gdk v0.13.2 [INFO] [stderr] Compiling gtk v0.9.2 [INFO] [stderr] Checking iana-time-zone v0.1.58 [INFO] [stderr] Checking cpufeatures v0.2.11 [INFO] [stderr] Compiling heck v0.3.3 [INFO] [stderr] Compiling quote v1.0.33 [INFO] [stderr] Compiling syn v2.0.38 [INFO] [stderr] Checking crypto-common v0.1.6 [INFO] [stderr] Checking block-buffer v0.10.4 [INFO] [stderr] Checking digest v0.10.7 [INFO] [stderr] Compiling proc-macro-error-attr v1.0.4 [INFO] [stderr] Checking getrandom v0.2.10 [INFO] [stderr] Checking sha1 v0.10.6 [INFO] [stderr] Checking rand_core v0.6.4 [INFO] [stderr] Checking rand_chacha v0.3.1 [INFO] [stderr] Checking rand v0.8.5 [INFO] [stderr] Checking chrono v0.4.31 [INFO] [stderr] Compiling thiserror-impl v1.0.50 [INFO] [stderr] Compiling futures-macro v0.3.28 [INFO] [stderr] Compiling serde_derive v1.0.189 [INFO] [stderr] Compiling proc-macro-error v1.0.4 [INFO] [stderr] Compiling toml v0.5.11 [INFO] [stderr] Compiling strum_macros v0.18.0 [INFO] [stderr] Compiling system-deps v1.3.2 [INFO] [stderr] Compiling proc-macro-crate v0.1.5 [INFO] [stderr] Compiling glib-macros v0.10.1 [INFO] [stderr] Compiling glib-sys v0.10.1 [INFO] [stderr] Compiling gobject-sys v0.10.0 [INFO] [stderr] Compiling gio-sys v0.10.1 [INFO] [stderr] Compiling pango-sys v0.10.0 [INFO] [stderr] Compiling gdk-pixbuf-sys v0.10.0 [INFO] [stderr] Compiling cairo-sys-rs v0.10.0 [INFO] [stderr] Compiling gdk-sys v0.10.0 [INFO] [stderr] Compiling atk-sys v0.10.0 [INFO] [stderr] Compiling gtk-sys v0.10.0 [INFO] [stderr] Checking futures-executor v0.3.28 [INFO] [stderr] Checking glib v0.10.3 [INFO] [stderr] Checking futures v0.3.28 [INFO] [stderr] Checking serde_json v1.0.108 [INFO] [stderr] Checking messi v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: empty line after doc comment [INFO] [stdout] --> src/clone.rs:55:1 [INFO] [stdout] | [INFO] [stdout] 55 | / /// [INFO] [stdout] 56 | | [INFO] [stdout] | |_^ [INFO] [stdout] 57 | //Ver de dónde sale la default branch [INFO] [stdout] 58 | fn get_default_branch_commit(local_git_dir: &str) -> io::Result { [INFO] [stdout] | ---------------------------- the comment documents this function [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments [INFO] [stdout] = note: `#[warn(clippy::empty_line_after_doc_comments)]` on by default [INFO] [stdout] = help: if the empty line is unintentional, remove it [INFO] [stdout] help: if the doc comment should not document function `get_default_branch_commit` then comment it out [INFO] [stdout] | [INFO] [stdout] 42 ~ // /// Retrieves the commit hash of the default branch from the local Git repository. [INFO] [stdout] 43 ~ // /// [INFO] [stdout] 44 ~ // /// This function takes the path to the local Git repository directory and looks for the "origin/master" [INFO] [stdout] 45 ~ // /// reference to obtain the commit hash of the "master" branch. [INFO] [stdout] 46 ~ // /// [INFO] [stdout] 47 ~ // /// # Arguments [INFO] [stdout] 48 ~ // /// [INFO] [stdout] 49 ~ // /// * `local_git_dir`: The path to the local Git repository directory. [INFO] [stdout] 50 ~ // /// [INFO] [stdout] 51 ~ // /// # Returns [INFO] [stdout] 52 ~ // /// [INFO] [stdout] 53 ~ // /// Returns a `Result` containing the commit hash of the "master" branch in case of success, [INFO] [stdout] 54 ~ // /// or an error in case an issue occurs during the operation. [INFO] [stdout] 55 ~ // /// [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty lines after doc comment [INFO] [stdout] --> src/gui/repository_window.rs:4431:1 [INFO] [stdout] | [INFO] [stdout] 4431 | / /// - `merge_text_view`: A reference to the `gtk::TextView` containing the content to be written into a file. [INFO] [stdout] ... | [INFO] [stdout] 4614 | | [INFO] [stdout] | |_^ [INFO] [stdout] ... [INFO] [stdout] 4627 | fn set_update_button_behavior( [INFO] [stdout] | ----------------------------- the comment documents this function [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments [INFO] [stdout] = help: if the empty lines are unintentional, remove them [INFO] [stdout] help: if the doc comment should not document function `set_update_button_behavior` then comment it out [INFO] [stdout] | [INFO] [stdout] 4421 ~ // /// Sets the behavior for an update button. [INFO] [stdout] 4422 ~ // /// [INFO] [stdout] 4423 ~ // /// This function connects a callback to the `clicked` signal of the provided `Button`. [INFO] [stdout] 4424 ~ // /// When the button is clicked, the callback reads the content of the associated `gtk::TextView` [INFO] [stdout] 4425 ~ // /// and writes it into the file specified by the selected item in the associated `gtk::ComboBoxText`. [INFO] [stdout] 4426 ~ // /// [INFO] [stdout] 4427 ~ // /// # Arguments [INFO] [stdout] 4428 ~ // /// [INFO] [stdout] 4429 ~ // /// - `button`: A reference to the `Button` for which the behavior is being set. [INFO] [stdout] 4430 ~ // /// - `combo_box`: A reference to the `gtk::ComboBoxText` containing file paths. [INFO] [stdout] 4431 ~ // /// - `merge_text_view`: A reference to the `gtk::TextView` containing the content to be written into a file. [INFO] [stdout] 4432 | // /// [INFO] [stdout] ... [INFO] [stdout] 4516 | [INFO] [stdout] 4517 ~ // /// Sets up the functionality of the merge button. Will merge the current branch with the one that was selected. [INFO] [stdout] 4518 | // fn set_done_button_behavior(button: &Button, merge_button: >k::Button, conflicts: Vec) { [INFO] [stdout] ... [INFO] [stdout] 4566 | [INFO] [stdout] 4567 ~ // /// Updates the box with the paths of the files that have conflicts. [INFO] [stdout] 4568 | // fn update_combo_box(combo_box: >k::ComboBoxText, conflicts: Vec) { [INFO] [stdout] ... [INFO] [stdout] 4573 | [INFO] [stdout] 4574 ~ // /// Sets the behavior for the `gtk::ComboBoxText` when its active item changes. [INFO] [stdout] 4575 ~ // /// [INFO] [stdout] 4576 ~ // /// This function connects a callback to the `changed` signal of the provided `gtk::ComboBoxText`. [INFO] [stdout] 4577 ~ // /// When the active item in the combo box changes, the callback reads the content of the file [INFO] [stdout] 4578 ~ // /// associated with the selected item and sets the text of the provided `gtk::TextView` accordingly. [INFO] [stdout] 4579 ~ // /// [INFO] [stdout] 4580 ~ // /// # Arguments [INFO] [stdout] 4581 ~ // /// [INFO] [stdout] 4582 ~ // /// - `combo_box`: A reference to the `gtk::ComboBoxText` for which the behavior is being set. [INFO] [stdout] 4583 ~ // /// - `text_view`: A reference to the `gtk::TextView` whose content will be updated based on the [INFO] [stdout] 4584 ~ // /// selected item in the combo box. [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty line after doc comment [INFO] [stdout] --> src/clone.rs:55:1 [INFO] [stdout] | [INFO] [stdout] 55 | / /// [INFO] [stdout] 56 | | [INFO] [stdout] | |_^ [INFO] [stdout] 57 | //Ver de dónde sale la default branch [INFO] [stdout] 58 | fn get_default_branch_commit(local_git_dir: &str) -> io::Result { [INFO] [stdout] | ---------------------------- the comment documents this function [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments [INFO] [stdout] = note: `#[warn(clippy::empty_line_after_doc_comments)]` on by default [INFO] [stdout] = help: if the empty line is unintentional, remove it [INFO] [stdout] help: if the doc comment should not document function `get_default_branch_commit` then comment it out [INFO] [stdout] | [INFO] [stdout] 42 ~ // /// Retrieves the commit hash of the default branch from the local Git repository. [INFO] [stdout] 43 ~ // /// [INFO] [stdout] 44 ~ // /// This function takes the path to the local Git repository directory and looks for the "origin/master" [INFO] [stdout] 45 ~ // /// reference to obtain the commit hash of the "master" branch. [INFO] [stdout] 46 ~ // /// [INFO] [stdout] 47 ~ // /// # Arguments [INFO] [stdout] 48 ~ // /// [INFO] [stdout] 49 ~ // /// * `local_git_dir`: The path to the local Git repository directory. [INFO] [stdout] 50 ~ // /// [INFO] [stdout] 51 ~ // /// # Returns [INFO] [stdout] 52 ~ // /// [INFO] [stdout] 53 ~ // /// Returns a `Result` containing the commit hash of the "master" branch in case of success, [INFO] [stdout] 54 ~ // /// or an error in case an issue occurs during the operation. [INFO] [stdout] 55 ~ // /// [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty lines after doc comment [INFO] [stdout] --> src/gui/repository_window.rs:4431:1 [INFO] [stdout] | [INFO] [stdout] 4431 | / /// - `merge_text_view`: A reference to the `gtk::TextView` containing the content to be written into a file. [INFO] [stdout] ... | [INFO] [stdout] 4614 | | [INFO] [stdout] | |_^ [INFO] [stdout] ... [INFO] [stdout] 4627 | fn set_update_button_behavior( [INFO] [stdout] | ----------------------------- the comment documents this function [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments [INFO] [stdout] = help: if the empty lines are unintentional, remove them [INFO] [stdout] help: if the doc comment should not document function `set_update_button_behavior` then comment it out [INFO] [stdout] | [INFO] [stdout] 4421 ~ // /// Sets the behavior for an update button. [INFO] [stdout] 4422 ~ // /// [INFO] [stdout] 4423 ~ // /// This function connects a callback to the `clicked` signal of the provided `Button`. [INFO] [stdout] 4424 ~ // /// When the button is clicked, the callback reads the content of the associated `gtk::TextView` [INFO] [stdout] 4425 ~ // /// and writes it into the file specified by the selected item in the associated `gtk::ComboBoxText`. [INFO] [stdout] 4426 ~ // /// [INFO] [stdout] 4427 ~ // /// # Arguments [INFO] [stdout] 4428 ~ // /// [INFO] [stdout] 4429 ~ // /// - `button`: A reference to the `Button` for which the behavior is being set. [INFO] [stdout] 4430 ~ // /// - `combo_box`: A reference to the `gtk::ComboBoxText` containing file paths. [INFO] [stdout] 4431 ~ // /// - `merge_text_view`: A reference to the `gtk::TextView` containing the content to be written into a file. [INFO] [stdout] 4432 | // /// [INFO] [stdout] ... [INFO] [stdout] 4516 | [INFO] [stdout] 4517 ~ // /// Sets up the functionality of the merge button. Will merge the current branch with the one that was selected. [INFO] [stdout] 4518 | // fn set_done_button_behavior(button: &Button, merge_button: >k::Button, conflicts: Vec) { [INFO] [stdout] ... [INFO] [stdout] 4566 | [INFO] [stdout] 4567 ~ // /// Updates the box with the paths of the files that have conflicts. [INFO] [stdout] 4568 | // fn update_combo_box(combo_box: >k::ComboBoxText, conflicts: Vec) { [INFO] [stdout] ... [INFO] [stdout] 4573 | [INFO] [stdout] 4574 ~ // /// Sets the behavior for the `gtk::ComboBoxText` when its active item changes. [INFO] [stdout] 4575 ~ // /// [INFO] [stdout] 4576 ~ // /// This function connects a callback to the `changed` signal of the provided `gtk::ComboBoxText`. [INFO] [stdout] 4577 ~ // /// When the active item in the combo box changes, the callback reads the content of the file [INFO] [stdout] 4578 ~ // /// associated with the selected item and sets the text of the provided `gtk::TextView` accordingly. [INFO] [stdout] 4579 ~ // /// [INFO] [stdout] 4580 ~ // /// # Arguments [INFO] [stdout] 4581 ~ // /// [INFO] [stdout] 4582 ~ // /// - `combo_box`: A reference to the `gtk::ComboBoxText` for which the behavior is being set. [INFO] [stdout] 4583 ~ // /// - `text_view`: A reference to the `gtk::TextView` whose content will be updated based on the [INFO] [stdout] 4584 ~ // /// selected item in the combo box. [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty line after doc comment [INFO] [stdout] --> src/init.rs:148:1 [INFO] [stdout] | [INFO] [stdout] 148 | / /// [INFO] [stdout] 149 | | [INFO] [stdout] | |_^ [INFO] [stdout] 150 | #[cfg(test)] [INFO] [stdout] 151 | mod test { [INFO] [stdout] | -------- the comment documents this module [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_line_after_doc_comments [INFO] [stdout] = help: if the empty line is unintentional, remove it [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/branch.rs:20:22 [INFO] [stdout] | [INFO] [stdout] 20 | let path = match head_content.split(' ').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] = note: `#[warn(clippy::double_ended_iterator_last)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 20 - let path = match head_content.split(' ').last() { [INFO] [stdout] 20 + let path = match head_content.split(' ').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/branch.rs:170:5 [INFO] [stdout] | [INFO] [stdout] 170 | /// will be written. This can be a file, standard output (`stdout`), etc. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] = note: `#[warn(clippy::doc_overindented_list_items)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/branch.rs:219:5 [INFO] [stdout] | [INFO] [stdout] 219 | /// will be written. This can be a file, standard output (`stdout`), etc. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/branch.rs:316:5 [INFO] [stdout] | [INFO] [stdout] 316 | /// will be written. This can be a file, standard output (`stdout`), etc. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the variable `line_number` is used as a loop counter [INFO] [stdout] --> src/check_ignore.rs:79:9 [INFO] [stdout] | [INFO] [stdout] 79 | for path in line.iter().skip(3) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `for (line_number, path) in (1..).zip(line.iter().skip(3))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_counter_loop [INFO] [stdout] = note: `#[warn(clippy::explicit_counter_loop)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:70:24 [INFO] [stdout] | [INFO] [stdout] 70 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 71 | | io::ErrorKind::Other, [INFO] [stdout] 72 | | "Error when reading path", [INFO] [stdout] 73 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] = note: `#[warn(clippy::io_other_error)]` on by default [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 70 ~ return Err(io::Error::other( [INFO] [stdout] 71 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:80:24 [INFO] [stdout] | [INFO] [stdout] 80 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 81 | | io::ErrorKind::Other, [INFO] [stdout] 82 | | "Error getting current branch", [INFO] [stdout] 83 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 80 ~ return Err(io::Error::other( [INFO] [stdout] 81 ~ "Error getting current branch", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:125:24 [INFO] [stdout] | [INFO] [stdout] 125 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 126 | | io::ErrorKind::Other, [INFO] [stdout] 127 | | "Error when reading path", [INFO] [stdout] 128 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 125 ~ return Err(io::Error::other( [INFO] [stdout] 126 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:132:20 [INFO] [stdout] | [INFO] [stdout] 132 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 133 | | io::ErrorKind::Other, [INFO] [stdout] 134 | | format!("Branch {} does not exist", branch_name), [INFO] [stdout] 135 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 132 ~ return Err(io::Error::other( [INFO] [stdout] 133 ~ format!("Branch {} does not exist", branch_name), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:175:24 [INFO] [stdout] | [INFO] [stdout] 175 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 176 | | io::ErrorKind::Other, [INFO] [stdout] 177 | | "Error when reading path", [INFO] [stdout] 178 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 175 ~ return Err(io::Error::other( [INFO] [stdout] 176 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:236:24 [INFO] [stdout] | [INFO] [stdout] 236 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 237 | | io::ErrorKind::Other, [INFO] [stdout] 238 | | "Error when reading path", [INFO] [stdout] 239 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 236 ~ return Err(io::Error::other( [INFO] [stdout] 237 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:274:24 [INFO] [stdout] | [INFO] [stdout] 274 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 275 | | io::ErrorKind::Other, [INFO] [stdout] 276 | | "Error when reading path", [INFO] [stdout] 277 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 274 ~ return Err(io::Error::other( [INFO] [stdout] 275 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/checkout.rs:368:5 [INFO] [stdout] | [INFO] [stdout] 368 | /// ID (e.g., "a1b2c3d4e5"). [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/clone.rs:86:24 [INFO] [stdout] | [INFO] [stdout] 86 | .map(|x| match x.0.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 86 - .map(|x| match x.0.split('/').last() { [INFO] [stdout] 86 + .map(|x| match x.0.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/commit.rs:69:20 [INFO] [stdout] | [INFO] [stdout] 69 | return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 69 - return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] 69 + return Err(io::Error::other("No changes were made")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/commit.rs:131:29 [INFO] [stdout] | [INFO] [stdout] 131 | let branch_name = match head_content.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 131 - let branch_name = match head_content.split('/').last() { [INFO] [stdout] 131 + let branch_name = match head_content.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/commit.rs:208:20 [INFO] [stdout] | [INFO] [stdout] 208 | return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 208 - return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] 208 + return Err(io::Error::other("No changes were made")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:175:9 [INFO] [stdout] | [INFO] [stdout] 175 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:223:9 [INFO] [stdout] | [INFO] [stdout] 223 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:311:9 [INFO] [stdout] | [INFO] [stdout] 311 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:361:9 [INFO] [stdout] | [INFO] [stdout] 361 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:500:9 [INFO] [stdout] | [INFO] [stdout] 500 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:551:9 [INFO] [stdout] | [INFO] [stdout] 551 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/config.rs:680:28 [INFO] [stdout] | [INFO] [stdout] 680 | return Err(io::Error::new( [INFO] [stdout] | ____________________________^ [INFO] [stdout] 681 | | io::ErrorKind::Other, [INFO] [stdout] 682 | | "No se pudo obtener el directorio padre", [INFO] [stdout] 683 | | )); [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 680 ~ return Err(io::Error::other( [INFO] [stdout] 681 ~ "No se pudo obtener el directorio padre", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/diff.rs:78:49 [INFO] [stdout] | [INFO] [stdout] 78 | fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 78 - fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] 78 + fn compute_longest_common_subsequence_matrix(a: &[String], b: &Vec) -> Vec> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/diff.rs:78:66 [INFO] [stdout] | [INFO] [stdout] 78 | fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 78 - fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] 78 + fn compute_longest_common_subsequence_matrix(a: &Vec, b: &[String]) -> Vec> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/fetch.rs:167:24 [INFO] [stdout] | [INFO] [stdout] 167 | .map(|x| match x.0.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 167 - .map(|x| match x.0.split('/').last() { [INFO] [stdout] 167 + .map(|x| match x.0.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/gui/clone_window.rs:117:36 [INFO] [stdout] | [INFO] [stdout] 117 | let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 117 - let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] 117 + let remote_repo_name = url_text.split('/').next_back().unwrap_or(""); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/clone_window.rs:180:54 [INFO] [stdout] | [INFO] [stdout] 180 | apply_button_style(&browse_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 180 - apply_button_style(&browse_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 180 + apply_button_style(&browse_button).map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/clone_window.rs:181:53 [INFO] [stdout] | [INFO] [stdout] 181 | apply_button_style(&clone_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 181 - apply_button_style(&clone_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 181 + apply_button_style(&clone_button).map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:37:22 [INFO] [stdout] | [INFO] [stdout] 37 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 37 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] 37 + .map_err(|_| io::Error::other("Failed to apply window style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:46:22 [INFO] [stdout] | [INFO] [stdout] 46 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button1 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 46 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button1 style"))?; [INFO] [stdout] 46 + .map_err(|_| io::Error::other("Failed to apply button1 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:48:22 [INFO] [stdout] | [INFO] [stdout] 48 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button2 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 48 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button2 style"))?; [INFO] [stdout] 48 + .map_err(|_| io::Error::other("Failed to apply button2 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:50:22 [INFO] [stdout] | [INFO] [stdout] 50 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button3 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 50 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button3 style"))?; [INFO] [stdout] 50 + .map_err(|_| io::Error::other("Failed to apply button3 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:52:22 [INFO] [stdout] | [INFO] [stdout] 52 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button4 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 52 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button4 style"))?; [INFO] [stdout] 52 + .map_err(|_| io::Error::other("Failed to apply button4 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/gui/init_window.rs:243:5 [INFO] [stdout] | [INFO] [stdout] 243 | /// when the user clicks the "OK" button, passing the entered text to the callback. [INFO] [stdout] | ^^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:31:13 [INFO] [stdout] | [INFO] [stdout] 31 | io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 31 - io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n") [INFO] [stdout] 31 + io::Error::other("Error applying window stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:38:13 [INFO] [stdout] | [INFO] [stdout] 38 | io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 38 - io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] 38 + io::Error::other("Error applying button stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:41:13 [INFO] [stdout] | [INFO] [stdout] 41 | io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 41 - io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] 41 + io::Error::other("Error applying button stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:44:13 [INFO] [stdout] | [INFO] [stdout] 44 | io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 44 - io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] 44 + io::Error::other("Error applying button stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:53:13 [INFO] [stdout] | [INFO] [stdout] 53 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 54 | | io::ErrorKind::Other, [INFO] [stdout] 55 | | "Failed to run main window.", [INFO] [stdout] 56 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 53 ~ Err(io::Error::other( [INFO] [stdout] 54 ~ "Failed to run main window.", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:103:24 [INFO] [stdout] | [INFO] [stdout] 103 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 104 | | io::ErrorKind::Other, [INFO] [stdout] 105 | | "Failed to convert path to string.\n", [INFO] [stdout] 106 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 103 ~ return Err(io::Error::other( [INFO] [stdout] 104 ~ "Failed to convert path to string.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:112:36 [INFO] [stdout] | [INFO] [stdout] 112 | Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 112 - Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)), [INFO] [stdout] 112 + Err(err) => return Err(io::Error::other(err)), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:117:13 [INFO] [stdout] | [INFO] [stdout] 117 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 118 | | io::ErrorKind::Other, [INFO] [stdout] 119 | | "Failed to show repository window.\n", [INFO] [stdout] 120 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 117 ~ Err(io::Error::other( [INFO] [stdout] 118 ~ "Failed to show repository window.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:324:24 [INFO] [stdout] | [INFO] [stdout] 324 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 325 | | io::ErrorKind::Other, [INFO] [stdout] 326 | | "Can't find git dir.\n", [INFO] [stdout] 327 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 324 ~ return Err(io::Error::other( [INFO] [stdout] 325 ~ "Can't find git dir.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:334:24 [INFO] [stdout] | [INFO] [stdout] 334 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 335 | | io::ErrorKind::Other, [INFO] [stdout] 336 | | "Can't find working dir.\n", [INFO] [stdout] 337 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 334 ~ return Err(io::Error::other( [INFO] [stdout] 335 ~ "Can't find working dir.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:363:24 [INFO] [stdout] | [INFO] [stdout] 363 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 364 | | io::ErrorKind::Other, [INFO] [stdout] 365 | | "Can't find git dir.\n", [INFO] [stdout] 366 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 363 ~ return Err(io::Error::other( [INFO] [stdout] 364 ~ "Can't find git dir.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:388:47 [INFO] [stdout] | [INFO] [stdout] 388 | apply_button_style(&button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 388 - apply_button_style(&button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 388 + apply_button_style(&button).map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:392:24 [INFO] [stdout] | [INFO] [stdout] 392 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get the button object"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 392 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get the button object"))?; [INFO] [stdout] 392 + .ok_or_else(|| io::Error::other("Failed to get the button object"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/gui/repository_window.rs:690:5 [INFO] [stdout] | [INFO] [stdout] 690 | /// and manipulate the GUI components. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1477:20 [INFO] [stdout] | [INFO] [stdout] 1477 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1477 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1477 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1510:20 [INFO] [stdout] | [INFO] [stdout] 1510 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1510 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1510 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1544:20 [INFO] [stdout] | [INFO] [stdout] 1544 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1544 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1544 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1578:20 [INFO] [stdout] | [INFO] [stdout] 1578 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1578 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1578 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1612:20 [INFO] [stdout] | [INFO] [stdout] 1612 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1612 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1612 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1855:24 [INFO] [stdout] | [INFO] [stdout] 1855 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 1856 | | io::ErrorKind::Other, [INFO] [stdout] 1857 | | "Error turning result into string", [INFO] [stdout] 1858 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1855 ~ return Err(io::Error::other( [INFO] [stdout] 1856 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1866:24 [INFO] [stdout] | [INFO] [stdout] 1866 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 1867 | | io::ErrorKind::Other, [INFO] [stdout] 1868 | | "Error turning result into string", [INFO] [stdout] 1869 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1866 ~ return Err(io::Error::other( [INFO] [stdout] 1867 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1877:20 [INFO] [stdout] | [INFO] [stdout] 1877 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 1878 | | io::ErrorKind::Other, [INFO] [stdout] 1879 | | "Error obtaining TextView", [INFO] [stdout] 1880 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1877 ~ return Err(io::Error::other( [INFO] [stdout] 1878 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2314:24 [INFO] [stdout] | [INFO] [stdout] 2314 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2315 | | io::ErrorKind::Other, [INFO] [stdout] 2316 | | "Error obtaining text view for list trees", [INFO] [stdout] 2317 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2314 ~ return Err(io::Error::other( [INFO] [stdout] 2315 ~ "Error obtaining text view for list trees", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2326:24 [INFO] [stdout] | [INFO] [stdout] 2326 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2327 | | io::ErrorKind::Other, [INFO] [stdout] 2328 | | "Error turning result into string", [INFO] [stdout] 2329 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2326 ~ return Err(io::Error::other( [INFO] [stdout] 2327 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2337:20 [INFO] [stdout] | [INFO] [stdout] 2337 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 2338 | | io::ErrorKind::Other, [INFO] [stdout] 2339 | | "Error obtaining TextView", [INFO] [stdout] 2340 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2337 ~ return Err(io::Error::other( [INFO] [stdout] 2338 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2465:24 [INFO] [stdout] | [INFO] [stdout] 2465 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2466 | | io::ErrorKind::Other, [INFO] [stdout] 2467 | | "Couldn't get remote text view.", [INFO] [stdout] 2468 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2465 ~ return Err(io::Error::other( [INFO] [stdout] 2466 ~ "Couldn't get remote text view.", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2476:24 [INFO] [stdout] | [INFO] [stdout] 2476 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2477 | | io::ErrorKind::Other, [INFO] [stdout] 2478 | | "Error turning result into string", [INFO] [stdout] 2479 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2476 ~ return Err(io::Error::other( [INFO] [stdout] 2477 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2487:20 [INFO] [stdout] | [INFO] [stdout] 2487 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 2488 | | io::ErrorKind::Other, [INFO] [stdout] 2489 | | "Error obtaining TextView", [INFO] [stdout] 2490 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2487 ~ return Err(io::Error::other( [INFO] [stdout] 2488 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2519:24 [INFO] [stdout] | [INFO] [stdout] 2519 | return Err(io::Error::new(io::ErrorKind::Other, "&error")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2519 - return Err(io::Error::new(io::ErrorKind::Other, "&error")); [INFO] [stdout] 2519 + return Err(io::Error::other("&error")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2551:24 [INFO] [stdout] | [INFO] [stdout] 2551 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2552 | | io::ErrorKind::Other, [INFO] [stdout] 2553 | | "Error obtaining text view", [INFO] [stdout] 2554 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2551 ~ return Err(io::Error::other( [INFO] [stdout] 2552 ~ "Error obtaining text view", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2562:24 [INFO] [stdout] | [INFO] [stdout] 2562 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2563 | | io::ErrorKind::Other, [INFO] [stdout] 2564 | | "Error turning result into string", [INFO] [stdout] 2565 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2562 ~ return Err(io::Error::other( [INFO] [stdout] 2563 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2573:20 [INFO] [stdout] | [INFO] [stdout] 2573 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 2574 | | io::ErrorKind::Other, [INFO] [stdout] 2575 | | "Error obtaining TextView", [INFO] [stdout] 2576 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2573 ~ return Err(io::Error::other( [INFO] [stdout] 2574 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3169:24 [INFO] [stdout] | [INFO] [stdout] 3169 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 3170 | | io::ErrorKind::Other, [INFO] [stdout] 3171 | | "Text view buffer can't be accessed.\n", [INFO] [stdout] 3172 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3169 ~ return Err(io::Error::other( [INFO] [stdout] 3170 ~ "Text view buffer can't be accessed.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3614:24 [INFO] [stdout] | [INFO] [stdout] 3614 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3614 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 3614 + .map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3616:24 [INFO] [stdout] | [INFO] [stdout] 3616 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3616 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 3616 + .map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3618:24 [INFO] [stdout] | [INFO] [stdout] 3618 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3618 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 3618 + .map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/gui/repository_window.rs:4301:33 [INFO] [stdout] | [INFO] [stdout] 4301 | let branch_name = match branch.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 4301 - let branch_name = match branch.split('/').last() { [INFO] [stdout] 4301 + let branch_name = match branch.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4517:5 [INFO] [stdout] | [INFO] [stdout] 4517 | /// Sets up the functionality of the merge button. Will merge the current branch with the one that was selected. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] = note: `#[warn(clippy::doc_lazy_continuation)]` on by default [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4517 | /// Sets up the functionality of the merge button. Will merge the current branch with the one that was selected. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4567:5 [INFO] [stdout] | [INFO] [stdout] 4567 | /// Updates the box with the paths of the files that have conflicts. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4567 | /// Updates the box with the paths of the files that have conflicts. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4574:5 [INFO] [stdout] | [INFO] [stdout] 4574 | /// Sets the behavior for the `gtk::ComboBoxText` when its active item changes. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4574 | /// Sets the behavior for the `gtk::ComboBoxText` when its active item changes. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4615:5 [INFO] [stdout] | [INFO] [stdout] 4615 | /// Sets the behavior for an update button. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4615 | /// Sets the behavior for an update button. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4694:24 [INFO] [stdout] | [INFO] [stdout] 4694 | return Err(io::Error::new(io::ErrorKind::Other, "Entry not found.\n")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4694 - return Err(io::Error::new(io::ErrorKind::Other, "Entry not found.\n")); [INFO] [stdout] 4694 + return Err(io::Error::other("Entry not found.\n")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4700:24 [INFO] [stdout] | [INFO] [stdout] 4700 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4701 | | io::ErrorKind::Other, [INFO] [stdout] 4702 | | "Text view not found.\n", [INFO] [stdout] 4703 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4700 ~ return Err(io::Error::other( [INFO] [stdout] 4701 ~ "Text view not found.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4763:24 [INFO] [stdout] | [INFO] [stdout] 4763 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4764 | | io::ErrorKind::Other, [INFO] [stdout] 4765 | | "Couldn't get rebase branch entry.\n", [INFO] [stdout] 4766 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4763 ~ return Err(io::Error::other( [INFO] [stdout] 4764 ~ "Couldn't get rebase branch entry.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4836:17 [INFO] [stdout] | [INFO] [stdout] 4836 | Err(io::Error::new( [INFO] [stdout] | _________________^ [INFO] [stdout] 4837 | | io::ErrorKind::Other, [INFO] [stdout] 4838 | | format!("Error getting not staged text: {}", err), [INFO] [stdout] 4839 | | ))?; [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4836 ~ Err(io::Error::other( [INFO] [stdout] 4837 ~ format!("Error getting not staged text: {}", err), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4848:17 [INFO] [stdout] | [INFO] [stdout] 4848 | Err(io::Error::new( [INFO] [stdout] | _________________^ [INFO] [stdout] 4849 | | io::ErrorKind::Other, [INFO] [stdout] 4850 | | format!("Error getting staged text: {}", err), [INFO] [stdout] 4851 | | ))?; [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4848 ~ Err(io::Error::other( [INFO] [stdout] 4849 ~ format!("Error getting staged text: {}", err), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4860:25 [INFO] [stdout] | [INFO] [stdout] 4860 | Err(err) => Err(io::Error::new( [INFO] [stdout] | _________________________^ [INFO] [stdout] 4861 | | io::ErrorKind::Other, [INFO] [stdout] 4862 | | format!("Error setting staging area texts: {}", err), [INFO] [stdout] 4863 | | )), [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4860 ~ Err(err) => Err(io::Error::other( [INFO] [stdout] 4861 ~ format!("Error setting staging area texts: {}", err), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4878:45 [INFO] [stdout] | [INFO] [stdout] 4878 | std::env::current_dir().map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4878 - std::env::current_dir().map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4878 + std::env::current_dir().map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4879:54 [INFO] [stdout] | [INFO] [stdout] 4879 | let current_dir_str = current_dir.to_str().ok_or(io::Error::new( [INFO] [stdout] | ______________________________________________________^ [INFO] [stdout] 4880 | | io::ErrorKind::Other, [INFO] [stdout] 4881 | | "Failed to convert current directory to string", [INFO] [stdout] 4882 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4879 ~ let current_dir_str = current_dir.to_str().ok_or(io::Error::other( [INFO] [stdout] 4880 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4884:79 [INFO] [stdout] | [INFO] [stdout] 4884 | let git_dir = find_git_directory(&mut current_dir.clone(), GIT_DIR).ok_or(io::Error::new( [INFO] [stdout] | _______________________________________________________________________________^ [INFO] [stdout] 4885 | | io::ErrorKind::Other, [INFO] [stdout] 4886 | | "Failed to find git directory", [INFO] [stdout] 4887 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4884 ~ let git_dir = find_git_directory(&mut current_dir.clone(), GIT_DIR).ok_or(io::Error::other( [INFO] [stdout] 4885 ~ "Failed to find git directory", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4892:24 [INFO] [stdout] | [INFO] [stdout] 4892 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4893 | | io::ErrorKind::Other, [INFO] [stdout] 4894 | | "Failed to convert current directory to string", [INFO] [stdout] 4895 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4892 ~ return Err(io::Error::other( [INFO] [stdout] 4893 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4904:22 [INFO] [stdout] | [INFO] [stdout] 4904 | .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4904 - .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4904 + .map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4915:22 [INFO] [stdout] | [INFO] [stdout] 4915 | .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4915 - .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4915 + .map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4936:24 [INFO] [stdout] | [INFO] [stdout] 4936 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4937 | | io::ErrorKind::Other, [INFO] [stdout] 4938 | | "Failed to convert current directory to string", [INFO] [stdout] 4939 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4936 ~ return Err(io::Error::other( [INFO] [stdout] 4937 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `ok` [INFO] [stdout] --> src/gui/repository_window.rs:4947:9 [INFO] [stdout] | [INFO] [stdout] 4947 | / match tree_handler::load_tree_from_commit(&last_commit, &git_dir) { [INFO] [stdout] 4948 | | Ok(tree) => Some(tree), [INFO] [stdout] 4949 | | Err(_) => None, [INFO] [stdout] 4950 | | }; [INFO] [stdout] | |_________^ help: replace with: `tree_handler::load_tree_from_commit(&last_commit, &git_dir).ok()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_ok_err [INFO] [stdout] = note: `#[warn(clippy::manual_ok_err)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4955:22 [INFO] [stdout] | [INFO] [stdout] 4955 | .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4955 - .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4955 + .map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4976:72 [INFO] [stdout] | [INFO] [stdout] 4976 | let text_view: gtk::TextView = builder.get_object(view_name).ok_or(io::Error::new( [INFO] [stdout] | ________________________________________________________________________^ [INFO] [stdout] 4977 | | io::ErrorKind::Other, [INFO] [stdout] 4978 | | format!("Failed to get {} object", view_name), [INFO] [stdout] 4979 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4976 ~ let text_view: gtk::TextView = builder.get_object(view_name).ok_or(io::Error::other( [INFO] [stdout] 4977 ~ format!("Failed to get {} object", view_name), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4981:47 [INFO] [stdout] | [INFO] [stdout] 4981 | let buffer = text_view.get_buffer().ok_or(io::Error::new( [INFO] [stdout] | _______________________________________________^ [INFO] [stdout] 4982 | | io::ErrorKind::Other, [INFO] [stdout] 4983 | | format!("Failed to get buffer for {}", view_name), [INFO] [stdout] 4984 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4981 ~ let buffer = text_view.get_buffer().ok_or(io::Error::other( [INFO] [stdout] 4982 ~ format!("Failed to get buffer for {}", view_name), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5033:24 [INFO] [stdout] | [INFO] [stdout] 5033 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get label"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5033 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get label"))?; [INFO] [stdout] 5033 + .ok_or_else(|| io::Error::other("Failed to get label"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5039:24 [INFO] [stdout] | [INFO] [stdout] 5039 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 5040 | | io::ErrorKind::Other, [INFO] [stdout] 5041 | | "Git directory not found\n", [INFO] [stdout] 5042 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5039 ~ return Err(io::Error::other( [INFO] [stdout] 5040 ~ "Git directory not found\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5054:24 [INFO] [stdout] | [INFO] [stdout] 5054 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history view"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5054 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history view"))?; [INFO] [stdout] 5054 + .ok_or_else(|| io::Error::other("Failed to get history view"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5057:24 [INFO] [stdout] | [INFO] [stdout] 5057 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history buffer"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5057 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history buffer"))?; [INFO] [stdout] 5057 + .ok_or_else(|| io::Error::other("Failed to get history buffer"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5066:9 [INFO] [stdout] | [INFO] [stdout] 5066 | / io::Error::new( [INFO] [stdout] 5067 | | io::ErrorKind::Other, [INFO] [stdout] 5068 | | "Failed to convert current directory to string", [INFO] [stdout] 5069 | | ) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5066 ~ io::Error::other( [INFO] [stdout] 5067 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5091:21 [INFO] [stdout] | [INFO] [stdout] 5091 | None => Err(io::Error::new( [INFO] [stdout] | _____________________^ [INFO] [stdout] 5092 | | io::ErrorKind::Other, [INFO] [stdout] 5093 | | "Git directory not found", [INFO] [stdout] 5094 | | )), [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5091 ~ None => Err(io::Error::other( [INFO] [stdout] 5092 ~ "Git directory not found", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5147:17 [INFO] [stdout] | [INFO] [stdout] 5147 | / io::Error::new( [INFO] [stdout] 5148 | | io::ErrorKind::Other, [INFO] [stdout] 5149 | | "Failed to get commit message text view", [INFO] [stdout] 5150 | | ) [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5147 ~ io::Error::other( [INFO] [stdout] 5148 ~ "Failed to get commit message text view", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:322:25 [INFO] [stdout] | [INFO] [stdout] 322 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 322 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] 322 + .map_err(|_err| io::Error::other("Error applying window stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:335:25 [INFO] [stdout] | [INFO] [stdout] 335 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 335 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] 335 + .map_err(|_err| io::Error::other("Error applying button stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:374:25 [INFO] [stdout] | [INFO] [stdout] 374 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 374 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] 374 + .map_err(|_err| io::Error::other("Error applying window stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:391:25 [INFO] [stdout] | [INFO] [stdout] 391 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 391 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] 391 + .map_err(|_err| io::Error::other("Error applying button stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:433:25 [INFO] [stdout] | [INFO] [stdout] 433 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window style.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 433 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window style.\n"))?; [INFO] [stdout] 433 + .map_err(|_err| io::Error::other("Error applying window style.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:457:25 [INFO] [stdout] | [INFO] [stdout] 457 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button style.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 457 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button style.\n"))?; [INFO] [stdout] 457 + .map_err(|_err| io::Error::other("Error applying button style.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:515:22 [INFO] [stdout] | [INFO] [stdout] 515 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 515 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] 515 + .map_err(|_| io::Error::other("Failed to apply window style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/visual_branches.rs:47:24 [INFO] [stdout] | [INFO] [stdout] 47 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get drawing area"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 47 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get drawing area"))?; [INFO] [stdout] 47 + .ok_or_else(|| io::Error::other("Failed to get drawing area"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/gui/visual_branches.rs:168:15 [INFO] [stdout] | [INFO] [stdout] 168 | branches: &Vec, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 168 - branches: &Vec, [INFO] [stdout] 168 + branches: &[String], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/log.rs:47:5 [INFO] [stdout] | [INFO] [stdout] 47 | /// the repo will be read. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 47 | /// the repo will be read. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/log.rs:216:9 [INFO] [stdout] | [INFO] [stdout] 216 | /// or disabled (`false`). [INFO] [stdout] | ^^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/ls_tree.rs:58:34 [INFO] [stdout] | [INFO] [stdout] 58 | Err(_) => return Err(io::Error::new(io::ErrorKind::Other, "Not a tree")), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 58 - Err(_) => return Err(io::Error::new(io::ErrorKind::Other, "Not a tree")), [INFO] [stdout] 58 + Err(_) => return Err(io::Error::other("Not a tree")), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/ls_tree.rs:67:25 [INFO] [stdout] | [INFO] [stdout] 67 | _ => return Err(io::Error::new(io::ErrorKind::Other, "Invalid option")), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 67 - _ => return Err(io::Error::new(io::ErrorKind::Other, "Invalid option")), [INFO] [stdout] 67 + _ => return Err(io::Error::other("Invalid option")), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/merge.rs:54:20 [INFO] [stdout] | [INFO] [stdout] 54 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 55 | | io::ErrorKind::Other, [INFO] [stdout] 56 | | "No common ancestor found.", [INFO] [stdout] 57 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 54 ~ return Err(io::Error::other( [INFO] [stdout] 55 ~ "No common ancestor found.", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/packfile/delta_utils.rs:301:17 [INFO] [stdout] | [INFO] [stdout] 301 | / if *o1 + *s1 == *o2 { [INFO] [stdout] 302 | | optimized[i] = Command::Copy { [INFO] [stdout] 303 | | offset: *o1, [INFO] [stdout] 304 | | size: *s1 + *s2, [INFO] [stdout] ... | [INFO] [stdout] 308 | | i += 1; [INFO] [stdout] 309 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 300 ~ ) [INFO] [stdout] 301 ~ if *o1 + *s1 == *o2 => { [INFO] [stdout] 302 | optimized[i] = Command::Copy { [INFO] [stdout] ... [INFO] [stdout] 305 | }; [INFO] [stdout] 306 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/parse_commands.rs:546:24 [INFO] [stdout] | [INFO] [stdout] 546 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Error al obtener el working dir"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 546 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Error al obtener el working dir"))?; [INFO] [stdout] 546 + .ok_or_else(|| io::Error::other("Error al obtener el working dir"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/parse_commands.rs:589:13 [INFO] [stdout] | [INFO] [stdout] 589 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 590 | | io::ErrorKind::Other, [INFO] [stdout] 591 | | "Error al abrir el archivo de commit", [INFO] [stdout] 592 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 589 ~ Err(io::Error::other( [INFO] [stdout] 590 ~ "Error al abrir el archivo de commit", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/parse_commands.rs:908:21 [INFO] [stdout] | [INFO] [stdout] 908 | None => Err(io::Error::new( [INFO] [stdout] | _____________________^ [INFO] [stdout] 909 | | io::ErrorKind::Other, [INFO] [stdout] 910 | | "Error al obtener el working dir", [INFO] [stdout] 911 | | )), [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 908 ~ None => Err(io::Error::other( [INFO] [stdout] 909 ~ "Error al obtener el working dir", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/parse_commands.rs:952:5 [INFO] [stdout] | [INFO] [stdout] 952 | /// ('-b', '-B', '--detach', '-f') and the fourth element is the branch or commit to checkout. [INFO] [stdout] | ^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/parse_commands.rs:1051:28 [INFO] [stdout] | [INFO] [stdout] 1051 | let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 1051 - let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] 1051 + let remote_repo_name = url_text.split('/').next_back().unwrap_or(""); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/parse_commands.rs:1096:28 [INFO] [stdout] | [INFO] [stdout] 1096 | let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 1096 - let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] 1096 + let remote_repo_name = url_text.split('/').next_back().unwrap_or(""); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/parse_commands.rs:1113:5 [INFO] [stdout] | [INFO] [stdout] 1113 | /// expected to be the name of the branch to be merged. [INFO] [stdout] | ^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/parse_commands.rs:1157:5 [INFO] [stdout] | [INFO] [stdout] 1157 | /// representing the 'git remote' subcommand and its options. [INFO] [stdout] | ^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/parse_commands.rs:1376:5 [INFO] [stdout] | [INFO] [stdout] 1376 | /// the second element is the main command (e.g., "git"), and the third element is the option [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 1376 | /// the second element is the main command (e.g., "git"), and the third element is the option [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/parse_commands.rs:1377:5 [INFO] [stdout] | [INFO] [stdout] 1377 | /// specifying the Git branch operation ("-m", "-d", "-c"). The subsequent elements depend on [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 1377 | /// specifying the Git branch operation ("-m", "-d", "-c"). The subsequent elements depend on [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/parse_commands.rs:1378:5 [INFO] [stdout] | [INFO] [stdout] 1378 | /// the chosen option. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 1378 | /// the chosen option. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/parse_commands.rs:1460:30 [INFO] [stdout] | [INFO] [stdout] 1460 | fn extract_init_params(args: &Vec) -> (String, String, Option<&str>) { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 1460 - fn extract_init_params(args: &Vec) -> (String, String, Option<&str>) { [INFO] [stdout] 1460 + fn extract_init_params(args: &[String]) -> (String, String, Option<&str>) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/pull.rs:71:20 [INFO] [stdout] | [INFO] [stdout] 71 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 72 | | io::ErrorKind::Other, [INFO] [stdout] 73 | | "Error: Could not fetch remote repository\n", [INFO] [stdout] 74 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 71 ~ return Err(io::Error::other( [INFO] [stdout] 72 ~ "Error: Could not fetch remote repository\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: consider using `sort_by_key` [INFO] [stdout] --> src/pull_request.rs:188:9 [INFO] [stdout] | [INFO] [stdout] 188 | prs.sort_by(|a, b| a.pull_number.cmp(&b.pull_number)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_sort_by [INFO] [stdout] = note: `#[warn(clippy::unnecessary_sort_by)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 188 - prs.sort_by(|a, b| a.pull_number.cmp(&b.pull_number)); [INFO] [stdout] 188 + prs.sort_by_key(|a| a.pull_number); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:674:9 [INFO] [stdout] | [INFO] [stdout] 674 | Err(io::Error::new( [INFO] [stdout] | _________^ [INFO] [stdout] 675 | | io::ErrorKind::Other, [INFO] [stdout] 676 | | "No hay más commits para rebase", [INFO] [stdout] 677 | | )) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 674 ~ Err(io::Error::other( [INFO] [stdout] 675 ~ "No hay más commits para rebase", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:834:24 [INFO] [stdout] | [INFO] [stdout] 834 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 835 | | io::ErrorKind::Other, [INFO] [stdout] 836 | | "No hay commits con los que hacer rebase", [INFO] [stdout] 837 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 834 ~ return Err(io::Error::other( [INFO] [stdout] 835 ~ "No hay commits con los que hacer rebase", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:851:20 [INFO] [stdout] | [INFO] [stdout] 851 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 852 | | io::ErrorKind::Other, [INFO] [stdout] 853 | | "No hay conflictos, se hizo un fast forward rebase", [INFO] [stdout] 854 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 851 ~ return Err(io::Error::other( [INFO] [stdout] 852 ~ "No hay conflictos, se hizo un fast forward rebase", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:889:13 [INFO] [stdout] | [INFO] [stdout] 889 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 890 | | io::ErrorKind::Other, [INFO] [stdout] 891 | | "El rebase no es fast forward, por favor use la interfaz gráfica", [INFO] [stdout] 892 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 889 ~ Err(io::Error::other( [INFO] [stdout] 890 ~ "El rebase no es fast forward, por favor use la interfaz gráfica", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:112:11 [INFO] [stdout] | [INFO] [stdout] 112 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 112 - line: &Vec<&str>, [INFO] [stdout] 112 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:141:11 [INFO] [stdout] | [INFO] [stdout] 141 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 141 - line: &Vec<&str>, [INFO] [stdout] 141 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:169:11 [INFO] [stdout] | [INFO] [stdout] 169 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 169 - line: &Vec<&str>, [INFO] [stdout] 169 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:197:11 [INFO] [stdout] | [INFO] [stdout] 197 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 197 - line: &Vec<&str>, [INFO] [stdout] 197 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:227:11 [INFO] [stdout] | [INFO] [stdout] 227 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 227 - line: &Vec<&str>, [INFO] [stdout] 227 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/server_utils.rs:44:20 [INFO] [stdout] | [INFO] [stdout] 44 | return Err(Error::new(io::ErrorKind::Other, format!("Error: {}", line))); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 44 - return Err(Error::new(io::ErrorKind::Other, format!("Error: {}", line))); [INFO] [stdout] 44 + return Err(Error::other(format!("Error: {}", line))); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/branch.rs:20:22 [INFO] [stdout] | [INFO] [stdout] 20 | let path = match head_content.split(' ').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] = note: `#[warn(clippy::double_ended_iterator_last)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 20 - let path = match head_content.split(' ').last() { [INFO] [stdout] 20 + let path = match head_content.split(' ').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/branch.rs:170:5 [INFO] [stdout] | [INFO] [stdout] 170 | /// will be written. This can be a file, standard output (`stdout`), etc. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] = note: `#[warn(clippy::doc_overindented_list_items)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap_err` on `result` after checking its variant with `is_err` [INFO] [stdout] --> src/tag.rs:140:42 [INFO] [stdout] | [INFO] [stdout] 139 | if result.is_err() { [INFO] [stdout] | ------------------ help: try: `if let Err() = result` [INFO] [stdout] 140 | output.write_all(format!("{:?}", result.unwrap_err()).as_bytes())?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] = note: `#[warn(clippy::unnecessary_unwrap)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/branch.rs:219:5 [INFO] [stdout] | [INFO] [stdout] 219 | /// will be written. This can be a file, standard output (`stdout`), etc. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/branch.rs:316:5 [INFO] [stdout] | [INFO] [stdout] 316 | /// will be written. This can be a file, standard output (`stdout`), etc. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `match` expression can be replaced with `?` [INFO] [stdout] --> src/tree_handler.rs:160:25 [INFO] [stdout] | [INFO] [stdout] 160 | let file_name = match path.pop() { [INFO] [stdout] | _________________________^ [INFO] [stdout] 161 | | Some(file_name) => file_name, [INFO] [stdout] 162 | | None => return None, [INFO] [stdout] 163 | | }; [INFO] [stdout] | |_________^ help: try instead: `path.pop()?` [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: this `match` expression can be replaced with `?` [INFO] [stdout] --> src/tree_handler.rs:166:28 [INFO] [stdout] | [INFO] [stdout] 166 | current_tree = match current_tree.get_subdir(path.remove(0)) { [INFO] [stdout] | ____________________________^ [INFO] [stdout] 167 | | Some(tree) => tree, [INFO] [stdout] 168 | | None => return None, [INFO] [stdout] 169 | | }; [INFO] [stdout] | |_____________^ help: try instead: `current_tree.get_subdir(path.remove(0))?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against true are unnecessary [INFO] [stdout] --> src/branch.rs:743:18 [INFO] [stdout] | [INFO] [stdout] 743 | assert!((before == true) && (after == false)); [INFO] [stdout] | ^^^^^^^^^^^^^^ help: try: `before` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] = note: `#[warn(clippy::bool_comparison)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against false can be replaced by a negation [INFO] [stdout] --> src/branch.rs:743:38 [INFO] [stdout] | [INFO] [stdout] 743 | assert!((before == true) && (after == false)); [INFO] [stdout] | ^^^^^^^^^^^^^^ help: try: `!after` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `result` after checking its variant with `is_ok` [INFO] [stdout] --> src/branch.rs:798:26 [INFO] [stdout] | [INFO] [stdout] 797 | if result.is_ok() { [INFO] [stdout] | ----------------- help: try: `if let Ok() = result` [INFO] [stdout] 798 | let string = result.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] = note: `#[warn(clippy::unnecessary_unwrap)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `unwrap` on `result` after checking its variant with `is_ok` [INFO] [stdout] --> src/branch.rs:870:26 [INFO] [stdout] | [INFO] [stdout] 869 | if result.is_ok() { [INFO] [stdout] | ----------------- help: try: `if let Ok() = result` [INFO] [stdout] 870 | let string = result.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/utils.rs:26:24 [INFO] [stdout] | [INFO] [stdout] 26 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 27 | | io::ErrorKind::Other, [INFO] [stdout] 28 | | "Error obtaining actual directory", [INFO] [stdout] 29 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 26 ~ return Err(io::Error::other( [INFO] [stdout] 27 ~ "Error obtaining actual directory", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/utils.rs:37:24 [INFO] [stdout] | [INFO] [stdout] 37 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 38 | | io::ErrorKind::Other, [INFO] [stdout] 39 | | "Error obtaining git dir", [INFO] [stdout] 40 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 37 ~ return Err(io::Error::other( [INFO] [stdout] 38 ~ "Error obtaining git dir", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the variable `line_number` is used as a loop counter [INFO] [stdout] --> src/check_ignore.rs:79:9 [INFO] [stdout] | [INFO] [stdout] 79 | for path in line.iter().skip(3) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `for (line_number, path) in (1..).zip(line.iter().skip(3))` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_counter_loop [INFO] [stdout] = note: `#[warn(clippy::explicit_counter_loop)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/index.rs:233:17 [INFO] [stdout] | [INFO] [stdout] 233 | pub fn iter(&self) -> std::collections::hash_map::Iter { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 233 | pub fn iter(&self) -> std::collections::hash_map::Iter<'_, String, String> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:70:24 [INFO] [stdout] | [INFO] [stdout] 70 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 71 | | io::ErrorKind::Other, [INFO] [stdout] 72 | | "Error when reading path", [INFO] [stdout] 73 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] = note: `#[warn(clippy::io_other_error)]` on by default [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 70 ~ return Err(io::Error::other( [INFO] [stdout] 71 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:80:24 [INFO] [stdout] | [INFO] [stdout] 80 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 81 | | io::ErrorKind::Other, [INFO] [stdout] 82 | | "Error getting current branch", [INFO] [stdout] 83 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 80 ~ return Err(io::Error::other( [INFO] [stdout] 81 ~ "Error getting current branch", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:125:24 [INFO] [stdout] | [INFO] [stdout] 125 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 126 | | io::ErrorKind::Other, [INFO] [stdout] 127 | | "Error when reading path", [INFO] [stdout] 128 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 125 ~ return Err(io::Error::other( [INFO] [stdout] 126 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:132:20 [INFO] [stdout] | [INFO] [stdout] 132 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 133 | | io::ErrorKind::Other, [INFO] [stdout] 134 | | format!("Branch {} does not exist", branch_name), [INFO] [stdout] 135 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 132 ~ return Err(io::Error::other( [INFO] [stdout] 133 ~ format!("Branch {} does not exist", branch_name), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:175:24 [INFO] [stdout] | [INFO] [stdout] 175 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 176 | | io::ErrorKind::Other, [INFO] [stdout] 177 | | "Error when reading path", [INFO] [stdout] 178 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 175 ~ return Err(io::Error::other( [INFO] [stdout] 176 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:236:24 [INFO] [stdout] | [INFO] [stdout] 236 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 237 | | io::ErrorKind::Other, [INFO] [stdout] 238 | | "Error when reading path", [INFO] [stdout] 239 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 236 ~ return Err(io::Error::other( [INFO] [stdout] 237 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/checkout.rs:274:24 [INFO] [stdout] | [INFO] [stdout] 274 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 275 | | io::ErrorKind::Other, [INFO] [stdout] 276 | | "Error when reading path", [INFO] [stdout] 277 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 274 ~ return Err(io::Error::other( [INFO] [stdout] 275 ~ "Error when reading path", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/checkout.rs:368:5 [INFO] [stdout] | [INFO] [stdout] 368 | /// ID (e.g., "a1b2c3d4e5"). [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/checkout.rs:467:28 [INFO] [stdout] | [INFO] [stdout] 467 | fs::create_dir_all(&branch_ref_file.parent().unwrap()).expect("Failed to create dirs"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `branch_ref_file.parent().unwrap()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] = note: `#[warn(clippy::needless_borrows_for_generic_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/checkout.rs:512:29 [INFO] [stdout] | [INFO] [stdout] 512 | let head_contents = format!("ref: refs/heads/my_branch\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/my_branch\n".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: the borrowed expression implements the required traits [INFO] [stdout] --> src/checkout.rs:559:28 [INFO] [stdout] | [INFO] [stdout] 559 | fs::create_dir_all(&branch_ref_file.parent().unwrap()).expect("Failed to create dirs"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `branch_ref_file.parent().unwrap()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/checkout.rs:563:31 [INFO] [stdout] | [INFO] [stdout] 563 | fs::write(&head_file, format!("ref: refs/heads/other_branch\n")) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/other_branch\n".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: the borrowed expression implements the required traits [INFO] [stdout] --> src/checkout.rs:598:44 [INFO] [stdout] | [INFO] [stdout] 598 | let commit_file = objects_dir.join(&commit_id); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `commit_id` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/checkout.rs:599:28 [INFO] [stdout] | [INFO] [stdout] 599 | fs::create_dir_all(&commit_file.parent().unwrap()).expect("Failed to create dirs"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `commit_file.parent().unwrap()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/checkout.rs:650:28 [INFO] [stdout] | [INFO] [stdout] 650 | fs::create_dir_all(&branch_ref_file.parent().unwrap()).expect("Failed to create dirs"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `branch_ref_file.parent().unwrap()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/checkout.rs:654:31 [INFO] [stdout] | [INFO] [stdout] 654 | fs::write(&head_file, format!("ref: refs/heads/other_branch\n")) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/other_branch\n".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/checkout.rs:689:29 [INFO] [stdout] | [INFO] [stdout] 689 | let head_contents = format!("ref: refs/heads/master"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/master".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: the borrowed expression implements the required traits [INFO] [stdout] --> src/checkout.rs:775:48 [INFO] [stdout] | [INFO] [stdout] 775 | let file1_content = fs::read_to_string(&file1).expect("Failed to read file"); [INFO] [stdout] | ^^^^^^ help: change this to: `file1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/clone.rs:86:24 [INFO] [stdout] | [INFO] [stdout] 86 | .map(|x| match x.0.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 86 - .map(|x| match x.0.split('/').last() { [INFO] [stdout] 86 + .map(|x| match x.0.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/commit.rs:69:20 [INFO] [stdout] | [INFO] [stdout] 69 | return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 69 - return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] 69 + return Err(io::Error::other("No changes were made")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/commit.rs:131:29 [INFO] [stdout] | [INFO] [stdout] 131 | let branch_name = match head_content.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 131 - let branch_name = match head_content.split('/').last() { [INFO] [stdout] 131 + let branch_name = match head_content.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/commit.rs:208:20 [INFO] [stdout] | [INFO] [stdout] 208 | return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 208 - return Err(io::Error::new(io::ErrorKind::Other, "No changes were made")); [INFO] [stdout] 208 + return Err(io::Error::other("No changes were made")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:175:9 [INFO] [stdout] | [INFO] [stdout] 175 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:223:9 [INFO] [stdout] | [INFO] [stdout] 223 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:311:9 [INFO] [stdout] | [INFO] [stdout] 311 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:361:9 [INFO] [stdout] | [INFO] [stdout] 361 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:500:9 [INFO] [stdout] | [INFO] [stdout] 500 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/config.rs:551:9 [INFO] [stdout] | [INFO] [stdout] 551 | /// or output will be written. [INFO] [stdout] | ^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/config.rs:680:28 [INFO] [stdout] | [INFO] [stdout] 680 | return Err(io::Error::new( [INFO] [stdout] | ____________________________^ [INFO] [stdout] 681 | | io::ErrorKind::Other, [INFO] [stdout] 682 | | "No se pudo obtener el directorio padre", [INFO] [stdout] 683 | | )); [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 680 ~ return Err(io::Error::other( [INFO] [stdout] 681 ~ "No se pudo obtener el directorio padre", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> src/config.rs:834:9 [INFO] [stdout] | [INFO] [stdout] 834 | / let _ = config.add_remote( [INFO] [stdout] 835 | | "my_remote".to_string(), [INFO] [stdout] 836 | | "url".to_string(), [INFO] [stdout] 837 | | "fetch".to_string(), [INFO] [stdout] 838 | | &mut output, [INFO] [stdout] 839 | | )?; [INFO] [stdout] | |___________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] = note: `#[warn(clippy::let_unit_value)]` on by default [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 834 - let _ = config.add_remote( [INFO] [stdout] 834 + config.add_remote( [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> src/config.rs:1010:9 [INFO] [stdout] | [INFO] [stdout] 1010 | / let _ = config.add_remote( [INFO] [stdout] 1011 | | "my_remote".to_string(), [INFO] [stdout] 1012 | | "url".to_string(), [INFO] [stdout] 1013 | | "fetch".to_string(), [INFO] [stdout] 1014 | | &mut output, [INFO] [stdout] 1015 | | )?; [INFO] [stdout] | |___________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 1010 - let _ = config.add_remote( [INFO] [stdout] 1010 + config.add_remote( [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> src/config.rs:1036:9 [INFO] [stdout] | [INFO] [stdout] 1036 | / let _ = config.add_remote( [INFO] [stdout] 1037 | | "my_remote".to_string(), [INFO] [stdout] 1038 | | "url".to_string(), [INFO] [stdout] 1039 | | "fetch".to_string(), [INFO] [stdout] 1040 | | &mut output, [INFO] [stdout] 1041 | | )?; [INFO] [stdout] | |___________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 1036 - let _ = config.add_remote( [INFO] [stdout] 1036 + config.add_remote( [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> src/config.rs:1074:9 [INFO] [stdout] | [INFO] [stdout] 1074 | / let _ = config.add_remote( [INFO] [stdout] 1075 | | "my_remote".to_string(), [INFO] [stdout] 1076 | | "url".to_string(), [INFO] [stdout] 1077 | | "fetch".to_string(), [INFO] [stdout] 1078 | | &mut output, [INFO] [stdout] 1079 | | )?; [INFO] [stdout] | |___________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 1074 - let _ = config.add_remote( [INFO] [stdout] 1074 + config.add_remote( [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/diff.rs:78:49 [INFO] [stdout] | [INFO] [stdout] 78 | fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] = note: `#[warn(clippy::ptr_arg)]` on by default [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 78 - fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] 78 + fn compute_longest_common_subsequence_matrix(a: &[String], b: &Vec) -> Vec> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/diff.rs:78:66 [INFO] [stdout] | [INFO] [stdout] 78 | fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 78 - fn compute_longest_common_subsequence_matrix(a: &Vec, b: &Vec) -> Vec> { [INFO] [stdout] 78 + fn compute_longest_common_subsequence_matrix(a: &Vec, b: &[String]) -> Vec> { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/fetch.rs:167:24 [INFO] [stdout] | [INFO] [stdout] 167 | .map(|x| match x.0.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 167 - .map(|x| match x.0.split('/').last() { [INFO] [stdout] 167 + .map(|x| match x.0.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/gui/clone_window.rs:117:36 [INFO] [stdout] | [INFO] [stdout] 117 | let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 117 - let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] 117 + let remote_repo_name = url_text.split('/').next_back().unwrap_or(""); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/clone_window.rs:180:54 [INFO] [stdout] | [INFO] [stdout] 180 | apply_button_style(&browse_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 180 - apply_button_style(&browse_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 180 + apply_button_style(&browse_button).map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/clone_window.rs:181:53 [INFO] [stdout] | [INFO] [stdout] 181 | apply_button_style(&clone_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 181 - apply_button_style(&clone_button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 181 + apply_button_style(&clone_button).map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:37:22 [INFO] [stdout] | [INFO] [stdout] 37 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 37 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] 37 + .map_err(|_| io::Error::other("Failed to apply window style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:46:22 [INFO] [stdout] | [INFO] [stdout] 46 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button1 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 46 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button1 style"))?; [INFO] [stdout] 46 + .map_err(|_| io::Error::other("Failed to apply button1 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:48:22 [INFO] [stdout] | [INFO] [stdout] 48 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button2 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 48 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button2 style"))?; [INFO] [stdout] 48 + .map_err(|_| io::Error::other("Failed to apply button2 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:50:22 [INFO] [stdout] | [INFO] [stdout] 50 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button3 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 50 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button3 style"))?; [INFO] [stdout] 50 + .map_err(|_| io::Error::other("Failed to apply button3 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/init_window.rs:52:22 [INFO] [stdout] | [INFO] [stdout] 52 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button4 style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 52 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply button4 style"))?; [INFO] [stdout] 52 + .map_err(|_| io::Error::other("Failed to apply button4 style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/gui/init_window.rs:243:5 [INFO] [stdout] | [INFO] [stdout] 243 | /// when the user clicks the "OK" button, passing the entered text to the callback. [INFO] [stdout] | ^^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:31:13 [INFO] [stdout] | [INFO] [stdout] 31 | io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 31 - io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n") [INFO] [stdout] 31 + io::Error::other("Error applying window stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:38:13 [INFO] [stdout] | [INFO] [stdout] 38 | io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 38 - io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] 38 + io::Error::other("Error applying button stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:41:13 [INFO] [stdout] | [INFO] [stdout] 41 | io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 41 - io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] 41 + io::Error::other("Error applying button stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:44:13 [INFO] [stdout] | [INFO] [stdout] 44 | io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 44 - io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n") [INFO] [stdout] 44 + io::Error::other("Error applying button stlye.\n") [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:22:20 [INFO] [stdout] | [INFO] [stdout] 22 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 23 | | io::ErrorKind::Other, [INFO] [stdout] 24 | | "Failed to initialize GTK.\n", [INFO] [stdout] 25 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] = note: `#[warn(clippy::io_other_error)]` on by default [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 22 ~ return Err(io::Error::other( [INFO] [stdout] 23 ~ "Failed to initialize GTK.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/main_window.rs:53:13 [INFO] [stdout] | [INFO] [stdout] 53 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 54 | | io::ErrorKind::Other, [INFO] [stdout] 55 | | "Failed to run main window.", [INFO] [stdout] 56 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 53 ~ Err(io::Error::other( [INFO] [stdout] 54 ~ "Failed to run main window.", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:28:37 [INFO] [stdout] | [INFO] [stdout] 28 | run_main_window().map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 28 - run_main_window().map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 28 + run_main_window().map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:53:28 [INFO] [stdout] | [INFO] [stdout] 53 | return Err(io::Error::new( [INFO] [stdout] | ____________________________^ [INFO] [stdout] 54 | | io::ErrorKind::Other, [INFO] [stdout] 55 | | "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] 56 | | )); [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 53 ~ return Err(io::Error::other( [INFO] [stdout] 54 ~ "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:103:24 [INFO] [stdout] | [INFO] [stdout] 103 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 104 | | io::ErrorKind::Other, [INFO] [stdout] 105 | | "Failed to convert path to string.\n", [INFO] [stdout] 106 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 103 ~ return Err(io::Error::other( [INFO] [stdout] 104 ~ "Failed to convert path to string.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:112:36 [INFO] [stdout] | [INFO] [stdout] 112 | Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 112 - Err(err) => return Err(io::Error::new(io::ErrorKind::Other, err)), [INFO] [stdout] 112 + Err(err) => return Err(io::Error::other(err)), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:117:13 [INFO] [stdout] | [INFO] [stdout] 117 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 118 | | io::ErrorKind::Other, [INFO] [stdout] 119 | | "Failed to show repository window.\n", [INFO] [stdout] 120 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 117 ~ Err(io::Error::other( [INFO] [stdout] 118 ~ "Failed to show repository window.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:151:28 [INFO] [stdout] | [INFO] [stdout] 151 | return Err(io::Error::new( [INFO] [stdout] | ____________________________^ [INFO] [stdout] 152 | | io::ErrorKind::Other, [INFO] [stdout] 153 | | "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] 154 | | )); [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 151 ~ return Err(io::Error::other( [INFO] [stdout] 152 ~ "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:324:24 [INFO] [stdout] | [INFO] [stdout] 324 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 325 | | io::ErrorKind::Other, [INFO] [stdout] 326 | | "Can't find git dir.\n", [INFO] [stdout] 327 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 324 ~ return Err(io::Error::other( [INFO] [stdout] 325 ~ "Can't find git dir.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:334:24 [INFO] [stdout] | [INFO] [stdout] 334 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 335 | | io::ErrorKind::Other, [INFO] [stdout] 336 | | "Can't find working dir.\n", [INFO] [stdout] 337 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 334 ~ return Err(io::Error::other( [INFO] [stdout] 335 ~ "Can't find working dir.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:363:24 [INFO] [stdout] | [INFO] [stdout] 363 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 364 | | io::ErrorKind::Other, [INFO] [stdout] 365 | | "Can't find git dir.\n", [INFO] [stdout] 366 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 363 ~ return Err(io::Error::other( [INFO] [stdout] 364 ~ "Can't find git dir.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:388:47 [INFO] [stdout] | [INFO] [stdout] 388 | apply_button_style(&button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 388 - apply_button_style(&button).map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 388 + apply_button_style(&button).map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:392:24 [INFO] [stdout] | [INFO] [stdout] 392 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get the button object"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 392 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get the button object"))?; [INFO] [stdout] 392 + .ok_or_else(|| io::Error::other("Failed to get the button object"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/gui/repository_window.rs:690:5 [INFO] [stdout] | [INFO] [stdout] 690 | /// and manipulate the GUI components. [INFO] [stdout] | ^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1477:20 [INFO] [stdout] | [INFO] [stdout] 1477 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1477 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1477 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1510:20 [INFO] [stdout] | [INFO] [stdout] 1510 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1510 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1510 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1544:20 [INFO] [stdout] | [INFO] [stdout] 1544 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1544 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1544 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1578:20 [INFO] [stdout] | [INFO] [stdout] 1578 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1578 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1578 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1612:20 [INFO] [stdout] | [INFO] [stdout] 1612 | return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1612 - return Err(io::Error::new(io::ErrorKind::Other, string)); [INFO] [stdout] 1612 + return Err(io::Error::other(string)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1855:24 [INFO] [stdout] | [INFO] [stdout] 1855 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 1856 | | io::ErrorKind::Other, [INFO] [stdout] 1857 | | "Error turning result into string", [INFO] [stdout] 1858 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1855 ~ return Err(io::Error::other( [INFO] [stdout] 1856 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1866:24 [INFO] [stdout] | [INFO] [stdout] 1866 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 1867 | | io::ErrorKind::Other, [INFO] [stdout] 1868 | | "Error turning result into string", [INFO] [stdout] 1869 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1866 ~ return Err(io::Error::other( [INFO] [stdout] 1867 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:1877:20 [INFO] [stdout] | [INFO] [stdout] 1877 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 1878 | | io::ErrorKind::Other, [INFO] [stdout] 1879 | | "Error obtaining TextView", [INFO] [stdout] 1880 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 1877 ~ return Err(io::Error::other( [INFO] [stdout] 1878 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2314:24 [INFO] [stdout] | [INFO] [stdout] 2314 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2315 | | io::ErrorKind::Other, [INFO] [stdout] 2316 | | "Error obtaining text view for list trees", [INFO] [stdout] 2317 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2314 ~ return Err(io::Error::other( [INFO] [stdout] 2315 ~ "Error obtaining text view for list trees", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2326:24 [INFO] [stdout] | [INFO] [stdout] 2326 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2327 | | io::ErrorKind::Other, [INFO] [stdout] 2328 | | "Error turning result into string", [INFO] [stdout] 2329 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2326 ~ return Err(io::Error::other( [INFO] [stdout] 2327 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2337:20 [INFO] [stdout] | [INFO] [stdout] 2337 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 2338 | | io::ErrorKind::Other, [INFO] [stdout] 2339 | | "Error obtaining TextView", [INFO] [stdout] 2340 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2337 ~ return Err(io::Error::other( [INFO] [stdout] 2338 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2465:24 [INFO] [stdout] | [INFO] [stdout] 2465 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2466 | | io::ErrorKind::Other, [INFO] [stdout] 2467 | | "Couldn't get remote text view.", [INFO] [stdout] 2468 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2465 ~ return Err(io::Error::other( [INFO] [stdout] 2466 ~ "Couldn't get remote text view.", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2476:24 [INFO] [stdout] | [INFO] [stdout] 2476 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2477 | | io::ErrorKind::Other, [INFO] [stdout] 2478 | | "Error turning result into string", [INFO] [stdout] 2479 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2476 ~ return Err(io::Error::other( [INFO] [stdout] 2477 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2487:20 [INFO] [stdout] | [INFO] [stdout] 2487 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 2488 | | io::ErrorKind::Other, [INFO] [stdout] 2489 | | "Error obtaining TextView", [INFO] [stdout] 2490 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2487 ~ return Err(io::Error::other( [INFO] [stdout] 2488 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2519:24 [INFO] [stdout] | [INFO] [stdout] 2519 | return Err(io::Error::new(io::ErrorKind::Other, "&error")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2519 - return Err(io::Error::new(io::ErrorKind::Other, "&error")); [INFO] [stdout] 2519 + return Err(io::Error::other("&error")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2551:24 [INFO] [stdout] | [INFO] [stdout] 2551 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2552 | | io::ErrorKind::Other, [INFO] [stdout] 2553 | | "Error obtaining text view", [INFO] [stdout] 2554 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2551 ~ return Err(io::Error::other( [INFO] [stdout] 2552 ~ "Error obtaining text view", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2562:24 [INFO] [stdout] | [INFO] [stdout] 2562 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 2563 | | io::ErrorKind::Other, [INFO] [stdout] 2564 | | "Error turning result into string", [INFO] [stdout] 2565 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2562 ~ return Err(io::Error::other( [INFO] [stdout] 2563 ~ "Error turning result into string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:2573:20 [INFO] [stdout] | [INFO] [stdout] 2573 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 2574 | | io::ErrorKind::Other, [INFO] [stdout] 2575 | | "Error obtaining TextView", [INFO] [stdout] 2576 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 2573 ~ return Err(io::Error::other( [INFO] [stdout] 2574 ~ "Error obtaining TextView", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> tests/tests_client.rs:31:31 [INFO] [stdout] | [INFO] [stdout] 31 | assert!(refs.contains_key(&"HEAD".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: replace it with: `"HEAD"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] = note: `#[warn(clippy::unnecessary_to_owned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3169:24 [INFO] [stdout] | [INFO] [stdout] 3169 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 3170 | | io::ErrorKind::Other, [INFO] [stdout] 3171 | | "Text view buffer can't be accessed.\n", [INFO] [stdout] 3172 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3169 ~ return Err(io::Error::other( [INFO] [stdout] 3170 ~ "Text view buffer can't be accessed.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3614:24 [INFO] [stdout] | [INFO] [stdout] 3614 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3614 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 3614 + .map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3616:24 [INFO] [stdout] | [INFO] [stdout] 3616 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3616 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 3616 + .map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:3618:24 [INFO] [stdout] | [INFO] [stdout] 3618 | .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 3618 - .map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 3618 + .map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/gui/repository_window.rs:4301:33 [INFO] [stdout] | [INFO] [stdout] 4301 | let branch_name = match branch.split('/').last() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 4301 - let branch_name = match branch.split('/').last() { [INFO] [stdout] 4301 + let branch_name = match branch.split('/').next_back() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4517:5 [INFO] [stdout] | [INFO] [stdout] 4517 | /// Sets up the functionality of the merge button. Will merge the current branch with the one that was selected. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] = note: `#[warn(clippy::doc_lazy_continuation)]` on by default [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4517 | /// Sets up the functionality of the merge button. Will merge the current branch with the one that was selected. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4567:5 [INFO] [stdout] | [INFO] [stdout] 4567 | /// Updates the box with the paths of the files that have conflicts. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4567 | /// Updates the box with the paths of the files that have conflicts. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4574:5 [INFO] [stdout] | [INFO] [stdout] 4574 | /// Sets the behavior for the `gtk::ComboBoxText` when its active item changes. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4574 | /// Sets the behavior for the `gtk::ComboBoxText` when its active item changes. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/gui/repository_window.rs:4615:5 [INFO] [stdout] | [INFO] [stdout] 4615 | /// Sets the behavior for an update button. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 4615 | /// Sets the behavior for an update button. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4694:24 [INFO] [stdout] | [INFO] [stdout] 4694 | return Err(io::Error::new(io::ErrorKind::Other, "Entry not found.\n")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4694 - return Err(io::Error::new(io::ErrorKind::Other, "Entry not found.\n")); [INFO] [stdout] 4694 + return Err(io::Error::other("Entry not found.\n")); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4700:24 [INFO] [stdout] | [INFO] [stdout] 4700 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4701 | | io::ErrorKind::Other, [INFO] [stdout] 4702 | | "Text view not found.\n", [INFO] [stdout] 4703 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4700 ~ return Err(io::Error::other( [INFO] [stdout] 4701 ~ "Text view not found.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4763:24 [INFO] [stdout] | [INFO] [stdout] 4763 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4764 | | io::ErrorKind::Other, [INFO] [stdout] 4765 | | "Couldn't get rebase branch entry.\n", [INFO] [stdout] 4766 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4763 ~ return Err(io::Error::other( [INFO] [stdout] 4764 ~ "Couldn't get rebase branch entry.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4836:17 [INFO] [stdout] | [INFO] [stdout] 4836 | Err(io::Error::new( [INFO] [stdout] | _________________^ [INFO] [stdout] 4837 | | io::ErrorKind::Other, [INFO] [stdout] 4838 | | format!("Error getting not staged text: {}", err), [INFO] [stdout] 4839 | | ))?; [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4836 ~ Err(io::Error::other( [INFO] [stdout] 4837 ~ format!("Error getting not staged text: {}", err), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4848:17 [INFO] [stdout] | [INFO] [stdout] 4848 | Err(io::Error::new( [INFO] [stdout] | _________________^ [INFO] [stdout] 4849 | | io::ErrorKind::Other, [INFO] [stdout] 4850 | | format!("Error getting staged text: {}", err), [INFO] [stdout] 4851 | | ))?; [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4848 ~ Err(io::Error::other( [INFO] [stdout] 4849 ~ format!("Error getting staged text: {}", err), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4860:25 [INFO] [stdout] | [INFO] [stdout] 4860 | Err(err) => Err(io::Error::new( [INFO] [stdout] | _________________________^ [INFO] [stdout] 4861 | | io::ErrorKind::Other, [INFO] [stdout] 4862 | | format!("Error setting staging area texts: {}", err), [INFO] [stdout] 4863 | | )), [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4860 ~ Err(err) => Err(io::Error::other( [INFO] [stdout] 4861 ~ format!("Error setting staging area texts: {}", err), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4878:45 [INFO] [stdout] | [INFO] [stdout] 4878 | std::env::current_dir().map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4878 - std::env::current_dir().map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4878 + std::env::current_dir().map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4879:54 [INFO] [stdout] | [INFO] [stdout] 4879 | let current_dir_str = current_dir.to_str().ok_or(io::Error::new( [INFO] [stdout] | ______________________________________________________^ [INFO] [stdout] 4880 | | io::ErrorKind::Other, [INFO] [stdout] 4881 | | "Failed to convert current directory to string", [INFO] [stdout] 4882 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4879 ~ let current_dir_str = current_dir.to_str().ok_or(io::Error::other( [INFO] [stdout] 4880 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4884:79 [INFO] [stdout] | [INFO] [stdout] 4884 | let git_dir = find_git_directory(&mut current_dir.clone(), GIT_DIR).ok_or(io::Error::new( [INFO] [stdout] | _______________________________________________________________________________^ [INFO] [stdout] 4885 | | io::ErrorKind::Other, [INFO] [stdout] 4886 | | "Failed to find git directory", [INFO] [stdout] 4887 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4884 ~ let git_dir = find_git_directory(&mut current_dir.clone(), GIT_DIR).ok_or(io::Error::other( [INFO] [stdout] 4885 ~ "Failed to find git directory", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4892:24 [INFO] [stdout] | [INFO] [stdout] 4892 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4893 | | io::ErrorKind::Other, [INFO] [stdout] 4894 | | "Failed to convert current directory to string", [INFO] [stdout] 4895 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4892 ~ return Err(io::Error::other( [INFO] [stdout] 4893 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4904:22 [INFO] [stdout] | [INFO] [stdout] 4904 | .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4904 - .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4904 + .map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4915:22 [INFO] [stdout] | [INFO] [stdout] 4915 | .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4915 - .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4915 + .map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4936:24 [INFO] [stdout] | [INFO] [stdout] 4936 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 4937 | | io::ErrorKind::Other, [INFO] [stdout] 4938 | | "Failed to convert current directory to string", [INFO] [stdout] 4939 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4936 ~ return Err(io::Error::other( [INFO] [stdout] 4937 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of `ok` [INFO] [stdout] --> src/gui/repository_window.rs:4947:9 [INFO] [stdout] | [INFO] [stdout] 4947 | / match tree_handler::load_tree_from_commit(&last_commit, &git_dir) { [INFO] [stdout] 4948 | | Ok(tree) => Some(tree), [INFO] [stdout] 4949 | | Err(_) => None, [INFO] [stdout] 4950 | | }; [INFO] [stdout] | |_________^ help: replace with: `tree_handler::load_tree_from_commit(&last_commit, &git_dir).ok()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_ok_err [INFO] [stdout] = note: `#[warn(clippy::manual_ok_err)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4955:22 [INFO] [stdout] | [INFO] [stdout] 4955 | .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4955 - .map_err(|e| io::Error::new(io::ErrorKind::Other, e))?; [INFO] [stdout] 4955 + .map_err(|e| io::Error::other(e))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4976:72 [INFO] [stdout] | [INFO] [stdout] 4976 | let text_view: gtk::TextView = builder.get_object(view_name).ok_or(io::Error::new( [INFO] [stdout] | ________________________________________________________________________^ [INFO] [stdout] 4977 | | io::ErrorKind::Other, [INFO] [stdout] 4978 | | format!("Failed to get {} object", view_name), [INFO] [stdout] 4979 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4976 ~ let text_view: gtk::TextView = builder.get_object(view_name).ok_or(io::Error::other( [INFO] [stdout] 4977 ~ format!("Failed to get {} object", view_name), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:4981:47 [INFO] [stdout] | [INFO] [stdout] 4981 | let buffer = text_view.get_buffer().ok_or(io::Error::new( [INFO] [stdout] | _______________________________________________^ [INFO] [stdout] 4982 | | io::ErrorKind::Other, [INFO] [stdout] 4983 | | format!("Failed to get buffer for {}", view_name), [INFO] [stdout] 4984 | | ))?; [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 4981 ~ let buffer = text_view.get_buffer().ok_or(io::Error::other( [INFO] [stdout] 4982 ~ format!("Failed to get buffer for {}", view_name), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5033:24 [INFO] [stdout] | [INFO] [stdout] 5033 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get label"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5033 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get label"))?; [INFO] [stdout] 5033 + .ok_or_else(|| io::Error::other("Failed to get label"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5039:24 [INFO] [stdout] | [INFO] [stdout] 5039 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 5040 | | io::ErrorKind::Other, [INFO] [stdout] 5041 | | "Git directory not found\n", [INFO] [stdout] 5042 | | )) [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5039 ~ return Err(io::Error::other( [INFO] [stdout] 5040 ~ "Git directory not found\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5054:24 [INFO] [stdout] | [INFO] [stdout] 5054 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history view"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5054 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history view"))?; [INFO] [stdout] 5054 + .ok_or_else(|| io::Error::other("Failed to get history view"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5057:24 [INFO] [stdout] | [INFO] [stdout] 5057 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history buffer"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5057 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get history buffer"))?; [INFO] [stdout] 5057 + .ok_or_else(|| io::Error::other("Failed to get history buffer"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5066:9 [INFO] [stdout] | [INFO] [stdout] 5066 | / io::Error::new( [INFO] [stdout] 5067 | | io::ErrorKind::Other, [INFO] [stdout] 5068 | | "Failed to convert current directory to string", [INFO] [stdout] 5069 | | ) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5066 ~ io::Error::other( [INFO] [stdout] 5067 ~ "Failed to convert current directory to string", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5091:21 [INFO] [stdout] | [INFO] [stdout] 5091 | None => Err(io::Error::new( [INFO] [stdout] | _____________________^ [INFO] [stdout] 5092 | | io::ErrorKind::Other, [INFO] [stdout] 5093 | | "Git directory not found", [INFO] [stdout] 5094 | | )), [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5091 ~ None => Err(io::Error::other( [INFO] [stdout] 5092 ~ "Git directory not found", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/repository_window.rs:5147:17 [INFO] [stdout] | [INFO] [stdout] 5147 | / io::Error::new( [INFO] [stdout] 5148 | | io::ErrorKind::Other, [INFO] [stdout] 5149 | | "Failed to get commit message text view", [INFO] [stdout] 5150 | | ) [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 5147 ~ io::Error::other( [INFO] [stdout] 5148 ~ "Failed to get commit message text view", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:322:25 [INFO] [stdout] | [INFO] [stdout] 322 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 322 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] 322 + .map_err(|_err| io::Error::other("Error applying window stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:335:25 [INFO] [stdout] | [INFO] [stdout] 335 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 335 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] 335 + .map_err(|_err| io::Error::other("Error applying button stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:374:25 [INFO] [stdout] | [INFO] [stdout] 374 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 374 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window stlye.\n"))?; [INFO] [stdout] 374 + .map_err(|_err| io::Error::other("Error applying window stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:391:25 [INFO] [stdout] | [INFO] [stdout] 391 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 391 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button stlye.\n"))?; [INFO] [stdout] 391 + .map_err(|_err| io::Error::other("Error applying button stlye.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:433:25 [INFO] [stdout] | [INFO] [stdout] 433 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window style.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 433 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying window style.\n"))?; [INFO] [stdout] 433 + .map_err(|_err| io::Error::other("Error applying window style.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:457:25 [INFO] [stdout] | [INFO] [stdout] 457 | .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button style.\n"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 457 - .map_err(|_err| io::Error::new(io::ErrorKind::Other, "Error applying button style.\n"))?; [INFO] [stdout] 457 + .map_err(|_err| io::Error::other("Error applying button style.\n"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/style.rs:515:22 [INFO] [stdout] | [INFO] [stdout] 515 | .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 515 - .map_err(|_| io::Error::new(io::ErrorKind::Other, "Failed to apply window style"))?; [INFO] [stdout] 515 + .map_err(|_| io::Error::other("Failed to apply window style"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/gui/visual_branches.rs:47:24 [INFO] [stdout] | [INFO] [stdout] 47 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get drawing area"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 47 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Failed to get drawing area"))?; [INFO] [stdout] 47 + .ok_or_else(|| io::Error::other("Failed to get drawing area"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:22:20 [INFO] [stdout] | [INFO] [stdout] 22 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 23 | | io::ErrorKind::Other, [INFO] [stdout] 24 | | "Failed to initialize GTK.\n", [INFO] [stdout] 25 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] = note: `#[warn(clippy::io_other_error)]` on by default [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 22 ~ return Err(io::Error::other( [INFO] [stdout] 23 ~ "Failed to initialize GTK.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:28:37 [INFO] [stdout] | [INFO] [stdout] 28 | run_main_window().map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 28 - run_main_window().map_err(|err| io::Error::new(io::ErrorKind::Other, err))?; [INFO] [stdout] 28 + run_main_window().map_err(|err| io::Error::other(err))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/gui/visual_branches.rs:168:15 [INFO] [stdout] | [INFO] [stdout] 168 | branches: &Vec, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 168 - branches: &Vec, [INFO] [stdout] 168 + branches: &[String], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:53:28 [INFO] [stdout] | [INFO] [stdout] 53 | return Err(io::Error::new( [INFO] [stdout] | ____________________________^ [INFO] [stdout] 54 | | io::ErrorKind::Other, [INFO] [stdout] 55 | | "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] 56 | | )); [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 53 ~ return Err(io::Error::other( [INFO] [stdout] 54 ~ "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/main.rs:151:28 [INFO] [stdout] | [INFO] [stdout] 151 | return Err(io::Error::new( [INFO] [stdout] | ____________________________^ [INFO] [stdout] 152 | | io::ErrorKind::Other, [INFO] [stdout] 153 | | "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] 154 | | )); [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 151 ~ return Err(io::Error::other( [INFO] [stdout] 152 ~ "No se ha ingresado el segundo argumento.\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> tests/tests_pull.rs:42:20 [INFO] [stdout] | [INFO] [stdout] 42 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 43 | | io::ErrorKind::Other, [INFO] [stdout] 44 | | "Files copied incorrectly", [INFO] [stdout] 45 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] = note: `#[warn(clippy::io_other_error)]` on by default [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 42 ~ return Err(io::Error::other( [INFO] [stdout] 43 ~ "Files copied incorrectly", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> tests/tests_pull.rs:70:20 [INFO] [stdout] | [INFO] [stdout] 70 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 71 | | io::ErrorKind::Other, [INFO] [stdout] 72 | | "File copied incorrectly", [INFO] [stdout] 73 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 70 ~ return Err(io::Error::other( [INFO] [stdout] 71 ~ "File copied incorrectly", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/index.rs:436:30 [INFO] [stdout] | [INFO] [stdout] 436 | index.add_file(path, &hash)?; [INFO] [stdout] | ^^^^^ help: change this to: `hash` [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/index.rs:464:30 [INFO] [stdout] | [INFO] [stdout] 464 | index.add_file(path, &hash)?; [INFO] [stdout] | ^^^^^ help: change this to: `hash` [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/index.rs:467:30 [INFO] [stdout] | [INFO] [stdout] 467 | index.add_file(path, &hash)?; [INFO] [stdout] | ^^^^^ help: change this to: `hash` [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 can be `std::io::Error::other(_)` [INFO] [stdout] --> tests/tests_pull.rs:80:20 [INFO] [stdout] | [INFO] [stdout] 80 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 81 | | io::ErrorKind::Other, [INFO] [stdout] 82 | | "File copied incorrectly. Must be different", [INFO] [stdout] 83 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 80 ~ return Err(io::Error::other( [INFO] [stdout] 81 ~ "File copied incorrectly. Must be different", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/log.rs:47:5 [INFO] [stdout] | [INFO] [stdout] 47 | /// the repo will be read. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 47 | /// the repo will be read. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/log.rs:216:9 [INFO] [stdout] | [INFO] [stdout] 216 | /// or disabled (`false`). [INFO] [stdout] | ^^^^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/ls_tree.rs:58:34 [INFO] [stdout] | [INFO] [stdout] 58 | Err(_) => return Err(io::Error::new(io::ErrorKind::Other, "Not a tree")), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 58 - Err(_) => return Err(io::Error::new(io::ErrorKind::Other, "Not a tree")), [INFO] [stdout] 58 + Err(_) => return Err(io::Error::other("Not a tree")), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/ls_tree.rs:67:25 [INFO] [stdout] | [INFO] [stdout] 67 | _ => return Err(io::Error::new(io::ErrorKind::Other, "Invalid option")), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 67 - _ => return Err(io::Error::new(io::ErrorKind::Other, "Invalid option")), [INFO] [stdout] 67 + _ => return Err(io::Error::other("Invalid option")), [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/merge.rs:54:20 [INFO] [stdout] | [INFO] [stdout] 54 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 55 | | io::ErrorKind::Other, [INFO] [stdout] 56 | | "No common ancestor found.", [INFO] [stdout] 57 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 54 ~ return Err(io::Error::other( [INFO] [stdout] 55 ~ "No common ancestor found.", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/merge.rs:423:9 [INFO] [stdout] | [INFO] [stdout] 423 | assert_eq!(is_fast_forward(our_branch_commit, common_commit), true); [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] 423 - assert_eq!(is_fast_forward(our_branch_commit, common_commit), true); [INFO] [stdout] 423 + assert!(is_fast_forward(our_branch_commit, common_commit)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/merge.rs:431:9 [INFO] [stdout] | [INFO] [stdout] 431 | assert_eq!(is_fast_forward(our_branch_commit, common_commit), false); [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] 431 - assert_eq!(is_fast_forward(our_branch_commit, common_commit), false); [INFO] [stdout] 431 + assert!(!is_fast_forward(our_branch_commit, common_commit)); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/merge.rs:435:28 [INFO] [stdout] | [INFO] [stdout] 435 | fs::create_dir_all(&git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/merge.rs:460:48 [INFO] [stdout] | [INFO] [stdout] 460 | let commit_1_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:463:43 [INFO] [stdout] | [INFO] [stdout] 463 | let _ = branch::create_new_branch(&git_dir, "test", None, &mut io::stdout()); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:477:49 [INFO] [stdout] | [INFO] [stdout] 477 | let _commit_2_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:485:48 [INFO] [stdout] | [INFO] [stdout] 485 | let commit_3_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:488:66 [INFO] [stdout] | [INFO] [stdout] 488 | find_common_ancestor(&commit_1_hash, &commit_3_hash, &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:505:49 [INFO] [stdout] | [INFO] [stdout] 505 | let _commit_1_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:513:48 [INFO] [stdout] | [INFO] [stdout] 513 | let commit_2_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:516:43 [INFO] [stdout] | [INFO] [stdout] 516 | let _ = branch::create_new_branch(&git_dir, branch_name, None, &mut io::stdout()); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:530:48 [INFO] [stdout] | [INFO] [stdout] 530 | let commit_3_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:534:24 [INFO] [stdout] | [INFO] [stdout] 534 | .write_all(format!("ref: refs/heads/main").as_bytes()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/main".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: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/merge.rs:538:48 [INFO] [stdout] | [INFO] [stdout] 538 | let commit_4_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:541:66 [INFO] [stdout] | [INFO] [stdout] 541 | find_common_ancestor(&commit_3_hash, &commit_4_hash, &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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 operation has no effect [INFO] [stdout] --> tests/logger_tests.rs:63:49 [INFO] [stdout] | [INFO] [stdout] 63 | thread::sleep(Duration::from_millis(1 * times)); [INFO] [stdout] | ^^^^^^^^^ help: consider reducing it to: `times` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [INFO] [stdout] = note: `#[warn(clippy::identity_op)]` 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/merge.rs:581:48 [INFO] [stdout] | [INFO] [stdout] 581 | let commit_1_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:584:43 [INFO] [stdout] | [INFO] [stdout] 584 | let _ = branch::create_new_branch(&git_dir, branch_name, None, &mut io::stdout()); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:605:36 [INFO] [stdout] | [INFO] [stdout] 605 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:621:48 [INFO] [stdout] | [INFO] [stdout] 621 | let commit_3_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:623:71 [INFO] [stdout] | [INFO] [stdout] 623 | let main_branch_hash = branch::get_branch_commit_hash("main", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:626:37 [INFO] [stdout] | [INFO] [stdout] 626 | git_merge("main", "branch", &git_dir, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:627:71 [INFO] [stdout] | [INFO] [stdout] 627 | let main_branch_hash = branch::get_branch_commit_hash("main", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:686:48 [INFO] [stdout] | [INFO] [stdout] 686 | let commit_1_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:689:43 [INFO] [stdout] | [INFO] [stdout] 689 | let _ = branch::create_new_branch(&git_dir, branch_name, None, &mut io::stdout()); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:713:36 [INFO] [stdout] | [INFO] [stdout] 713 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:728:36 [INFO] [stdout] | [INFO] [stdout] 728 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:733:24 [INFO] [stdout] | [INFO] [stdout] 733 | .write_all(format!("ref: refs/heads/main").as_bytes()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/main".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: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/merge.rs:768:36 [INFO] [stdout] | [INFO] [stdout] 768 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:770:71 [INFO] [stdout] | [INFO] [stdout] 770 | let main_branch_hash = branch::get_branch_commit_hash("main", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:773:68 [INFO] [stdout] | [INFO] [stdout] 773 | let branch_hash = branch::get_branch_commit_hash("branch", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:785:61 [INFO] [stdout] | [INFO] [stdout] 785 | let merge_commit_hash = git_merge("main", "branch", &git_dir, "").unwrap().0; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:787:71 [INFO] [stdout] | [INFO] [stdout] 787 | let main_branch_hash = branch::get_branch_commit_hash("main", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:858:48 [INFO] [stdout] | [INFO] [stdout] 858 | let commit_1_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:861:43 [INFO] [stdout] | [INFO] [stdout] 861 | let _ = branch::create_new_branch(&git_dir, branch_name, None, &mut io::stdout()); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:884:36 [INFO] [stdout] | [INFO] [stdout] 884 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:900:36 [INFO] [stdout] | [INFO] [stdout] 900 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:905:24 [INFO] [stdout] | [INFO] [stdout] 905 | .write_all(format!("ref: refs/heads/main").as_bytes()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/main".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: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/merge.rs:969:36 [INFO] [stdout] | [INFO] [stdout] 969 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:971:71 [INFO] [stdout] | [INFO] [stdout] 971 | let main_branch_hash = branch::get_branch_commit_hash("main", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:974:68 [INFO] [stdout] | [INFO] [stdout] 974 | let branch_hash = branch::get_branch_commit_hash("branch", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:986:61 [INFO] [stdout] | [INFO] [stdout] 986 | let merge_commit_hash = git_merge("main", "branch", &git_dir, "").unwrap().0; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/merge.rs:988:71 [INFO] [stdout] | [INFO] [stdout] 988 | let main_branch_hash = branch::get_branch_commit_hash("main", &git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if` can be collapsed into the outer `match` [INFO] [stdout] --> src/packfile/delta_utils.rs:301:17 [INFO] [stdout] | [INFO] [stdout] 301 | / if *o1 + *s1 == *o2 { [INFO] [stdout] 302 | | optimized[i] = Command::Copy { [INFO] [stdout] 303 | | offset: *o1, [INFO] [stdout] 304 | | size: *s1 + *s2, [INFO] [stdout] ... | [INFO] [stdout] 308 | | i += 1; [INFO] [stdout] 309 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` on by default [INFO] [stdout] help: collapse nested if block [INFO] [stdout] | [INFO] [stdout] 300 ~ ) [INFO] [stdout] 301 ~ if *o1 + *s1 == *o2 => { [INFO] [stdout] 302 | optimized[i] = Command::Copy { [INFO] [stdout] ... [INFO] [stdout] 305 | }; [INFO] [stdout] 306 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/parse_commands.rs:546:24 [INFO] [stdout] | [INFO] [stdout] 546 | .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Error al obtener el working dir"))?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 546 - .ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Error al obtener el working dir"))?; [INFO] [stdout] 546 + .ok_or_else(|| io::Error::other("Error al obtener el working dir"))?; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/parse_commands.rs:589:13 [INFO] [stdout] | [INFO] [stdout] 589 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 590 | | io::ErrorKind::Other, [INFO] [stdout] 591 | | "Error al abrir el archivo de commit", [INFO] [stdout] 592 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 589 ~ Err(io::Error::other( [INFO] [stdout] 590 ~ "Error al abrir el archivo de commit", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/parse_commands.rs:908:21 [INFO] [stdout] | [INFO] [stdout] 908 | None => Err(io::Error::new( [INFO] [stdout] | _____________________^ [INFO] [stdout] 909 | | io::ErrorKind::Other, [INFO] [stdout] 910 | | "Error al obtener el working dir", [INFO] [stdout] 911 | | )), [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 908 ~ None => Err(io::Error::other( [INFO] [stdout] 909 ~ "Error al obtener el working dir", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/parse_commands.rs:952:5 [INFO] [stdout] | [INFO] [stdout] 952 | /// ('-b', '-B', '--detach', '-f') and the fourth element is the branch or commit to checkout. [INFO] [stdout] | ^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/parse_commands.rs:1051:28 [INFO] [stdout] | [INFO] [stdout] 1051 | let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 1051 - let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] 1051 + let remote_repo_name = url_text.split('/').next_back().unwrap_or(""); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator [INFO] [stdout] --> src/parse_commands.rs:1096:28 [INFO] [stdout] | [INFO] [stdout] 1096 | let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#double_ended_iterator_last [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 1096 - let remote_repo_name = url_text.split('/').last().unwrap_or(""); [INFO] [stdout] 1096 + let remote_repo_name = url_text.split('/').next_back().unwrap_or(""); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/parse_commands.rs:1113:5 [INFO] [stdout] | [INFO] [stdout] 1113 | /// expected to be the name of the branch to be merged. [INFO] [stdout] | ^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item overindented [INFO] [stdout] --> src/parse_commands.rs:1157:5 [INFO] [stdout] | [INFO] [stdout] 1157 | /// representing the 'git remote' subcommand and its options. [INFO] [stdout] | ^^^^^^^^^^^ help: try using ` ` (2 spaces) [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_overindented_list_items [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/parse_commands.rs:1376:5 [INFO] [stdout] | [INFO] [stdout] 1376 | /// the second element is the main command (e.g., "git"), and the third element is the option [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 1376 | /// the second element is the main command (e.g., "git"), and the third element is the option [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/parse_commands.rs:1377:5 [INFO] [stdout] | [INFO] [stdout] 1377 | /// specifying the Git branch operation ("-m", "-d", "-c"). The subsequent elements depend on [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 1377 | /// specifying the Git branch operation ("-m", "-d", "-c"). The subsequent elements depend on [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: doc list item without indentation [INFO] [stdout] --> src/parse_commands.rs:1378:5 [INFO] [stdout] | [INFO] [stdout] 1378 | /// the chosen option. [INFO] [stdout] | ^ [INFO] [stdout] | [INFO] [stdout] = help: if this is supposed to be its own paragraph, add a blank line [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation [INFO] [stdout] help: indent this line [INFO] [stdout] | [INFO] [stdout] 1378 | /// the chosen option. [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/parse_commands.rs:1460:30 [INFO] [stdout] | [INFO] [stdout] 1460 | fn extract_init_params(args: &Vec) -> (String, String, Option<&str>) { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 1460 - fn extract_init_params(args: &Vec) -> (String, String, Option<&str>) { [INFO] [stdout] 1460 + fn extract_init_params(args: &[String]) -> (String, String, Option<&str>) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/pull.rs:71:20 [INFO] [stdout] | [INFO] [stdout] 71 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 72 | | io::ErrorKind::Other, [INFO] [stdout] 73 | | "Error: Could not fetch remote repository\n", [INFO] [stdout] 74 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 71 ~ return Err(io::Error::other( [INFO] [stdout] 72 ~ "Error: Could not fetch remote repository\n", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: used `assert_eq!` with a literal bool [INFO] [stdout] --> src/pull.rs:132:9 [INFO] [stdout] | [INFO] [stdout] 132 | assert_eq!(result.is_ok(), true); [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] 132 - assert_eq!(result.is_ok(), true); [INFO] [stdout] 132 + assert!(result.is_ok()); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: consider using `sort_by_key` [INFO] [stdout] --> src/pull_request.rs:188:9 [INFO] [stdout] | [INFO] [stdout] 188 | prs.sort_by(|a, b| a.pull_number.cmp(&b.pull_number)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_sort_by [INFO] [stdout] = note: `#[warn(clippy::unnecessary_sort_by)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 188 - prs.sort_by(|a, b| a.pull_number.cmp(&b.pull_number)); [INFO] [stdout] 188 + prs.sort_by_key(|a| a.pull_number); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: returning the result of a `let` binding from a block [INFO] [stdout] --> src/pull_request.rs:693:9 [INFO] [stdout] | [INFO] [stdout] 692 | let commit_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ---------------------------------------------------------------------------- unnecessary `let` binding [INFO] [stdout] 693 | commit_hash [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return [INFO] [stdout] = note: `#[warn(clippy::let_and_return)]` on by default [INFO] [stdout] help: return the expression directly [INFO] [stdout] | [INFO] [stdout] 692 ~ [INFO] [stdout] 693 ~ commit::new_commit(&git_dir, commit_message, "").unwrap() [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/pull_request.rs:668:28 [INFO] [stdout] | [INFO] [stdout] 668 | fs::create_dir_all(&git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/pull_request.rs:692:46 [INFO] [stdout] | [INFO] [stdout] 692 | let commit_hash = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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: the borrowed expression implements the required traits [INFO] [stdout] --> src/pull_request.rs:709:44 [INFO] [stdout] | [INFO] [stdout] 709 | let git_dir = Path::new(&dir).join(&repo_name).join(".mgit"); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `repo_name` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/pull_request.rs:784:19 [INFO] [stdout] | [INFO] [stdout] 784 | repo.dump(&dir)?; [INFO] [stdout] | ^^^^ help: change this to: `dir` [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/pull_request.rs:787:49 [INFO] [stdout] | [INFO] [stdout] 787 | let result = repo.merge_pull_request(1, &dir, ".mgit"); [INFO] [stdout] | ^^^^ help: change this to: `dir` [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/pull_request.rs:799:25 [INFO] [stdout] | [INFO] [stdout] 799 | let repo_path = format!("tests/pull_request/server/merge"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"tests/pull_request/server/merge".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: the borrowed expression implements the required traits [INFO] [stdout] --> src/pull_request.rs:818:44 [INFO] [stdout] | [INFO] [stdout] 818 | let git_dir = Path::new(&dir).join(&repo_name).join(".mgit"); [INFO] [stdout] | ^^^^^^^^^^ help: change this to: `repo_name` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/pull_request.rs:856:24 [INFO] [stdout] | [INFO] [stdout] 856 | .write_all(format!("ref: refs/heads/main").as_bytes()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/main".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: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/pull_request.rs:884:19 [INFO] [stdout] | [INFO] [stdout] 884 | repo.dump(&dir)?; [INFO] [stdout] | ^^^^ help: change this to: `dir` [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/pull_request.rs:887:49 [INFO] [stdout] | [INFO] [stdout] 887 | let result = repo.merge_pull_request(1, &dir, ".mgit"); [INFO] [stdout] | ^^^^ help: change this to: `dir` [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/pull_request.rs:891:25 [INFO] [stdout] | [INFO] [stdout] 891 | let repo_path = format!("tests/pull_request/server/merge_conflicts"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"tests/pull_request/server/merge_conflicts".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: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:674:9 [INFO] [stdout] | [INFO] [stdout] 674 | Err(io::Error::new( [INFO] [stdout] | _________^ [INFO] [stdout] 675 | | io::ErrorKind::Other, [INFO] [stdout] 676 | | "No hay más commits para rebase", [INFO] [stdout] 677 | | )) [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 674 ~ Err(io::Error::other( [INFO] [stdout] 675 ~ "No hay más commits para rebase", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:834:24 [INFO] [stdout] | [INFO] [stdout] 834 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 835 | | io::ErrorKind::Other, [INFO] [stdout] 836 | | "No hay commits con los que hacer rebase", [INFO] [stdout] 837 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 834 ~ return Err(io::Error::other( [INFO] [stdout] 835 ~ "No hay commits con los que hacer rebase", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:851:20 [INFO] [stdout] | [INFO] [stdout] 851 | return Err(io::Error::new( [INFO] [stdout] | ____________________^ [INFO] [stdout] 852 | | io::ErrorKind::Other, [INFO] [stdout] 853 | | "No hay conflictos, se hizo un fast forward rebase", [INFO] [stdout] 854 | | )); [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 851 ~ return Err(io::Error::other( [INFO] [stdout] 852 ~ "No hay conflictos, se hizo un fast forward rebase", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/rebase.rs:889:13 [INFO] [stdout] | [INFO] [stdout] 889 | Err(io::Error::new( [INFO] [stdout] | _____________^ [INFO] [stdout] 890 | | io::ErrorKind::Other, [INFO] [stdout] 891 | | "El rebase no es fast forward, por favor use la interfaz gráfica", [INFO] [stdout] 892 | | )) [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 889 ~ Err(io::Error::other( [INFO] [stdout] 890 ~ "El rebase no es fast forward, por favor use la interfaz gráfica", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/rebase.rs:906:28 [INFO] [stdout] | [INFO] [stdout] 906 | fs::create_dir_all(&git_dir).unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> src/rebase.rs:932:9 [INFO] [stdout] | [INFO] [stdout] 932 | let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 932 - let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] 932 + fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/rebase.rs:943:43 [INFO] [stdout] | [INFO] [stdout] 943 | let _ = branch::create_new_branch(&git_dir, "test", None, &mut io::stdout()); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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 let-binding has unit value [INFO] [stdout] --> src/rebase.rs:954:9 [INFO] [stdout] | [INFO] [stdout] 954 | let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 954 - let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] 954 + fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/rebase.rs:958:36 [INFO] [stdout] | [INFO] [stdout] 958 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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 let-binding has unit value [INFO] [stdout] --> src/rebase.rs:963:9 [INFO] [stdout] | [INFO] [stdout] 963 | let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 963 - let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] 963 + fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/rebase.rs:967:36 [INFO] [stdout] | [INFO] [stdout] 967 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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 let-binding has unit value [INFO] [stdout] --> src/rebase.rs:976:9 [INFO] [stdout] | [INFO] [stdout] 976 | let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 976 - let _ = fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] 976 + fs::write(format!("{}/{}", test_dir, file_path), file_content).unwrap(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/rebase.rs:980:36 [INFO] [stdout] | [INFO] [stdout] 980 | let _ = commit::new_commit(&git_dir, commit_message, "").unwrap(); [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/rebase.rs:985:24 [INFO] [stdout] | [INFO] [stdout] 985 | .write_all(format!("ref: refs/heads/test").as_bytes()) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"ref: refs/heads/test".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: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:112:11 [INFO] [stdout] | [INFO] [stdout] 112 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 112 - line: &Vec<&str>, [INFO] [stdout] 112 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:141:11 [INFO] [stdout] | [INFO] [stdout] 141 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 141 - line: &Vec<&str>, [INFO] [stdout] 141 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:169:11 [INFO] [stdout] | [INFO] [stdout] 169 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 169 - line: &Vec<&str>, [INFO] [stdout] 169 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:197:11 [INFO] [stdout] | [INFO] [stdout] 197 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 197 - line: &Vec<&str>, [INFO] [stdout] 197 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do [INFO] [stdout] --> src/remote.rs:227:11 [INFO] [stdout] | [INFO] [stdout] 227 | line: &Vec<&str>, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg [INFO] [stdout] help: change this to [INFO] [stdout] | [INFO] [stdout] 227 - line: &Vec<&str>, [INFO] [stdout] 227 + line: &[&str], [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> src/remote.rs:339:27 [INFO] [stdout] | [INFO] [stdout] 339 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:362:27 [INFO] [stdout] | [INFO] [stdout] 362 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:385:27 [INFO] [stdout] | [INFO] [stdout] 385 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:406:27 [INFO] [stdout] | [INFO] [stdout] 406 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:426:27 [INFO] [stdout] | [INFO] [stdout] 426 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:446:27 [INFO] [stdout] | [INFO] [stdout] 446 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:466:27 [INFO] [stdout] | [INFO] [stdout] 466 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:486:27 [INFO] [stdout] | [INFO] [stdout] 486 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:506:27 [INFO] [stdout] | [INFO] [stdout] 506 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:526:27 [INFO] [stdout] | [INFO] [stdout] 526 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:551:27 [INFO] [stdout] | [INFO] [stdout] 551 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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/remote.rs:576:27 [INFO] [stdout] | [INFO] [stdout] 576 | ...data = format!("[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n"); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"[core]\n\trepositoryformatversion = 0\n\tfilemode = true\n\tbare = false\n\tlogallrefupdates = true\n".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: this boolean expression can be simplified [INFO] [stdout] --> src/rm.rs:195:17 [INFO] [stdout] | [INFO] [stdout] 195 | assert!(!fs::metadata(file_name).is_ok()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `fs::metadata(file_name).is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/rm.rs:276:17 [INFO] [stdout] | [INFO] [stdout] 276 | assert!(!fs::metadata(dir_path).is_ok()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `fs::metadata(dir_path).is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/rm.rs:277:17 [INFO] [stdout] | [INFO] [stdout] 277 | assert!(!fs::metadata(&file_path).is_ok()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `fs::metadata(&file_path).is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/server_utils.rs:44:20 [INFO] [stdout] | [INFO] [stdout] 44 | return Err(Error::new(io::ErrorKind::Other, format!("Error: {}", line))); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 44 - return Err(Error::new(io::ErrorKind::Other, format!("Error: {}", line))); [INFO] [stdout] 44 + return Err(Error::other(format!("Error: {}", line))); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> src/server_utils.rs:346:35 [INFO] [stdout] | [INFO] [stdout] 346 | assert!(refs.contains_key(&"master".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `"master"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] = note: `#[warn(clippy::unnecessary_to_owned)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> src/server_utils.rs:352:35 [INFO] [stdout] | [INFO] [stdout] 352 | assert!(refs.contains_key(&"v1.0".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: replace it with: `"v1.0"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> src/server_utils.rs:359:35 [INFO] [stdout] | [INFO] [stdout] 359 | assert!(refs.contains_key(&"master".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `"master"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> src/server_utils.rs:366:35 [INFO] [stdout] | [INFO] [stdout] 366 | assert!(refs.contains_key(&"master".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `"master"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> src/server_utils.rs:367:35 [INFO] [stdout] | [INFO] [stdout] 367 | assert!(refs.contains_key(&"v1.0".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: replace it with: `"v1.0"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> src/server_utils.rs:374:35 [INFO] [stdout] | [INFO] [stdout] 374 | assert!(refs.contains_key(&"master".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `"master"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `to_string` [INFO] [stdout] --> src/server_utils.rs:375:35 [INFO] [stdout] | [INFO] [stdout] 375 | assert!(refs.contains_key(&"v1.0".to_string())); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: replace it with: `"v1.0"` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/status.rs:304:42 [INFO] [stdout] | [INFO] [stdout] 304 | changes_to_be_committed_for_test(&git_dir, true, &mut output)?; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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: called `unwrap` on `result` after checking its variant with `is_ok` [INFO] [stdout] --> src/status.rs:328:29 [INFO] [stdout] | [INFO] [stdout] 327 | if result.is_ok() { [INFO] [stdout] | ----------------- help: try: `if let Ok() = result` [INFO] [stdout] 328 | let resultado = result.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: equality checks against true are unnecessary [INFO] [stdout] --> src/status.rs:350:12 [INFO] [stdout] | [INFO] [stdout] 350 | if commit == true { [INFO] [stdout] | ^^^^^^^^^^^^^^ help: try: `commit` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/status.rs:381:33 [INFO] [stdout] | [INFO] [stdout] 381 | let index = Index::load(&index_file_path, &git_dir, &git_ignore_path)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `index_file_path` [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/status.rs:381:51 [INFO] [stdout] | [INFO] [stdout] 381 | let index = Index::load(&index_file_path, &git_dir, &git_ignore_path)?; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/status.rs:381:61 [INFO] [stdout] | [INFO] [stdout] 381 | let index = Index::load(&index_file_path, &git_dir, &git_ignore_path)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `git_ignore_path` [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/status.rs:383:39 [INFO] [stdout] | [INFO] [stdout] 383 | find_unstaged_changes(&index, &working_dir, &mut output)?; [INFO] [stdout] | ^^^^^^^^^^^^ help: change this to: `working_dir` [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/status.rs:434:33 [INFO] [stdout] | [INFO] [stdout] 434 | let index = Index::load(&index_file_path, &git_dir, &git_ignore_path)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `index_file_path` [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/status.rs:434:51 [INFO] [stdout] | [INFO] [stdout] 434 | let index = Index::load(&index_file_path, &git_dir, &git_ignore_path)?; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/status.rs:434:61 [INFO] [stdout] | [INFO] [stdout] 434 | let index = Index::load(&index_file_path, &git_dir, &git_ignore_path)?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `git_ignore_path` [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/status.rs:436:39 [INFO] [stdout] | [INFO] [stdout] 436 | find_unstaged_changes(&index, &git_dir, &mut output)?; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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: called `unwrap` on `resultado` after checking its variant with `is_ok` [INFO] [stdout] --> src/status.rs:460:26 [INFO] [stdout] | [INFO] [stdout] 459 | if resultado.is_ok() { [INFO] [stdout] | -------------------- help: try: `if let Ok() = resultado` [INFO] [stdout] 460 | let string = resultado.unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/status.rs:450:13 [INFO] [stdout] | [INFO] [stdout] 450 | &index_file_path, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `index_file_path` [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: unnecessary use of `to_string` [INFO] [stdout] --> src/status.rs:451:13 [INFO] [stdout] | [INFO] [stdout] 451 | &git_dir.to_string_lossy().to_string(), [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `git_dir.to_string_lossy().as_ref()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/status.rs:452:13 [INFO] [stdout] | [INFO] [stdout] 452 | &git_ignore_path, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `git_ignore_path` [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/status.rs:456:30 [INFO] [stdout] | [INFO] [stdout] 456 | find_untracked_files(&git_dir, &git_dir, &index, &mut output)?; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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/status.rs:456:40 [INFO] [stdout] | [INFO] [stdout] 456 | find_untracked_files(&git_dir, &git_dir, &index, &mut output)?; [INFO] [stdout] | ^^^^^^^^ help: change this to: `git_dir` [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: called `unwrap_err` on `result` after checking its variant with `is_err` [INFO] [stdout] --> src/tag.rs:140:42 [INFO] [stdout] | [INFO] [stdout] 139 | if result.is_err() { [INFO] [stdout] | ------------------ help: try: `if let Err() = result` [INFO] [stdout] 140 | output.write_all(format!("{:?}", result.unwrap_err()).as_bytes())?; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_unwrap [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `match` expression can be replaced with `?` [INFO] [stdout] --> src/tree_handler.rs:160:25 [INFO] [stdout] | [INFO] [stdout] 160 | let file_name = match path.pop() { [INFO] [stdout] | _________________________^ [INFO] [stdout] 161 | | Some(file_name) => file_name, [INFO] [stdout] 162 | | None => return None, [INFO] [stdout] 163 | | }; [INFO] [stdout] | |_________^ help: try instead: `path.pop()?` [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: this `match` expression can be replaced with `?` [INFO] [stdout] --> src/tree_handler.rs:166:28 [INFO] [stdout] | [INFO] [stdout] 166 | current_tree = match current_tree.get_subdir(path.remove(0)) { [INFO] [stdout] | ____________________________^ [INFO] [stdout] 167 | | Some(tree) => tree, [INFO] [stdout] 168 | | None => return None, [INFO] [stdout] 169 | | }; [INFO] [stdout] | |_____________^ help: try instead: `current_tree.get_subdir(path.remove(0))?` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/utils.rs:26:24 [INFO] [stdout] | [INFO] [stdout] 26 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 27 | | io::ErrorKind::Other, [INFO] [stdout] 28 | | "Error obtaining actual directory", [INFO] [stdout] 29 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 26 ~ return Err(io::Error::other( [INFO] [stdout] 27 ~ "Error obtaining actual directory", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/utils.rs:37:24 [INFO] [stdout] | [INFO] [stdout] 37 | return Err(io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 38 | | io::ErrorKind::Other, [INFO] [stdout] 39 | | "Error obtaining git dir", [INFO] [stdout] 40 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 37 ~ return Err(io::Error::other( [INFO] [stdout] 38 ~ "Error obtaining git dir", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/utils.rs:325:12 [INFO] [stdout] | [INFO] [stdout] 325 | if !fs::metadata("tests/utils/parents2").is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `fs::metadata("tests/utils/parents2").is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: calls to `push` immediately after creation [INFO] [stdout] --> src/utils.rs:349:9 [INFO] [stdout] | [INFO] [stdout] 349 | / let mut expected_parents = Vec::new(); [INFO] [stdout] 350 | | expected_parents.push(result.clone()); [INFO] [stdout] 351 | | expected_parents.push("0894f78e615131459e43d258070b5540081f1d82".to_string()); [INFO] [stdout] | |______________________________________________________________________________________^ help: consider using the `vec![]` macro: `let expected_parents = vec![..];` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#vec_init_then_push [INFO] [stdout] = note: `#[warn(clippy::vec_init_then_push)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/utils.rs:362:12 [INFO] [stdout] | [INFO] [stdout] 362 | if !fs::metadata("tests/utils/parents3").is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `fs::metadata("tests/utils/parents3").is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this let-binding has unit value [INFO] [stdout] --> src/utils.rs:384:9 [INFO] [stdout] | [INFO] [stdout] 384 | let _ = fs::create_dir_all("tests/utils/parents3/objects").unwrap(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value [INFO] [stdout] help: omit the `let` binding [INFO] [stdout] | [INFO] [stdout] 384 - let _ = fs::create_dir_all("tests/utils/parents3/objects").unwrap(); [INFO] [stdout] 384 + fs::create_dir_all("tests/utils/parents3/objects").unwrap(); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: calls to `push` immediately after creation [INFO] [stdout] --> src/utils.rs:403:9 [INFO] [stdout] | [INFO] [stdout] 403 | / let mut expected_parents = Vec::new(); [INFO] [stdout] 404 | | expected_parents.push(commit_3_hash.clone()); [INFO] [stdout] 405 | | expected_parents.push(commit_2_hash); [INFO] [stdout] 406 | | expected_parents.push(commit_1_hash); [INFO] [stdout] 407 | | expected_parents.push("a4a7dce85cf63874e984719f4fdd239f5145052e".to_string()); [INFO] [stdout] | |______________________________________________________________________________________^ help: consider using the `vec![]` macro: `let expected_parents = vec![..];` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#vec_init_then_push [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: hiding a lifetime that's elided elsewhere is confusing [INFO] [stdout] --> src/index.rs:233:17 [INFO] [stdout] | [INFO] [stdout] 233 | pub fn iter(&self) -> std::collections::hash_map::Iter { [INFO] [stdout] | ^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the same lifetime is hidden here [INFO] [stdout] | | [INFO] [stdout] | the lifetime is elided here [INFO] [stdout] | [INFO] [stdout] = help: the same lifetime is referred to in inconsistent ways, making the signature confusing [INFO] [stdout] = note: `#[warn(mismatched_lifetime_syntaxes)]` on by default [INFO] [stdout] help: use `'_` for type paths [INFO] [stdout] | [INFO] [stdout] 233 | pub fn iter(&self) -> std::collections::hash_map::Iter<'_, String, String> { [INFO] [stdout] | +++ [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 57.55s [INFO] running `Command { std: "docker" "inspect" "33d90adf4fc6cf8b87ee8c22da6436947d43215cf549bdc01100dd228e0e3951", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "33d90adf4fc6cf8b87ee8c22da6436947d43215cf549bdc01100dd228e0e3951", kill_on_drop: false }` [INFO] [stdout] 33d90adf4fc6cf8b87ee8c22da6436947d43215cf549bdc01100dd228e0e3951