That's where the Trash Can comes in handy, a temporary location that allows a permanent removal at a latter time.
I'm using Gnome and the location of the Trash is :
It contains two directories : files and info. The files folder contains the files deleted and the info directory consists of meta data for each deleted file.
Showing the Trash Can icon on the Desktop is done by going to :
Menu > Applications > System Tools > Configuration Editor.
Just check the Key name /apps/nautilus/desktop/trash_icon_visible.
Trash-cli manages the Trash in command line which is equivalent to Trash functionalities in Nautilus file browser.
There is no package in Squeeze, but you can install package trash-cli (0.1.10.28-2) from Sid without any problem.
I've tested it by issuing the command :
list-trash to list the files in the Trash Can :
It spits out errors :
Traceback (most recent call last): File "/usr/bin/list-trash", line 5, in
Seems to be a bug : http://email@example.com/msg882686.html
So you better go to the next page : http://code.google.com/p/trash-cli/ and download trash-cli-0.11.3-r315.tar.gz.
Extract it :
tar xf trash-cli-0.11.3-r315.tar.gz
A directory trash-cli-0.11.3-r315 is created with a INSTALL.txt with the instruction to install it :
Open up a terminal inside the directory and then as root :
python setup.py install
Checking .pth file support in /usr/local/lib/python2.6/dist-packages/
Installing trash-list script to /usr/local/bin
Installing restore-trash script to /usr/local/bin
Installing trash-put script to /usr/local/bin
Installing volume-of script to /usr/local/bin
Installing trash-empty script to /usr/local/bin
Finished processing dependencies for trash-cli==0.11.3-r315
To remove file foo in the Trash Can, use :
To list all the contents of the Trash Can :
To restore a trashed file :
0 2011-10-20 23:47:05 /home/eric/Downloads/ruba 3tif.jpg
1 2011-10-20 23:47:25 /home/eric/Downloads/README.txt
2 2011-10-20 23:46:54 /home/eric/Downloads/NCw6L.jpg
What file to restore [0..2]:
To remove all trashed files :
To remove files that have been in the trash more than a given number of days :