No way to disable trash in nautilus

Bug #118988 reported by anethema
88
This bug affects 14 people
Affects Status Importance Assigned to Milestone
Nautilus
Won't Fix
Wishlist
nautilus (Ubuntu)
Triaged
Wishlist
Ubuntu Desktop Bugs

Bug Description

This is a similar 'bug' to #12893 but what I think there should be is a check-box in the nautilus configuration that just says 'Disable the trash and delete files immediately'

I realize you can shift delete, but there should be a way to just disable the trash all together. You can do this in both windows and OSX so there is no reason it shouldn't be possible in Linux.

I believe the ideal situation would be the nautilus configuration as it is now with two additional check-boxes:

1. Disable the trash and delete files immediately.
2. Disable the trash for removable media and delete files immediately.

Option two check-box would get greyed out when option 1 was checked.

Revision history for this message
Jérôme Guelfucci (jerome-guelfucci-deactivatedaccount) wrote :

Thank you for your report. Have a look at the following gconf key : apps/nautilus/preferences/enable_delete , it should do what you want. After that, it's a matter of UI.

Revision history for this message
anethema (anethema) wrote : Re: [Bug 118988] Re: No way to disable trash in nautilus

This does not fix the bug. It seems to add an option into the context menu,
which does help some, but the delete key still sends files to the trash
rather than deleting them.

Is there no option to just disable the trash functionality all together like
windows/OSX has?

Revision history for this message
anethema (anethema) wrote :

Sorry I meant, the delete option IN the context menu. The delete key
behaviour does not change for some reason. Having it change one and not the
other is almost a bug in itself I'd think.

On 6/6/07, Jay DeRoussy <email address hidden> wrote:
>
> This does not fix the bug. It seems to add an option into the context
> menu, which does help some, but the delete key still sends files to the
> trash rather than deleting them.
>
> Is there no option to just disable the trash functionality all together
> like windows/OSX has?
>

Revision history for this message
Jérôme Guelfucci (jerome-guelfucci-deactivatedaccount) wrote :

Ok, thank you, I will report this upstream when I have some time.

Changed in nautilus:
assignee: nobody → desktop-bugs
status: Needs Info → Confirmed
Revision history for this message
Jérôme Guelfucci (jerome-guelfucci-deactivatedaccount) wrote :

Actually it has already been reported upstream, feel free to add any comment there.

Changed in nautilus:
status: Unknown → Unconfirmed
Revision history for this message
irongrunty (wtfmanthatsnotcool) wrote :

trash is quite irritating, please add the option to just delete.

Changed in nautilus:
status: Confirmed → Triaged
Revision history for this message
The Devil Is A Squirrel (justanotheradress) wrote :

This is still not resolved?!

Revision history for this message
Jérôme Guelfucci (jerome-guelfucci-deactivatedaccount) wrote :

If you want to get this fixed, please contact Nautilus developpers, the bug has been forwarded and we can't do anything about it here, unless one of you provide a patch. Thank you.

Revision history for this message
rofthorax (rofthorax) wrote :

I think the better suggestion would be to add an option to allow people to delete a file without trashing it, and distinguish it as a seperate option.. Trashing a file means something different than deleting it anyhow. Deleting could also be distinguished with the name "remove" or "remove totally"..

I have this problem with drives like SD cards where I was to trash the entire contents (such as to replace podcasts) to make room for new contents (new podcasts in my case).

One solution is to enable the side pane which gives you the "trash can" symbol for that drive..

The trashcan symbol is a life saver sometimes, but sometimes its just plain annoying.. I am confident enough to manage "rm" without having to alias it with "rm -i" which some unixes have the command set to.. I guess it depends on how clumsy you are with managing files. But some newbies never remove stuff from their trashcan, and when the trashcan fills up they feel they need a new drive, and never think to (or can never bring themselves to) remove the trash.

BTW, none of the options I've ever set in the gconf-editor has ever worked for me..

Changed in nautilus:
status: New → Invalid
Changed in nautilus:
status: Unknown → Confirmed
Revision history for this message
Arthur Archnix (arthur-archnix) wrote :

