Trash Problem

Discussion in 'Mac Programming' started by melow71, Mar 5, 2017.

  1. melow71 macrumors member

    Dec 29, 2008
    I recently typed a command I was told would help empty my trash bin but now it deletes every file I right click move to trash ?? The files never enter trash bin but simply get deleted and I don't know how to reverse this issue. Any help would be appreciated.

    This is what I typed into terminal

    sudo rm -rf ~/.Trash /Volumes/*/.Trashes
  2. jerwin macrumors 68000

    Jun 13, 2015
    Try logging out and then logging back in.

    If you can't log out right now, you might also be able to get the proper behavior back by force quitting finder-- (it will, of course start right up again)
  3. KALLT macrumors 601

    Sep 23, 2008
    The command will have deleted your Trash directories. Without them, files will be deleted immediately.

    You should restore them with these commands:
    mkdir -m go= ~/.Trash
    chmod +a "everyone deny delete" ~/.Trash
    sudo mkdir -m a=wx+t /.Trashes
    For your external volumes (replace <volume> with the name of the volume):
    sudo mkdir -m a=wx+t /Volumes/<volume>

Share This Page