commit 1bae669f236b9612eacd64554cfb39733157ef43
parent 61b58e3c2731966a8fa4d60e33a724a27e722f76
Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date: Mon, 3 Nov 2025 18:52:11 +0100
rm: fix confirmation for deleting files and add question mark
Answering 'y' to rm -i will now delete the file.
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libutil/rm.c b/libutil/rm.c
@@ -28,7 +28,7 @@ rm(int dirfd, const char *name, struct stat *st, void *data, struct recursor *r)
}
if (!quiet && (!write && isatty(0) || ask)) {
- if (!confirm("remove file '%s'", r->path));
+ if (!confirm("remove file '%s'? ", r->path))
return;
}