1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 19:47:45 +00:00

rm: make the remove function public

This commit is contained in:
KAA the Wise 2023-09-22 19:17:51 +03:00
parent 75044c1bc4
commit 20fb473da8

View file

@ -279,7 +279,13 @@ pub fn uu_app() -> Command {
} }
// TODO: implement one-file-system (this may get partially implemented in walkdir) // TODO: implement one-file-system (this may get partially implemented in walkdir)
fn remove(files: &[&OsStr], options: &Options) -> bool { /// Remove (or unlink) the given files
///
/// Returns true if it has encountered an error.
///
/// Behavior is determined by the `options` parameter, see [`Options`] for
/// details.
pub fn remove(files: &[&OsStr], options: &Options) -> bool {
let mut had_err = false; let mut had_err = false;
for filename in files { for filename in files {