Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

galstaph

macrumors 6502a
Original poster
Jul 24, 2002
812
2
The Great White North Eh
Ok so i have some stuck items in the trash, tried forcing empty, tried trash it, onyx, even tried terminal - rebuilding trashes for the account and checking if it is an immutable bit. here is the terminal output for the immutable check:

ls -lhd0 /Volumes/biggest/.Trashes/501/accurate\ recovered\ documents/documents/0001\ My\ Documents\ Miriams\ Comp/11achurch\ folder/Fw_\ Foothills\ Stake\ Family\ Home\ Evening\ Manual.eml\:OECustomProperty
ls: illegal option -- 0
usage: ls [-ABCFGHLOPRSTUWabcdefghiklmnopqrstuwx1] [file ...]

When I tried the rm terminal command, I got a lot of errors stating that the directory was not empty and that there was no such file or directory....

I even clean installed yosemite to see if that would help - no avail...

Any suggestions? This is bugging the heck out of me!!
 

fisherking

macrumors G4
Jul 16, 2010
11,252
5,563
ny somewhere
i had a file (the remnants of a deleted app) that NOTHING would trash, but this actually did it...

EDIT: sorry just realized you've mentioned 'trashit'. weird... try looking at the package contents? changing permissions?
 

Intell

macrumors P6
Jan 24, 2010
18,955
509
Inside
What is the exact Terminal command you used? Have you tried:

Code:
sudo rm -r ~/.Trash
 

dyt1983

macrumors 65816
May 6, 2014
1,365
165
USA USA USA
Repair disk from Disk Utility. Then try to trash it again. If it's your startup disk you will need to boot in recovery mode.

p.s. your 'ls' has a wrong flag, I think you mean "ls -lhdO"
 

dyt1983

macrumors 65816
May 6, 2014
1,365
165
USA USA USA
Colons are illegal in Mac filenames.

You may need to move the offending file out of the trash in order to get the above to work. The trash folder sets some limitations on what you can do to the files inside it.

He was in terminal. Colons are not illegal in filenames. Only the forward slash. Finder converts back and forth between colons and slashes. The trash folder limitations are also only in Finder. In terminal, anything goes.
 

Intell

macrumors P6
Jan 24, 2010
18,955
509
Inside
Go into Finder.
Choose a file.
Try to add a : to its name.
Read the error message.
It's been this way since like, forever.

Read the rest of dyt1983'a post. A colon is only a limitation with Finder, not Terminal, the UNIX subsystem, or HFS+.
 

Partron22

macrumors 68030
Apr 13, 2011
2,655
808
Yes
A colon is only a limitation with Finder
Yup, it's illegal there, and expecting Finder to deal with it happily is a stretch. That's why you get problems when when you try to deal with such names through the Finder. Colon used to be folder separator in the Mac file system, so it's not surprising that there are still glitches when you include it in a file name. Even when you're working in Terminal, sooner or later the Finder has to be told that you've done something to a file, else it'll just keep happily drawing an icon for it. If Finder chokes on the name, you've got a problem whether you're starting your action from Finder, Terminal, AppleScript or whatever.
 

Intell

macrumors P6
Jan 24, 2010
18,955
509
Inside
Terminal and the UNIX subsystem do not have a problem with colons in file/folder names. As long as the script doesn't interact with Finder, it can use a colon in the path name without a problem. When a file/folder with a colon in it is viewed/manipulated from within Finder, the colon is replaced with a forward slash, but only within Finder. On the filesystem, in Terminal, and anything else that doesn't use Finder, the file/folder still has the colon in its name. I can easily create a folder in Terminal with a colon in its name, add stuff to it using Finder, move it to a different folder with Finder, then move it to the Trash and empty the Trash. Finder doesn't complain at all. It may have complained in much older versions, but as of 10.6, Finder is fully colon compliant.
 

Intell

macrumors P6
Jan 24, 2010
18,955
509
Inside
It's compliant in every other way. Much more so than Windows Explorer and its illegal characters. Summation, colons are not illegal in Mac file names, only within Finder.
 

w0lf

macrumors 65816
Feb 16, 2013
1,268
109
USA
Reboot. Your trash is most likely already empty and just bugged showing some item remaining. It's not even that uncommon of a bug.
 

GatorGhost

macrumors regular
Jun 30, 2014
113
19
Ok so i have some stuck items in the trash, tried forcing empty, tried trash it, onyx, even tried terminal - rebuilding trashes for the account and checking if it is an immutable bit. here is the terminal output for the immutable check:

ls -lhd0 /Volumes/biggest/.Trashes/501/accurate\ recovered\ documents/documents/0001\ My\ Documents\ Miriams\ Comp/11achurch\ folder/Fw_\ Foothills\ Stake\ Family\ Home\ Evening\ Manual.eml\:OECustomProperty
ls: illegal option -- 0
usage: ls [-ABCFGHLOPRSTUWabcdefghiklmnopqrstuwx1] [file ...]

When I tried the rm terminal command, I got a lot of errors stating that the directory was not empty and that there was no such file or directory....

I even clean installed yosemite to see if that would help - no avail...

Any suggestions? This is bugging the heck out of me!!


Try this program....it worked for me

Trash It! Trash It! 6.0.1 12-Oct-2014 Force-empty your trash can. 123458
Free Download Trash It! from MacUpdate.com Download
3.6 MB(Intel) http://www.macupdate.com/download/8214/trashit.zip Email me when discounted: More Apps | NoName Scriptware
Trash It! is an AppleScript-based application that force-empties your Trash and/or removes stubborn items. Especially useful if you have files or folders in the Trash with permissions set incorrectly, locked Trash items, want to securely delete a stuck item, or trash items from other partitions. If you drop files or folders onto the Trash It! icon, it will delete them as well. If you double-click on it, it will clean out your Trash can. This is the software recommended by Apple Tech support when all else fails!

Trash It! should be used when:

You can't get rid of trash items manually.
You can't move more...
What's New
Version 6.0.1:
Fixed a bug introduced in 6.0
New algorithms for faster usage.
Should get rid of Time Machine files accidentally dragged to the trash. Please read the readme file for more info.
Code optimization changes.
Requirements



Download Trash It! 4.1 (OS X 10.5 or earlier, Intel/PPC)
 

Apple_Robert

Contributor
Sep 21, 2012
35,647
52,437
In a van down by the river
Try this program....it worked for me

Trash It! Trash It! 6.0.1 12-Oct-2014 Force-empty your trash can. 123458
Free Download Trash It! from MacUpdate.com Download
3.6 MB(Intel) http://www.macupdate.com/download/8214/trashit.zip Email me when discounted: More Apps | NoName Scriptware
Trash It! is an AppleScript-based application that force-empties your Trash and/or removes stubborn items. Especially useful if you have files or folders in the Trash with permissions set incorrectly, locked Trash items, want to securely delete a stuck item, or trash items from other partitions. If you drop files or folders onto the Trash It! icon, it will delete them as well. If you double-click on it, it will clean out your Trash can. This is the software recommended by Apple Tech support when all else fails!

Trash It! should be used when:

You can't get rid of trash items manually.
You can't move more...
What's New
Version 6.0.1:
Fixed a bug introduced in 6.0
New algorithms for faster usage.
Should get rid of Time Machine files accidentally dragged to the trash. Please read the readme file for more info.
Code optimization changes.
Requirements



Download Trash It! 4.1 (OS X 10.5 or earlier, Intel/PPC)

The OP stated that Trash It! had not worked.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.