Ubuntu QA:
BlogBrainstormPackage status
Log in
Ubuntu QA
The Ubuntu community has contributed 21986 ideas, 135057 comments, 2615221 votes
Idea sandbox Idea sandbox
Popular ideas Popular ideas
Ideas in development Ideas in development
Implemented ideas Implemented ideas
Idea #63: Add a option to automatically clean trash bin

Written by nomis the 28 Feb 08 at 16:12. Category: System. Related project: Nothing/Others. Status: New
Rationale
It would be nice to have a feature like: "delete items older than 2 weeks"
Tags: (none)

438
votes
up equal down
Solution #1: Auto-generated solution of idea #63
Written by nomis the 28 Feb 08 at 16:12.
Ubuntu Brainstorm was updated in January 2009. Since the idea #63 was submitted before this update, its rationale and solution are not separated. Please vote accordingly, and if you have the necessary rights, please separate the rationale from the solution. Thanks!

Propose your solution

Attachments


Duplicates


Comments
Alan Pope (Ubuntu developer) wrote on the 28 Feb 08 at 16:29
#!/bin/sh
find ~/.Trash -mtime +14 -exec rm -f \;


:)

skyhook19 wrote on the 28 Feb 08 at 23:35
I think nomis was going for a graphical setting for that...

Tolaris wrote on the 29 Feb 08 at 01:19
How about an option to "Limit Trash to 5% of partition"?

derick.eisenhardt wrote on the 29 Feb 08 at 06:23
I would very much like to see the gnome Trash Bin do an automatic removal of items older than a certain time period or when the drive is getting close to full.

Honestly, if something sits in your trash for 30 days there's a fairly good chance that you're never going to restore it.

Graf wrote on the 29 Feb 08 at 07:29
Great idea.

This sort of thing would help set Ubuntu apart from windows/OS x

johan wrote on the 29 Feb 08 at 12:31
Sure that would be nice, but what's really needed is an option to put the files back wherever they were deleted from.

antistress wrote on the 2 Mar 08 at 23:19
i totally agree with that suggestion
i filled a bug report once about it https://bugs.launchpad.net/ubuntu/+source/nautilus/+bug/150112

antistress wrote on the 3 Mar 08 at 00:32
see also idea #1605: Trash Criteria/Timing

logfish wrote on the 4 Mar 08 at 01:57
I've got a small crontab line that might help some:

find ~/.local/share/Trash/files/ -type f -mtime 30 -printf '%P\000' |xargs -n1 -I -0 gvfs-rm trash:///_

Mind you, this is for the upcoming hardy.

(more on what it does at http://log.logfish.net/node/23 )

jiu wrote on the 5 Mar 08 at 07:38
...and a "restore to initial location" option

antistress wrote on the 5 Mar 08 at 14:05
restore to initial locataion will be possible in near future thanks to GVFS (which will replace GnomeVFS in GNOME 2.22)

antistress wrote on the 21 Apr 08 at 19:22
see that amazing mockup http://jeff.ecchi.ca/blog/images/trash-individual-files-expiry.png from that article http://jeff.ecchi.ca/blog/?p=335

sampoli wrote on the 7 May 08 at 20:33
A small annoyance of the trashcan i just noticed: when you click the trashcan icon, it opens up the trashcan window. On the second click it opens a second one and so on. It would probably be better if it closed the existing trash window when the icon was clicked, like pidgin does for example.

This may be intentional, but i can't come up with a situation where i would need several trashcans open simultaneously.

uaneme wrote on the 5 Jun 08 at 04:19
delete oldest trash item older then 7 day when bin is fuller then xxxx MB
and also a fix for trash that gets 'jailed' in the bin.

i often have to sudo nautilus to put the trash out.

(external harddrive trash issue .trash .trash-0 .trash-1000 folders)

hessam wrote on the 14 Sep 08 at 11:00
OH YEAH! This is a GREAT idea.

There should be an option for automatic emptying too. I love the way Gmail handles this. It gets rid of mail more than 30 days old automatically.

> How about an option to "Limit Trash to 5% of partition"?

Not such a good ides. Imagine you delete a bunch of important text files and then a huge video file almost as big as 5% of the entire partition. That will get rid of the text files for good.

anystupidname wrote on the 19 Oct 08 at 03:01
This has been a need for a while and been discussed many times. Example:
http://ubuntuforums.org/showthread.php?t=402302&highlight=trash+oldest

I think it is definitely time to implement something in this regard...


Post your comment