Users often find rm (and even rm –i) too unforgiving because this utility removes files irrevocably. Create an alias named delete that moves files specified by its argument(s) into the ~/.trash directory. Create a second alias named undelete that moves a file from the ~/.trash directory into the working directory. Put the following line in your ~/.logout file to remove any files that you deleted during the login session:

/bin/rm -f $HOME/.trash/* >& /dev/null


These commands create the required aliases:
$ alias delete mv \!:\* ~/.trash
$ alias undelete mv ~/.trash/\!:1

Computer Science & Information Technology

You might also like to view...

A(n) ________ appears next to a linked table name in the Navigation Pane

A) arrow B) star C) pound sign D) ampersand

Computer Science & Information Technology

By convention, Cascading Style Sheet files are always given a(n) ____ extension so that Web developers can immediately recognize them as Cascading Style Sheets.

A. .cs B. .css C. .shtml D. .shtm

Computer Science & Information Technology

Choose the correctly capitalized sentence.?

A. ?Cayla will fly to San Diego to meet her aunt Tess. B. ?Cayla will fly to San Diego to meet her Aunt Tess.

Computer Science & Information Technology

____ constructs scenarios of the types of threats that assets can face.

A. Asset management B. Vulnerability identification C. Threat modeling D. Asset identification

Computer Science & Information Technology