Skip to content

Commit bf10e34

Browse files
committed
lints: use PathQuotedDisplay for tmpfiles
This is more readable. Signed-off-by: Colin Walters <walters@verbum.org>
1 parent aa635b3 commit bf10e34

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/src/lints.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ use std::fmt::Write as WriteFmt;
1111
use std::os::unix::ffi::OsStrExt;
1212

1313
use anyhow::Result;
14+
use bootc_utils::PathQuotedDisplay;
1415
use camino::{Utf8Path, Utf8PathBuf};
1516
use cap_std::fs::Dir;
1617
use cap_std_ext::cap_std;
@@ -505,8 +506,8 @@ fn check_var_tmpfiles(_root: &Dir) -> LintResult {
505506
bootc_utils::iterator_split_nonempty_rest_count(r.unsupported.iter(), 5)
506507
{
507508
msg.push_str("Found non-directory/non-symlink files in /var:\n");
508-
for elt in samples {
509-
writeln!(msg, " {elt:?}")?;
509+
for elt in samples.map(PathQuotedDisplay::new) {
510+
writeln!(msg, " {elt}")?;
510511
}
511512
if rest > 0 {
512513
writeln!(msg, " ...and {} more", rest)?;

0 commit comments

Comments
 (0)