强制将特定的本地化用于目标 [英] Force a specific localization to be used for a target

查看:58
本文介绍了强制将特定的本地化用于目标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一款可以播放大型音频文件(30MB)的应用程序.

I'm developing an app that, among other things, will play a large audio file (30MB).

我想将应用程序提交到多个国家/地区的App Store.每个目标国家/地区的音频文件都不同,应用程序的其余部分保持不变(尽管已本地化).

I want to submit the app to the App Store in several countries. The audio file is different per target country, the rest of the app remains the same (Although localized).

我已经为每个国家/地区创建了一个目标,bash脚本负责根据目标将正确的音频文件复制到已编译的应用中,并且效果很好.

I've created a target for each country, a bash script takes care of copying the correct audio file into compiled app based on the target, and it works great.

我还对资源(图像和Localized.strings)进行了本地化,以使其易于维护.

I've also localized the ressources (Images and Localized.strings) to make it easy to maintain.

假设我为瑞典建立了目标,我只想包含瑞典语本地化以强制应用程序始终显示瑞典语(与音频文件匹配).

Let's say I built my target for Sweden, I want to include only the swedish localization to force the app to always show swedish language (Which matches the audio file).

这是实际的问题:* 无论电话设置如何,我如何从目标中排除所有本地化或强制目标仅使用特定的本地化?

Here's the actual question:* How do I exclude all localizations from a target or force a target to ONLY use a specific localization, regardless of phone settings?

推荐答案

基于您对Lvsti的评论(您说这样做的原因是,某些语言的翻译尚未完成,但您想释放自己拥有的东西),或者作为删除所有相关的本地化文件或弄乱您的构建设置的替代方法,可以尝试在XCode项目中编辑语言列表?它不是每个目标而是每个项目,但是它可能允许您排除在构建中不需要的语言.在项目设置的本地化"下查看(有一个小图标-可用于删除语言).

Based on your comment in answer to Lvsti (where you say the reason you're doing this is that translations in some of your languages aren't finished yet but you want to release what you have), perhaps as an alternative to deleting all the relevant localization files or messing with your build settings you can try to edit the list of languages in your XCode project? It's not per target but per project, but it might allow you to exclude languages you don't want in your build. See under Localizations in your project settings (there's a little - icon you can use to remove a language).

这篇关于强制将特定的本地化用于目标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