Apparently, Prism Launcher chose to adhere to the idiotic principle of the hidden “trashbin”, .Trash-$(uid), invented by Ubuntu. Even though it’s based on QT. This can’t be disabled. It accumulated 139 GB of literal Trash, fully replaceable, over time. Just … why? There’s even an open issue about this, for over a year, referenced multiple times. I guess I have another point on my agenda.

  • d_k_bo@feddit.org
    link
    fedilink
    arrow-up
    88
    ·
    edit-2
    11 days ago

    the hidden “trashbin”, .Trash-$(uid), invented by Ubuntu

    This isn’t some “idiotic principle invented by Ubuntu”, it just follows the freedesktop.org Trash specification. For many users, it can be really beneficial, see also the spec’s introduction:

    An ability to recover accidentally deleted files has become the de facto standard for today’s desktop user experience.

    Users do not expect that anything they delete is permanently gone. Instead, they are used to a “Trash can” metaphor. A deleted document ends up in a “Trash can”, and stays there at least for some time — until the can is manually or automatically cleaned.

    Whether an application like Prism Launcher should use the trash can or delete the files directly is an entirely different question.

    • lurch (he/him)@sh.itjust.works
      link
      fedilink
      arrow-up
      39
      ·
      11 days ago

      and proper trashing is actually really helpful, so you can trash files on encrypted volumes without leaking them to a unencrypted trash dir.

      trashing saves time and has a more continous workflow, as you don’t have to confirm each file to prevent accidents, because you can restore if you deleted too much

    • theshatterstone54@feddit.uk
      link
      fedilink
      arrow-up
      13
      ·
      11 days ago

      But why wouldn’t they use .local/share/Trash instead? Isn’t that supposed to be a unified directory for that very purpose?

      • cmnybo@discuss.tchncs.de
        link
        fedilink
        English
        arrow-up
        43
        ·
        11 days ago

        Because that would take a long time if you deleted a large file in another partition or drive. You could also end up not having enough space to move the file to trash and if the trash directory is on an SSD, it would add a lot of unnecessary wear to it.

        • d_k_bo@feddit.org
          link
          fedilink
          arrow-up
          8
          ·
          10 days ago

          To explain it a bit further: when you move a file/directory on the same mount point, moving the file/directory is essentially just a rename operation, which doesn’t involve copying the data itself and is a very cheap operation. If you move a file/directory across mount points, you need to (recursively) copy the file/directory, copy file metadata and (recursively) delete the old file/directory, which is slow and error-prone.

    • mizuki
      link
      fedilink
      arrow-up
      2
      ·
      10 days ago

      I was about to suggest this. It comes with a nice TUI that sorts by highest disk usage.

    • InFerNo@lemmy.ml
      link
      fedilink
      arrow-up
      1
      ·
      10 days ago

      Neat! I kept using du and df and work my way to the culprit. On PC’s with GNOME I use baobab.

  • DrDystopia@lemy.lol
    link
    fedilink
    arrow-up
    24
    ·
    11 days ago

    Doesn’t people use a disk usage scanner every once in a while to find out if there’s something hogging space?

    • lnxtx@feddit.nl
      link
      fedilink
      English
      arrow-up
      13
      ·
      11 days ago

      If you have 4 TB disk, you don’t care until it is getting full.

      • MonkderVierte@lemmy.ml
        link
        fedilink
        arrow-up
        6
        ·
        edit-2
        10 days ago

        I do, because it is the same with a 4 TB disk and 100 GB games as it is with a 256 GB disk and png’s & office stuff.

      • DrDystopia@lemy.lol
        link
        fedilink
        arrow-up
        5
        ·
        11 days ago

        I have several 4 and 8 TB disks filled up with various stuff just waiting to be cleaned up. Why do you think I’m preaching about storage space management?

        My dual 10’s are starting to fill up because I don’t move stuff off-site as I should. And then reclaiming space through disk analyser and freeing up reserved space is a life saver.

    • Lucy :3@feddit.orgOP
      link
      fedilink
      arrow-up
      3
      ·
      11 days ago

      I do, except I always used du -hs *, which does not include hidden (.-Prefixed) files. So a double trap.

  • exu@feditown.com
    link
    fedilink
    English
    arrow-up
    19
    ·
    11 days ago

    Your desktop environment should have settings for when to clear the trash. You can also use autotrash to clear it automatically.

    • Lucy :3@feddit.orgOP
      link
      fedilink
      arrow-up
      13
      ·
      11 days ago

      The Problem is: I don’t have a DE, and therefore didn’t realize programs would still try to use trashbins.

  • thingsiplay@beehaw.org
    link
    fedilink
    arrow-up
    19
    ·
    edit-2
    11 days ago

    I use command trash-empty to empty all trashcan of all the users, after each system update. It’s a non standard program, but most likely available in your distributions repository: https://github.com/andreafrancia/trash-cli And my alias/function will show each file that is about being deleted (just put it in .bashrc, if you have installed trash-cli, which includes trash-empty):

    old function (click to expand)
    empty() {
        echo "Files to delete:"
        trash-empty -f --dry-run |
            awk '{print $3}' |
            grep -vF '/info/'
        echo
        trash-empty
    }
    

    Edit: After I posted I just realized there is a more straightforward way of doing it:

    New and more simple alias:

    alias empty='trash-empty -f --dry-run ; trash-empty'
    

    This searches all trash cans, lists all files it has found to be deleted, then lists all directories it looked under and then asks if you want really delete. With trash-empty -f it deletes without asking.

  • sunstoned@lemmus.org
    link
    fedilink
    English
    arrow-up
    17
    ·
    edit-2
    10 days ago

    I’m more of a dust man, myself. It runs recursively so it’s easy to pinpoint the culprit.

    [Image source: the project’s README]

  • ZeroHora@lemmy.ml
    link
    fedilink
    English
    arrow-up
    9
    ·
    11 days ago

    All .Trash-1000 files appears in your trashbin no? At least is how is working for me.

  • eldavi@lemmy.ml
    link
    fedilink
    arrow-up
    5
    ·
    11 days ago

    I did this yesterday while trying to make a backup before formatting and then updating my work rig and I’m SO GLAD that the decades have taught me to take knee-jerk/automatic actions that forces me to make entire volume backups; otherwise this last month of work life would have been AWFUL!!!

    • prole
      link
      fedilink
      arrow-up
      2
      ·
      edit-2
      10 days ago

      You can easily set it up to do this automatically with something like timeshift…

      I recently switched to an Atomic distro (Bazzite), and they have made it so easy to rollback to previous commits without any additional software.

      • eldavi@lemmy.ml
        link
        fedilink
        arrow-up
        1
        ·
        edit-2
        10 days ago

        I use rsync on a cron job and it do it automatically every time i add a new drive or volume.