You are not logged in.

#1 2015-07-10 04:11:35

j33205
Member
Registered: 2015-06-28
Posts: 38

[SOLVED] Default trash and managing it

Hello.  In my new Arch install I basically just have openbox and SpaceFM and Terminator, in terms of window and file managing and terminal.  I was wondering if there is a default destination for removed/deleted (i.e. terminal removed / file manager deleted) files.  Where do they go?  Are they automatically permanently removed?  Are the two removal techniques different in execution?  I have no urgent need to know or any files to recover but it would be nice to know.  If they are permanently deleted, is there a way to change how deleted files are managed, like a Trash folder?  Any explanations and ideas appreciated.

Last edited by j33205 (2015-07-11 03:59:27)

Offline

#2 2015-07-10 05:26:34

ooo
Member
Registered: 2013-04-10
Posts: 1,638

Re: [SOLVED] Default trash and managing it

There's the freedesktop.org trash specification, which is used by most file managers and GUI applications (but not necessarily all). Trashed files are stored in ~/.local/share/Trash/ (at least in arch by default). With most graphical file managers it's also possible to actually delete files from file system, instead of just moving them to trash.

Standard 'rm' in command line will actually delete files from filesystem, and they can't be recovered from trash. If you want to delete files to trash from command line, there are many scripts available from AUR that can do that: https://aur.archlinux.org/packages/?O=0&K=trash

Looks like SpaceFM actually requires additional plugin to enable trash (I never used SpaceFM, just did a quick search), so beware when deleting files with it.

Offline

#3 2015-07-10 12:52:54

Chazza
Wiki Maintainer
Registered: 2013-06-02
Posts: 506

Re: [SOLVED] Default trash and managing it

PCManFM does have a trash folder but you need to install gvfs for it to work.

For future reference don't forget to consult the wiki:
https://wiki.archlinux.org/index.php/Fi … ctionality

https://wiki.archlinux.org/index.php/PCManFM

And of course the package optional dependencies.

Edit: Oops sorry. Must have misread. Please disregard.

Edit2: Here's an aur package for the trash plugin mentioned by the user above.

Last edited by Chazza (2015-07-10 13:13:03)

Offline

#4 2015-07-10 13:01:34

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: [SOLVED] Default trash and managing it

@Chazza, OP is talking about SpaceFM not PCManFM.

Offline

#5 2015-07-10 13:10:59

cirrus
Member
From: Glasgow Scotland
Registered: 2012-08-24
Posts: 341
Website

Re: [SOLVED] Default trash and managing it

Not quite what OP is asking for but this will give the desired end result, create an alias something akin to :

alias empty='echo -n Taking out teh trash | pv -qL 10 && rm -rf  ~/.local/share/Trash/files' 

note : my alias will require 'pv' to be installed.
Good luck & welcome to the machine.

Last edited by cirrus (2015-07-10 13:12:21)

Offline

#6 2015-07-10 13:38:31

snakeroot
Member
Registered: 2012-10-06
Posts: 173

Re: [SOLVED] Default trash and managing it

Not sure just an alias to mv does it, since the fdo spec requires retention of metadata relating to the "Trash-ed" file:

http://standards.freedesktop.org/trash- … c-0.8.html

In the AUR there are packages for trash-cli and trash-cli-git, which seem to allow fdo-compliant trashing from the command line.

Regards,

Offline

#7 2015-07-11 04:00:00

j33205
Member
Registered: 2015-06-28
Posts: 38

Re: [SOLVED] Default trash and managing it

Thanks guys, especially ooo and Chazza.  Didn't change the command execution.  I now know where the Trash folder is even though I swear it wasn't there before.  Got the corbeille plugin and working on making it work.  Now I just gotta figure out this Xorg problem I'm having, but another day, another post.

Offline

#8 2019-03-27 14:55:07

funkaddict
Member
Registered: 2018-08-13
Posts: 117

Re: [SOLVED] Default trash and managing it

Hey there,

I stumbled across this thread as I am looking how to implement a trash folder-function into spacefm. I already read about the corbeille plugin. However, I am not sure if I can savely install the plugin via the "plugin" function of spacefm or if I need to write a PKGBUILD. In other words: Does the plugin function of spacefm install any packages which should be tracked by pacman to prevent from inconsistensies?

Offline

#9 2019-03-27 15:11:46

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 24,759

Re: [SOLVED] Default trash and managing it

Please do not necrobump 4 year old solved threads, create your own, link back to this if you feel it is relevant to your problem. https://wiki.archlinux.org/index.php/Co … bumping%22

FWIW if your software installs things in your home directory, it should generally be safe and not cause conflicts.

Closing.

Offline

Board footer

Powered by FluxBB