From 055b3f63be443125f29acb446417cf8a0cfae324 Mon Sep 17 00:00:00 2001 From: pxgamer Date: Tue, 28 Aug 2018 10:23:45 +0100 Subject: [PATCH] forfiles: add page --- pages/windows/forfiles.md | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 pages/windows/forfiles.md diff --git a/pages/windows/forfiles.md b/pages/windows/forfiles.md new file mode 100644 index 0000000000..f973ebab4c --- /dev/null +++ b/pages/windows/forfiles.md @@ -0,0 +1,27 @@ +# forfiles + +> Select one or more files to execute a specified command on. + +- Search for files in the current directory: + +`forfiles` + +- Search for files in a specific directory: + +`forfiles /p {{path/to/directory}}` + +- Run the specified command for each file: + +`forfiles /c "{{command}}"` + +- Search for files using a specific glob mask: + +`forfiles /m {{glob_pattern}}` + +- Search for files recursively: + +`forfiles /s` + +- Search for files with a last-modified date greater than 5 days old: + +`forfiles /d {{+5}}`