RM(1) | User Commands | RM(1) |
rm - remove directory entries
rm [-fiRr] file ...
Rm removes the entries for one or more files from a directory. If an entry was the last link to the file, the file is destroyed. Removal of a file requires write permission in its directory, but neither read nor write permission on the file itself.
If a file has no write permission and the standard input is a terminal, its permissions are printed and a line is read from the standard input. If that line begins with `y' the file is deleted, otherwise the file remains.
When rm encounters a symbolic link, the link will be removed, but its target will remain in the file hierarchy.
The rm command accepts the following options:
rmdir(1), unlink(2), rmdir(2)
It is forbidden to remove the files `.' and `..' merely to avoid the antisocial consequences of inadvertently doing something like `rm -r .*'.
With /usr/5bin/rm and /usr/5bin/s42/rm, a single `-' can be used to indicate the end of the options list, as with `rm - -file'. If `--' is used to terminate the options list, though, a following `-' will be interpreted as a file name, so `rm -- -' will remove the file `-'.
1/24/05 | Heirloom Toolchest |