【发布时间】:2016-03-07 11:35:08
【问题描述】:
编辑:
在下面查看我的答案:apktool 完成了这项工作。
编辑:
来自 Hanno Binder 的评论:
"显然,-c 选项仅在 p[ackaging] 资源时有效,而不是在提取资源时有效。"
我尝试使用“aapt”工具从 apk 中提取 fr 字符串。
我能够像这样获得所有资源:
.\android-sdks\build-tools\23.0.2\aapt.exe d --values resources my.apk > resources.all.txt
我只想获取给定语言环境的资源,例如 fr(法语)。关于这一点,aapt 文档指出:
-c specify which configurations to include. The default is all
configurations. The value of the parameter should be a comma
separated list of configuration values. Locales should be specified
as either a language or language-region pair. Some examples:
en
port,en
port,land,en_US
所以我尝试了
.\android-sdks\build-tools\23.0.2\aapt.exe d -c fr --values resources my.apk > resources.fr。 txt
但输出仍包含 all 配置 (/locales) 的字符串。
问题:
我该怎么办?
注意:
我很确定 apk 确实包含 fr 数据,因为我使用以下方式获取 apk 配置:
.\android-sdks\build-tools\23.0.2\aapt.exe d --values configurations my.apk >configurations.txt
并且 fr 在配置列表中。 (另外,我在资源中看到了一些 fr 字符串。all.txt)
【问题讨论】:
-
显然
-c选项只对p[ackaging]资源有效,对提取无效。 -
感谢更新
标签: android internationalization resources apk