safely delete

Jeffrey F. Bloss jbloss at tampabay.rr.com
Wed Jan 10 20:14:32 UTC 2007


Bram Kuijper wrote:

> Hi all,
> 
> I know this is a beginner question, but is there any equivalent to
> the rm command so that files are not getting deleted, but just moved
> to a thrash can?
> 
> Searching for it in Google helped me find a number of shell scripts
> more or less achieving this, but I wonder if there is any package
> that does the same?

The trashcan is just another directory. No need for a fancy shell script
I'd think, just replace 'rm' with 'mv' on the command line and append
the destination. Something like 'mv <files> ~/.Trash' should suffice.

-- 
     _?_      Outside of a dog, a book is a man's best friend.
    (o o)         Inside of a dog, it's too dark to read.
-oOO-(_)--OOo-------------------------------[ Groucho Marx ]--
    grok!              Registered Linux user #402208
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 892 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20070110/f3a47cfa/attachment.sig>


More information about the ubuntu-users mailing list