Take the 2-minute tour ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

I accidentally deleted the .localized file from my mac desktop and then emptied my trash. How to I recover it?

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

Did it make any problems to your system?

The ".localized" files simply contain user language dependent data. This allows the Finder to display localized folder and file names. A good example of this is the "Applications" folder, which on the file system is called "Applications" but magically appears to the user with a localized name (e.g. "Applicazioni" in Italian).

To restore it:

  1. Open the terminal
    1. Type defaults write com.apple.finder AppleShowAllFiles TRUE
    2. Type killall Finder
  2. Open the finder and go to the Desktop folder
  3. Start Time Machine
  4. Use Time Machine for restoring the .localized file
  5. Open the terminal
    1. Type defaults write com.apple.finder AppleShowAllFiles FALSE
    2. Type killall Finder

Skip steps 1 and 5 if you already see the hidden files in Finder and you like it.

share|improve this answer
    
Its made no problems. Does this mean when I reboot the system or when I log out and back into it? –  Marina Nov 29 '12 at 9:59
    
@Marina Sorry, that wasn't true. See the edited answer. –  Maverik Nov 29 '12 at 10:15
    
I simply found the file in applications (the .localized file) and then right clicked scrolled down to Copy file. Then went to the desktop then right clicked and typed paste file and it showed it on my desktop. Do you think that will do the trick? –  Marina Nov 29 '12 at 10:22
    
@Marina The best solution is using Time Machine. I'm not sure that the content of you .localizedfile on the Desktop was the same of the one you have in the Application folder. –  Maverik Nov 29 '12 at 10:34
    
I don't have Time Machine set up for my Mac –  Marina Nov 29 '12 at 10:40
show 2 more comments

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.