You are not logged in.

#1 2021-11-01 10:17:10

jones
Member
Registered: 2013-03-14
Posts: 276

Trash-CLI wants to empty more than user's directory

I just ran the command I usually use and it produced the following output:

$ trash-empty 3  
Would empty the following trash directories:
    - /home/john/.local/share/Trash
    - /proc/.Trash-1000
    - /sys/.Trash-1000
    - /dev/.Trash-1000
    - /sys/kernel/security/.Trash-1000
    - /dev/shm/.Trash-1000
    - /dev/pts/.Trash-1000
    - /run/.Trash-1000
    - /sys/fs/cgroup/.Trash-1000
    - /sys/fs/pstore/.Trash-1000
    - /sys/firmware/efi/efivars/.Trash-1000
    - /sys/fs/bpf/.Trash-1000
    - /.Trash-1000
    - /proc/sys/fs/binfmt_misc/.Trash-1000
    - /dev/hugepages/.Trash-1000
    - /dev/mqueue/.Trash-1000
    - /sys/kernel/debug/.Trash-1000
    - /sys/kernel/tracing/.Trash-1000
    - /proc/sys/fs/binfmt_misc/.Trash-1000
    - /sys/fs/fuse/connections/.Trash-1000
    - /sys/kernel/config/.Trash-1000
    - /tmp/.Trash-1000
    - /home/.Trash-1000
    - /boot/.Trash-1000
    - /run/user/1000/.Trash-1000
    - /run/user/1000/gvfs/.Trash-1000
Proceed? (y/n) 

I could swear the output regarding all non-home based directories is new, however I cannot say if they were emptied in the past or not.

Is it safe to proceed?

Offline

#2 2021-11-01 14:16:24

twelveeighty
Member
Registered: 2011-09-04
Posts: 1,456

Re: Trash-CLI wants to empty more than user's directory

Check the file permissions on all those folders. My guess is that they are all owned by your regular user (with UID 1000), so in that sense they can all be considered *temporary* files. But, in my world, the "Trashcan" is not exactly the same as "user-owned temporary files". And how did those folders get there in the first place? Did that utility create them all?

Without a clear definition on *your* definition of "safe", it's hard for me to comment on that, but in *my* definition of safe, I would not even use a utility that creates that many files/directories all over the place for just the concept of a "Trashcan". For me, files either exist or they don't, no twilight zone for me, but that's a personal choice, of course.

Offline

#3 2021-11-07 20:40:50

jones
Member
Registered: 2013-03-14
Posts: 276

Re: Trash-CLI wants to empty more than user's directory

Well, since your reply I checked some of the folders listed in the op.
I do not recall which ones exactly I checked for, but every check lead to: that folder does not exist.

twelveeighty wrote:

Check the file permissions on all those folders. My guess is that they are all owned by your regular user (with UID 1000), so in that sense they can all be considered *temporary* files. But, in my world, the "Trashcan" is not exactly the same as "user-owned temporary files". And how did those folders get there in the first place? Did that utility create them all?

Without a clear definition on *your* definition of "safe", it's hard for me to comment on that, but in *my* definition of safe, I would not even use a utility that creates that many files/directories all over the place for just the concept of a "Trashcan". For me, files either exist or they don't, no twilight zone for me, but that's a personal choice, of course.

I think so. I certainly did not.

All in all: this is weird. Maybe trash-cli was enhanced.

In any case, the issue was already reported on github, even before I made my post on here: https://github.com/andreafrancia/trash-cli/issues/214
I think I rather stay clear until the package dev replies, so this will be an arguably dormant thread.

Offline

Board footer

Powered by FluxBB