Deleting one file at a time in trash

Discussion in 'Mac Basics and Help' started by Michaelgtrusa, Oct 21, 2008.

  1. Michaelgtrusa macrumors 604

    Michaelgtrusa

    Joined:
    Oct 13, 2008
    Location:
    Everywhere And Nowhere
    #1
    Is it possible to remove selected files in your trash? Like video? Appzapper will not remove these files.
     
  2. GimmeSlack12 macrumors 603

    GimmeSlack12

    Joined:
    Apr 29, 2005
    Location:
    San Francisco
    #2
    Not sure what you mean. If a file is in the trash all you have to do is drag it back out and its out.
     
  3. Lurchdubious macrumors 65816

    Lurchdubious

    Joined:
    Oct 15, 2008
    Location:
    Texas
    #3
    Correct me if I'm wrong, but won't Appzapper only "zap" applications?

    My trash is currently being securely emptied, so I can't check about the selected stuff...
     
  4. Michaelgtrusa thread starter macrumors 604

    Michaelgtrusa

    Joined:
    Oct 13, 2008
    Location:
    Everywhere And Nowhere
    #4
    I was thinking that maybe I could highlight files I wanted deleted, but i'd have to drag them back out, empty the trash and thed drag it back in agian.
     
  5. i.shaun macrumors 6502a

    i.shaun

    Joined:
    May 1, 2008
    Location:
    Canada
    #5
    i'm not sure why you would even want to do that, but yes, that is the only way to do it. The trash empties everything, unless the file is in use, and it cannot get access to it.


    only thing I can think of is you're hiding videos in the trash, but that doesn't seem like a good spot to me. lol
     
  6. blodwyn macrumors 65816

    Joined:
    Jul 28, 2004
    Location:
    Portland, Oregon
    #6

    DISCLAIMER, you can do a lot of damage in the Terminal, so be sure to enter the commands carefully

    You can do it in Terminal. Open up the Trash in a Finder window so you can see the contents of the trash folder. Open up a Terminal window and type the following:

    cd ~/.Trash {This should take you into the Trash folder}
    ls {This should list the contents of the Trash folder - check the listing contains the same files as the Finder window so you know you're in the right place}
    rm "filename" {Replace "filename" with the name of the file you want to remove from the Trash. Use "" around the filename if it contains spaces}

    In the Finder window you should see the file disappear
     
  7. i.shaun macrumors 6502a

    i.shaun

    Joined:
    May 1, 2008
    Location:
    Canada
    #7
    does terminal do everything? if only it wasn't so confusing and potentially fatal to my system (at least when I use it).


    I would still go with selecting files I want to keep, moving them out, and emptying the rest. Sometimes I create a desktop folder to dumb files that I'm not sure I want gone yet. Once I know they are no longer of use, I'll move the folder to trash, and empty.

    I also use trash for photo sorting. Justlooking.app has a "trash" button, and the ability to scroll through photos without crashing all the time like Xee2.app.


    I scroll through and on every picture with a certain theme, say "Animals", I send to trash. I then open the trash and drag them all out into a separate folder named "Animals". If the folder is in a list with other files, I'll name it "_Animals"

    the _ makes it appear at the top of any list, otherwise it would be somewhere in the "A" section with the files.
     
  8. blodwyn macrumors 65816

    Joined:
    Jul 28, 2004
    Location:
    Portland, Oregon
    #8
    By all means use the solution that works best for you, and the method of moving files out and back in again is a good one. I was just responding to the question of whether it is possible to delete individual files from the Trash.
     
  9. krustybaguette, Dec 15, 2010
    Last edited: Dec 15, 2010

    krustybaguette macrumors newbie

    Joined:
    Sep 22, 2010
    #9
    Well I want to do it because every time I try to put one particular album BACK into iTunes it gets retagged as a "compilation" under Artist. I renamed the containing folder with it on my desktop and added it back to iTunes, but it appears in both iterations. So I need to delete "compilations" from the trash while not wiping out other items in the trash which I may or may not want to recover in the future.

    Found something about grouping compilations checked, so I unchecked it and problem was solved.
     
  10. angelwatt Moderator emeritus

    angelwatt

    Joined:
    Aug 16, 2005
    Location:
    USA
    #10
    Having backups comes to mind because that would let you retrieve files you use to have. If you really think you may need to undelete some of those files in the trash, then you should undelete them now and delete for real later once you're convinced you really don't need them. Trying to use the trash can in a way it wasn't designed for is just working against yourself. You should find and use more appropriate ways to handle your files, such as backups and Time Machine.
     
  11. Dalton63841, Dec 15, 2010
    Last edited: Dec 15, 2010

    Dalton63841 macrumors 65816

    Dalton63841

    Joined:
    Nov 27, 2010
    Location:
    SEMO, USA
    #11
    Another way to do this is to simply open Trash in a Finder window, then open Terminal. Type:
    Code:
    rm
    then drag/drop the file you want to delete into the terminal window. it will put the entire file path to the file after rm. Then hit enter.

    EDIT: Just being helpful here. If you think this would be helpful, you could create a Droplet by copying this into applescript and saving as an application:
    Code:
    on open the_Files
    	set selectedItem to the_Files
    	set posixPath to POSIX path of selectedItem as string
    	display dialog "Are You Sure You Want To Permanently Delete This?" buttons {"Yes", "No"}
    	if the button returned of the result is "Yes" then
    		do shell script "rm -rf " & quoted form of posixPath
    	else
    		quit application
    	end if
    end open
    
    Anything you want to permanently delete just pull out of the Trash into any other folder/Desktop and drop on the app icon.
     

Share This Page