It's a shame this is listed as 'wishlist'. It's more than a matter of 'preference' when it comes to removable media. New users are often confused why they can't add files to their removable devices even though it shows enough free space. The reason is because nautilus creates a hidden trash folder on their devices and users need to figure out that it's there (if they're coming from Windows, (Mac, KDE?) they wouldn't because that's not the standard behaviour. As it stands, I know have to remember to always right-click and delete completely, but sometimes I find that others have simply deleted files off my memory stick and I have to empty the trash to free up the memory.

Revision history for this message
Sebastien Bacher (seb128) wrote :

Arthur, it's polite to subscribe to a bug when commenting so you get replies to your comments. What you describes is not what should happen right now, when ejecting the device nautilus should ask if you want to empty the trash. Does it happen for you? If not I suggest opening a new bug and not commenting on a different issue

Revision history for this message
Arthur Archnix (arthur-archnix) wrote :

Did I not? I assumed it was default behaviour. I'll check my settings.
Thank you.

As for your question, no. I'd seen a comment elsewhere requesting this
feature, but I was not aware it had been implemented. I will look into
it further and file a new bug report if necessary.

Best wishes,

Arthur
> Arthur, it's polite to subscribe to a bug when commenting so you get
> replies to your comments. What you describes is not what should happen
> right now, when ejecting the device nautilus should ask if you want to
> empty the trash. Does it happen for you? If not I suggest opening a new
> bug and not commenting on a different issue
>
>

Revision history for this message
Arthur Archnix (arthur-archnix) wrote :

Well colour me foolish and, if possible, let me retract my previous
comments. I've been using the workaround so long I wasn't aware it had
been fixed.

My apologies and best wishes,

Arthur

Revision history for this message
Vitaly Polonetsky (m-vitaly) wrote :

Actually exactly what you want is already enabled with
/apps/nautilus/preferences/enable_delete
configuration key (checkbox also exists in my nautilus preferences dialog).

The only thing you probably miss is Windows-like behavior where SHIFT-DELETE is
replaced with DELETE keyboard key and used to delete the file instead of moving
it to the Trash.

Look at this guide:

http://www.rolfs.no/2007/11/19/how-do-you-disable-the-ctrlt-%E2%80%98move-to-trash%E2%80%99-keyboard-shortcut-in-gnomenautilus/

It's about another shourtcut key, BUT after enabling the config
(.../enable_delete) you can replace the default SHIFT-DELETE with just DELETE
key (follow the guide and press DELETE twice: once to delete the previous key
and second time to set the DELETE key itself).
After that, pressing delete on any file/folder will bring the delete
confirmation dialog, after accepting it the selected items will be deleted
permanently.

Revision history for this message
jdelano1980 (jdelano1980) wrote :

Almost 2 years later and this is still not fixed? What's going on? This is really annoying.

Revision history for this message
jdelano1980 (jdelano1980) wrote :

The "enable delete" functionality only adds another option, it doesn't deal with the core issue of the trash cans. It's not a real solution.

Revision history for this message
fubarbundy (launchpad-mailtic) wrote :

Like others, I don't use the Trash/Wastebasket - I know when I want to delete something. However, it is too easy to accidentally tap the delete key on the keyboard, so I don't want to reassign the key to 'delete permanently', just disable it. Unfortunately, the 'editable shortcuts' approach doesn't work - the delete key still sends to trash, even when there is no keyboard shortcut in the edit menu.

Revision history for this message
Ubuntu-Me (treverplantaginate) wrote :

The way to disable the command is as follows :

Find the Trash folder and remove it. Then replace it with a file so that it cannot be recreated under that name again. Give it minimal rights. Anything that tries to use such a folder will never be able to. Twisting its arm off if it tries. Brute force but it works. Here is an example.

/home/<YourLoginName/.local/share# ls -l

-rw-r--r-- 1 root root 0 2009-10-25 10:48 Trash
 ------------------------------------------------------------------------

That file use to be this folder.

drwxrwxrwx 4 UserName UserName 4096 2009-02-01 16:54 Trash

In order to do this you need to empty the contents of the Trash folder which has an <info> and a <files> folder with stuff in it. After removing the files and folders then remove the Trash folder and use a touch command to create the file <Trash> like this.

touch Trash

Remeber you need to be root. Use <chmod> if you need to in order to remove rights to the file.
Your problem is gone.

Hint. You can do this on [Jump Drives] too. ! The fill up with trash. What a pain.
DELETE means DELETE... Thought I would help...

Happy UBUNTU - ing 8-)

Changed in nautilus:
importance: Unknown → Wishlist
Revision history for this message
Raúl Núñez de Arenas Coronado (dervishd) wrote :

While this is fixed, you may want to try my solution: go to the Configuration Editor and check the options
/desktop/gnome/interface/can_change_accels
/apps/nautilus/preferences/enable_delete

Now you can change the key accelerator for any menu entry in Gnome and you have a *real* delete menu entry in Nautilus. After that, go to Nautilus and change the accelerator for "Delete" and "Move to Trash". Set <Delete> for "Delete" and <Shift>+<Delete> for "Move to Trash". This way, pressing the <Delete> key will really delete the item instead of moving it to the Trashcan.

I find this useful for removable drives, specially. The ".Trash-1000" directory is annoying and in fact it's a very bad idea for newbies, who find their pendrives full when there are no files present...

