Use terminal to delete the DS_store. Why all of my files disappeared?
the order is
find ~-type f-name.DS_store -delete.
All my files disappeared. All folds were empty.
MacBook Pro with Retina display, OS X Mavericks (10.9.2)
the order is
find ~-type f-name.DS_store -delete.
All my files disappeared. All folds were empty.
MacBook Pro with Retina display, OS X Mavericks (10.9.2)
There are spaces missing, but in any case if you are going to use this kind of command it may have been better to do it first without the -delete just to see what it found.
is -delete the right command?
As ahi there,
as peter_watt already has written, there are spaces missing.
If you entered the command in the way you described in your message, the find command discards everything between ~ and the space before -delete. So find assumes -delete is the only parameter and thus deletes everything from the directory you are currently in downwards.
The correct parameters for the operation you wanted to execute are [without quotation marks]:
"find . -name ".DS_Store" -delete"
If you replace the "." with a "/", find searches from the top level (aka root) directory downwards. Using a "~" instead makes find search your home directory.
As a side note, it is not the best idea to remove the .DS_Store files from any OSX related directories, since those files do contain information necessary for OSX to work properly.
However, removing those files from network shares accessed by other operating systems as well can be useful.
Use terminal to delete the DS_store. Why all of my files disappeared?