Update Rust crate anyhow to 1.0.79 - autoclosed #526
Annotations
1 error and 17 warnings
cargo_bloat
Request failed with status code 404
|
the borrowed expression implements the required traits:
src/main.rs#L158
warning: the borrowed expression implements the required traits
--> src/main.rs:158:43
|
158 | history::history(config_path, &hist_path, sub_m.is_present("yes"))
| ^^^^^^^^^^ help: change this to: `hist_path`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args
|
deref on an immutable reference:
src/repo.rs#L154
warning: deref on an immutable reference
--> src/repo.rs:154:37
|
154 | git::commit_all(&self.path, &*commit_msg, false)?;
| ^^^^^^^^^^^^ help: if you would like to reborrow, try removing `&*`: `commit_msg`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrow_deref_ref
= note: `#[warn(clippy::borrow_deref_ref)]` on by default
|
deref which would be done by auto-deref:
src/repo.rs#L153
warning: deref which would be done by auto-deref
--> src/repo.rs:153:35
|
153 | git::add_file(&self.path, &*self.config.repo.file)?;
| ^^^^^^^^^^^^^^^^^^^^^^^ help: try: `&self.config.repo.file`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
|
the borrowed expression implements the required traits:
src/repo.rs#L149
warning: the borrowed expression implements the required traits
--> src/repo.rs:149:19
|
149 | fs::write(&full_path, toml_string)?;
| ^^^^^^^^^^ help: change this to: `full_path`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args
|
deref which would be done by auto-deref:
src/repo.rs#L136
warning: deref which would be done by auto-deref
--> src/repo.rs:136:37
|
136 | git::commit_all(&self.path, &*commit_msg, false)?;
| ^^^^^^^^^^^^ help: try: `&commit_msg`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
|
deref which would be done by auto-deref:
src/repo.rs#L127
warning: deref which would be done by auto-deref
--> src/repo.rs:127:35
|
127 | git::add_file(&self.path, &*self.config.repo.file)?;
| ^^^^^^^^^^^^^^^^^^^^^^^ help: try: `&self.config.repo.file`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
|
the borrowed expression implements the required traits:
src/repo.rs#L84
warning: the borrowed expression implements the required traits
--> src/repo.rs:84:35
|
84 | let mut file = File::open(&self.config.full_file_path())
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `self.config.full_file_path()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args
= note: `#[warn(clippy::needless_borrows_for_generic_args)]` on by default
|
deref which would be done by auto-deref:
src/repo.rs#L47
warning: deref which would be done by auto-deref
--> src/repo.rs:47:57
|
47 | git::clone_single_branch(&path, &*repo_url, &*repo_branch)
| ^^^^^^^^^^^^^ help: try: `&repo_branch`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
|
deref which would be done by auto-deref:
src/repo.rs#L47
warning: deref which would be done by auto-deref
--> src/repo.rs:47:45
|
47 | git::clone_single_branch(&path, &*repo_url, &*repo_branch)
| ^^^^^^^^^^ help: try: `&repo_url`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
= note: `#[warn(clippy::explicit_auto_deref)]` on by default
|
this expression can be written more simply using `.retain()`:
src/package.rs#L159
warning: this expression can be written more simply using `.retain()`
--> src/package.rs:159:9
|
159 | / self.0 = self
160 | | .0
161 | | .iter()
162 | | .filter(|package| !old.iter().any(|old_package| *package == old_package))
163 | | .cloned()
164 | | .collect();
| |______________________^ help: consider calling `.retain()` instead: `self.0.retain(|package| !old.iter().any(|old_package| *package == old_package))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_retain
= note: `#[warn(clippy::manual_retain)]` on by default
|
`filter_map()` will run forever if the iterator repeatedly produces an `Err`:
src/history.rs#L103
warning: `filter_map()` will run forever if the iterator repeatedly produces an `Err`
--> src/history.rs:103:10
|
103 | .filter_map(|x| x.ok())
| ^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `map_while(Result::ok)`
|
note: this expression returning a `std::io::Lines` may produce an infinite number of `Err` in case of a read error
--> src/history.rs:102:5
|
102 | lines
| ^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#lines_filter_map_ok
= note: `#[warn(clippy::lines_filter_map_ok)]` on by default
|
`Box::new(_)` of default value:
src/config.rs#L78
warning: `Box::new(_)` of default value
--> src/config.rs:78:13
|
78 | Box::new(dialoguer::theme::ColorfulTheme::default())
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Box::<ColorfulTheme>::default()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#box_default
= note: `#[warn(clippy::box_default)]` on by default
|
cargo_bloat
The following actions uses node12 which is deprecated and will be forced to run on node16: actions-rs/[email protected], orf/[email protected]. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
|
cargo_bloat
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|
cargo_bloat
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|
cargo_bloat
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|
cargo_bloat
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|