How to fix Xcode error when creating lproj folders in en.lproj folder?

In my project there was a Localizable.strings file for which I wanted to add additional localizations.

So, I went to the project settings and clicked β€œ+” to add languages. Somehow I can’t do this anymore on the right panel, as there is no β€œ+” button.

Xcode creates the cn.lproj folder inside the en.lproj folder in the file system, which is dirty, but some other lproj folders, such as de.lproj, are created where they belong.

How to move the xx.lproj folder to where it belongs without breaking everything in Xcode? I am afraid to leave them where xcode places them, may lead to runtime errors, because cn.lproj should not be a subfolder of en.lproj.

+5
source share
3 answers

As it turned out, this is an Xcode bug, but, fortunately, it can be solved.

- . lproj en.lproj, , , . () Project Navigator. , , . " ". , . "" sobfolder, lproj, Xcode , , , ​​ ( " " ). , , . , , lproj, .

+3

" " Xcode.

:

Here's the most obvious way to add a localization via Xcode

, ( ).

+1

I think you should have an en.lpoj folder for English. Now, if you press "+" and select xx as the language, you should get another "xx.lpoj" next to the old one (at the same level as you say) and NOT inside en.lproj. So delete this wrong subfolder and do it again ...

0
source

All Articles