Kolam Ayer MakersLinux Foundations

Command: rm

Use

rm ~/playground/old.txt
rm -i ~/playground/old.txt

What It Does

rm removes directory entries. For ordinary files, that means the filename disappears from the directory.

Safe Forms

Prompt before removing:

rm -i file.txt

rm -rf means recursive and force. It can remove a whole directory tree without prompting, so understand it but do not run it in S2.

Watch Out

Docs Pointers