Remove an iOS app localization

前端 未结 5 1755
清酒与你
清酒与你 2021-02-07 08:43

In Bombr 1.2 I added a half-assed French localization, over time adding more strings to localize I\'ve decided to drop the French localization. In Bombr 1.2.1 I removed the

相关标签:
5条回答
  • 2021-02-07 09:16

    So I landed on this question, but with some specific criteria:

    • I want to remove the base development language (English)
    • I want to keep the localized language (French)

    None of the above answers worked and I couldn't find anything better on Stack Overflow. Eventually I found this gem: XCode: Remove localizations on build.

    I develop in English, so the entire base of the app is in the English localisation. I then translated it into Finnish for the first release, but the intention was to only release the Finnish content and not the English.

    Setting up a small script during a final Build phase works wonders to strip unwanted localisations:

    #Remove english
    rm -r "${TARGET_BUILD_DIR}/${PRODUCT_NAME}.app/en.lproj"
    # Remove base (iOS 9)
    rm -r "${TARGET_BUILD_DIR}/${PRODUCT_NAME}.app/Base.lproj"
    

    Then I had some runtime errors because some Storyboard files were localized and located in the Base.lproj folder. I worked around this by doing the following:

    • Un-localized those Storyboards (unchecked all languages) and then "Moved to trash"
    • Dragged the Storyboards from the trash back into the project. (Basically moving the Storyboards from Base.lproj folder – which the script would delete – to the project folder.)

    Note: none of these Storyboards were actually localized (the .strings files were all empty). All the translations were properly set in code using NSLocalizedString.

    0 讨论(0)
  • 2021-02-07 09:22

    try to look at the info.plist which defines localizations and I guess some work in iTunesConnect should be done as well, but before approving an app

    0 讨论(0)
  • 2021-02-07 09:22

    If you want to remove app metadata localization, there's a delete menu on iTunesConnect

    enter image description here

    0 讨论(0)
  • 2021-02-07 09:24

    Building on the answer given by @vanya, select your project from the list and delete the language under in the "localization" section.

    XCode

    0 讨论(0)
  • 2021-02-07 09:36

    To remove the localization from Xcode (I'm using 4.2 on Snow Leopard) click on the file/folder in the sidebar, "Localizable.strings" and open the File Inspector (keyboard shortcut cmd-opt-1 or View > Utilities > Show File Inspector in the menu bar). You'll see a Localization pane with your localizations listed. Select the one you want to remove and click the minus sign to delete it.

    0 讨论(0)
提交回复
热议问题