Revision history for this message
user512 (rkareev) wrote :

Thanks! I'll try it.

Revision history for this message
Eric Majerus (nicht-ungarisch) wrote :

WARNING for anyone that tries the advice in comments #14 and #19:

Using Ubuntu 10.10, I did this and at first it worked perfectly, however, I was perplexed why Nautilus was "automatically" deleting my files when renaming them. I often use the "Delete" key when renaming files instead of the "Backspace" key. What happens after making the Delete key the shortcut for the Delete command in Nautilus is if you are renaming a file and press the Delete key (to remove text after the cursor), Nautilus deletes the file in the background but doesn't exit the rename process so it looks like nothing happened. When you press Enter to accept the new name, it errors saying the file does not exist (and being you just made it the shortcut to bypass the trash, good luck getting it back some work).

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

This bug appears to be fixed. Go to Nautilus preferences -> Behavior -> check "Include a Delete command that bypasses Trash". The action is bound to shift-delete by default.

Revision history for this message
anethema (anethema) wrote :

How do you make it the default behavior though ? Manually bypassing the
trash was always doable, but you do not seem to be able to disable the
trash all together.

On Thu, Dec 1, 2011 at 8:32 PM, Chris Bainbridge <<email address hidden>
> wrote:

> This bug appears to be fixed. Go to Nautilus preferences -> Behavior ->
> check "Include a Delete command that bypasses Trash". The action is
> bound to shift-delete by default.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/118988
>
> Title:
> No way to disable trash in nautilus
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/nautilus/+bug/118988/+subscriptions
>

Revision history for this message
EricDHH (ericdhh) wrote :

12.04 amd64

Just mount a nfs share from my NAS box, and nautilus create a trashbin again and again. Sorry, this is not okay. The dlna server on the nas box goes crazy, when deleted things are not really deleted. The dlna server database is crappy from this bug.

Please fix this bone old bug.

Revision history for this message
L Garcia (lisa-garcia-90mc022) wrote :

If "upstream" cannot be bothered to fix this outrageous problem could not the fix be default to a file manager OTHER-THAN nautilus?

Revision history for this message
Narcis Garcia (narcisgarcia) wrote :

A workaround for each place, already mentioned:

1. Invoke trash creation, deleting something.
2. Show hidden elements in folder, to trash folder be shown, for example, with the name .Trash-1000
3. Remove permanently this folder
4. Create a regular file with the same name as removed folder had.

This will not allow "move to trash". The only thing to add is to make <Delete> key to remove permanently by default. I've tried to edit ~/.gnome2/accels/nautilus but don't find it in Ubuntu 13.10

Revision history for this message
Michael Stumpfl (michael-stumpfl) wrote :

I am one of those who have been bugged by this problem for a number of years.

Unsatisfied with the existing proposals, I've recently taken the time to investigate a solution to this problem for myself.

As I want the Trash to be gone system-wide (not only in Nautilus), I've found that -- for the time being -- the only real solution is to create a custom-compiled version of `libgio' which is modified to call g_file_delete() every time an application calls g_file_trash().

For all technical-savy users interested in this solution: I've just recently posted a step-by-step guide on `The IT community':

http://www.theitcommunity.com/wiki/Globally_disable_GNOME%27s_Trash_in_Debian-based_distributions

I hope this is of (some) help to those who hate the Trash with the same passion as I do ...

Revision history for this message
Anonymous (reason) wrote :

This bug is now 8 years old. I really wish that I could TURN OFF the creation of ANY trash folders and TURN OFF all trash options.

Revision history for this message
Bougron (francis-bougron) wrote :
Revision history for this message
Bougron (francis-bougron) wrote :

Besides that some applications (for example the image viewer), when asked to delete a photo only proposes the trash and not the immediate deletion. So, we find these photos in the "pseudo-basket" and it must be removed then to actually release the place

Changed in nautilus:
status: Confirmed → Won't Fix
Revision history for this message
Joel Croteau (jcroteau) wrote :

Why is this won't fix? This is extremely annoying. There needs to be a fix that doesn't involve me editing config files or writing complicated script to work around the GUI's obtuseness. This is exactly four clicks in Windows. This is a pretty basic bit of system functionality to put so many hurdles around.

Revision history for this message
Michael Stumpfl (michael-stumpfl) wrote :

The http://www.theitcommunity.com/wiki/ link I posted above no longer works … a step-by-step tutorial on how to (completely) disable Gnome's Trash can now be found on my Github page:

http://htmlpreview.github.io/?https://github.com/Cordic77/libgio-disable-trash/blob/master/Globally%20disable%20GNOME%27s%20Trash%20in%20Debian-based%20distributions.htm

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.