Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Re: Yet another undeletable files solution' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Re: Yet another undeletable files solution
Authored by: dev909 on May 28, '02 10:53:15AM
or you can use my script!

set empty_local to
"chflags -R nouchg /.Trashes/* ~/.Trashes/* ~/.Trash/* ; rm -rf /.Trashes/* ~/.Trashes/* ~/.Trash/*"
set empty_all to
"chflags -R nouchg /.Trashes/* ~/.Trashes/* ~/.Trash/* Volumes/*/.Trashes/* ; rm -rf /.Trashes/* ~/.Trashes/* ~/.Trash/* Volumes/*/.Trashes/*"

display dialog "Empty Trash as root?" buttons {"Cancel", "User & Local", "All Volumes"}
default button "CANCEL"
set the user_choice to the button returned of the result
if the user_choice is "User & Local" then
do shell script
empty_local with administrator privileges
end if
if the user_choice is "All Volumes" then
do shell script
empty_all with administrator privileges
end if
tell application "Finder" to empty

-- emptytrashX 0.6
-- © 2002 devils@pobox.com


[ Reply to This | # ]