Sometimes unwittingly we may delete
some important files and realise it
later. To avoid such a situation,
you can use this following idea.
Create a small bash script containing
mv $1 ~/trash/
Save this file in your home say
".srm" (safe rm) and in your
".bashrc" enter this line:
Now whenever you delete any files
it will go to "trash" directory
instead of deletion. You will
have to create a "trash" directory
in your home directory.