1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages/common/rm.md

25 lines
616 B
Markdown
Raw Normal View History

# rm
> Remove files or directories.
> More information: <https://www.gnu.org/software/coreutils/rm>.
- Remove files from arbitrary locations:
`rm {{path/to/file}} {{path/to/another/file}}`
- Recursively remove a directory and all its subdirectories:
`rm -r {{path/to/directory}}`
- Forcibly remove a directory, without prompting for confirmation or showing error messages:
2016-01-14 21:43:17 +08:00
`rm -rf {{path/to/directory}}`
2016-01-14 21:43:17 +08:00
- Interactively remove multiple files, with a prompt before every removal:
`rm -i {{file(s)}}`
- Remove files in verbose mode, printing a message for each removed file:
`rm -v {{path/to/directory/*}}`