Skip to content

Commit 8bd1691

Browse files
committed
apease clippy some more
1 parent 5ede8ba commit 8bd1691

File tree

5 files changed

+11
-11
lines changed

5 files changed

+11
-11
lines changed

src/cmd/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -508,7 +508,7 @@ impl<'w, 'pl> Command<'w, 'pl> {
508508
}
509509

510510
if self.log_command {
511-
info!("running `{}`", cmdstr);
511+
info!("running `{cmdstr}`");
512512
}
513513

514514
let out = RUNTIME
@@ -521,7 +521,7 @@ impl<'w, 'pl> Command<'w, 'pl> {
521521
self.log_output,
522522
))
523523
.map_err(|e| {
524-
error!("error running command: {}", e);
524+
error!("error running command: {e}");
525525
e
526526
})?;
527527

src/cmd/sandbox.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ impl SandboxImage {
2929
/// error will be returned instead.
3030
pub fn remote(name: &str) -> Result<Self, CommandError> {
3131
let mut image = SandboxImage { name: name.into() };
32-
info!("pulling image {} from Docker Hub", name);
32+
info!("pulling image {name} from Docker Hub");
3333
Command::new_workspaceless("docker")
3434
.args(&["pull", name])
3535
.run()
@@ -308,10 +308,10 @@ impl SandboxBuilder {
308308
scopeguard::defer! {{
309309
if let Err(err) = container.delete() {
310310
error!("failed to delete container {}", container.id);
311-
error!("caused by: {}", err);
311+
error!("caused by: {err}");
312312
let mut err: &dyn Error = &err;
313313
while let Some(cause) = err.source() {
314-
error!("caused by: {}", cause);
314+
error!("caused by: {cause}");
315315
err = cause;
316316
}
317317
}

src/inside_docker.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ pub(crate) fn probe_container_id(workspace: &Workspace) -> anyhow::Result<Option
6262
.log_command(false)
6363
.run_capture()?;
6464
for id in out.stdout_lines() {
65-
info!("probing container id {}", id);
65+
info!("probing container id {id}");
6666

6767
let res = Command::new(workspace, "docker")
6868
.args(&["exec", id, "cat", probe_path_str])
@@ -71,7 +71,7 @@ pub(crate) fn probe_container_id(workspace: &Workspace) -> anyhow::Result<Option
7171
.run_capture();
7272
if let Ok([probed]) = res.as_ref().map(|out| out.stdout_lines()) {
7373
if *probed == probe_content {
74-
info!("probe successful, this is container ID {}", id);
74+
info!("probe successful, this is container ID {id}");
7575
return Ok(Some(id.clone()));
7676
}
7777
}

src/prepare.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ impl<'a> TomlTweaker<'a> {
268268
// Eliminate parent workspaces
269269
if let Some(&mut Value::Table(ref mut package)) = self.table.get_mut("package") {
270270
if package.remove("workspace").is_some() {
271-
info!("removed parent workspace from {}", krate);
271+
info!("removed parent workspace from {krate}");
272272
}
273273
}
274274
}
@@ -295,15 +295,15 @@ impl<'a> TomlTweaker<'a> {
295295

296296
// Strip the 'publish-lockfile' key from [package]
297297
if has_publish_lockfile {
298-
info!("disabled cargo feature 'publish-lockfile' from {}", krate);
298+
info!("disabled cargo feature 'publish-lockfile' from {krate}");
299299
if let Some(&mut Value::Table(ref mut package)) = self.table.get_mut("package") {
300300
package.remove("publish-lockfile");
301301
}
302302
}
303303

304304
// Strip the 'default-run' key from [package]
305305
if has_default_run {
306-
info!("disabled cargo feature 'default-run' from {}", krate);
306+
info!("disabled cargo feature 'default-run' from {krate}");
307307
if let Some(&mut Value::Table(ref mut package)) = self.table.get_mut("package") {
308308
package.remove("default-run");
309309
}

src/utils.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ pub(crate) fn file_lock<T>(
3535
let mut message_displayed = false;
3636
while let Err(err) = file.try_lock_exclusive() {
3737
if !message_displayed && err.kind() == fs2::lock_contended_error().kind() {
38-
warn!("blocking on other processes finishing to {}", msg);
38+
warn!("blocking on other processes finishing to {msg}");
3939
message_displayed = true;
4040
}
4141
file.lock_exclusive()?;

0 commit comments

Comments
 (0)