Skip to content

Commit

Permalink
chore: clippy::literal_string_with_formatting_args
Browse files Browse the repository at this point in the history
interesting... it turns out we need both lint allows:

```
#[allow(clippy::to_string_in_format_args)]
#[allow(clippy::literal_string_with_formatting_args)]
```
  • Loading branch information
jqnatividad committed Jan 30, 2025
1 parent a548a3d commit 60627a7
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/cmd/describegpt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,7 @@ fn get_prompt(
};
// Replace variable data in prompt
#[allow(clippy::to_string_in_format_args)]
#[allow(clippy::literal_string_with_formatting_args)]
let prompt = prompt
.replace("{stats}", stats.unwrap_or(""))
.replace("{frequency}", frequency.unwrap_or(""))
Expand Down
1 change: 1 addition & 0 deletions src/cmd/sniff.rs
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,7 @@ async fn get_file_to_sniff(args: &Args, tmpdir: &tempfile::TempDir) -> CliResult
if show_progress {
progress.set_style(
#[allow(clippy::to_string_in_format_args)]
#[allow(clippy::literal_string_with_formatting_args)]
ProgressStyle::default_bar()
.template(
"{msg}\n{spinner:.green} [{elapsed_precise}] \
Expand Down
1 change: 1 addition & 0 deletions src/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1545,6 +1545,7 @@ pub async fn download_file(
if show_progress {
pb.set_style(
#[allow(clippy::to_string_in_format_args)]
#[allow(clippy::literal_string_with_formatting_args)]
ProgressStyle::default_bar()
.template(if total_size == u64::MAX {
// only do a spinner if we don't know the total size
Expand Down

0 comments on commit 60627a7

Please sign in to comment.