All Projects → jordanjoz1 → android-localization-helper

jordanjoz1 / android-localization-helper

Licence: MIT license
Make sure that you aren't missing string translations in any language, and keep your localized strings organized.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to android-localization-helper

ios2androidres
Copy iOS image resources to their appropriate Android directory
Stars: ✭ 20 (-53.49%)
Mutual labels:  pip, android-tools
Repo
一个基于shell + gradle开发的效率工具,用来优化模块化/组件化分仓后带来的编译和调试痛点,提升开发效率
Stars: ✭ 28 (-34.88%)
Mutual labels:  android-tools
android-layout-inspector
Yet another android layout inspector
Stars: ✭ 69 (+60.47%)
Mutual labels:  android-tools
animec
A module to get data about anime characters, news, info, lyrics and more.
Stars: ✭ 31 (-27.91%)
Mutual labels:  pip
ochrona-cli
A command line tool for detecting vulnerabilities in Python dependencies and doing safe package installs
Stars: ✭ 46 (+6.98%)
Mutual labels:  pip
YoutubeFloatingVideo
Simple Youtube Floating Video Library
Stars: ✭ 37 (-13.95%)
Mutual labels:  pip
samp-server-cli
Control server configuration via command line (without manually editing server.cfg)
Stars: ✭ 14 (-67.44%)
Mutual labels:  pip
poetry-setup
Generate setup.py (setuptools) from pyproject.toml (poetry)
Stars: ✭ 44 (+2.33%)
Mutual labels:  pip
resolvelib
Resolve abstract dependencies into concrete ones
Stars: ✭ 92 (+113.95%)
Mutual labels:  pip
pipm
Python dependency management workflow using setup.cfg and requirements files without reinventing the wheels
Stars: ✭ 30 (-30.23%)
Mutual labels:  pip
pipyuan
pipyuan 内置了国内常用的 pip 源, 你可以快速设置想要的源
Stars: ✭ 30 (-30.23%)
Mutual labels:  pip
My.Jdownloader-API-Python-Library
My.Jdownloader API Python Library
Stars: ✭ 65 (+51.16%)
Mutual labels:  pip
p4python
[Officially Supported] P4Python is a wrapper for the P4 C++ API in Python.
Stars: ✭ 30 (-30.23%)
Mutual labels:  pip
passa
Resolver implementation and toolset for generating and interacting with Pipfile and Pipfile.lock.
Stars: ✭ 54 (+25.58%)
Mutual labels:  pip
index
A PEP 503-compliant Python package index specifically providing wheels built for Alpine Linux
Stars: ✭ 26 (-39.53%)
Mutual labels:  pip
pip-bash-completion
bash autocompletion for pip
Stars: ✭ 74 (+72.09%)
Mutual labels:  pip
Python-Course
🐍 This is the most complete course in Python, completely practical and all the lessons are explained with examples, so that they can be easily understood. 🍫
Stars: ✭ 18 (-58.14%)
Mutual labels:  pip
meta-package-manager
🎁 a wrapper around all package managers
Stars: ✭ 277 (+544.19%)
Mutual labels:  pip
serverless-python-requirements
⚡️🐍📦 Serverless plugin to bundle Python packages
Stars: ✭ 971 (+2158.14%)
Mutual labels:  pip
PyTorch-Model-Compare
Compare neural networks by their feature similarity
Stars: ✭ 119 (+176.74%)
Mutual labels:  pip

Travis build image Coverage Status PyPi version PyPi download count image Android Arsenal Code Climate

android-localization-helper

Python script that checks for missing string translations in your project's localized languages.

Ever lose track of what strings have and haven't been translated in each language? Android Studio made an awesome GUI to help deal with this issue, but there is no easy way to export missing strings, so if you are missing more than a few strings in a language it can become a tenuous problem. Here's a solution!

This python package will output a directory with all the string translations that are missing for each localized values directory. It can also clean-up localized strings.xml to remove translations that are no longer used in the default strings.xml file.

Getting started

Requirements:

Project structure

To install run:

pip install android-localization-helper

Usage

Normal use

cd into your res/ folder, and run:

android-localization-helper

By default, this creates an output directory to_translate/ (sample output) with separate files for the missing strings in each language. Now that you have the untranslated strings for each language in a standard format, you can send them out for translation!

Change output directory (--output)

Use the output option to change the output directory path.

For example, we can output the missing translations into a to_translate/ directory on the Desktop:

android-localization-helper --output ~/Desktop/to_translate

Clean-up translated string files (--clean)

This option will remove strings that aren't in the default file and sort strings to match the default strings.xml order. Warning: this will overwrite your existing localized strings.xml files, so make sure you have a back-up in case of any unexpected changes

android-localization-helper --clean

Use multiple default string sources (--input)

It is recommended that all your translatable strings are in strings.xml. If that's not the case, the input option will allow you to include multiple default string source files. The localized output will still have only one file for each language.

For example, if we had strings.xml and plurals.xml files in our values/ directory, we could make sure those are included as part of our default string source:

android-localization-helper --input strings.xml plurals.xml

Options

-h, --help

Prints help message.

--res

Path to the app's /res folder. Like, ./main/res

By default assumes the current directory

--input

List of file names to include from default values directory (e.g. strings.xml plurals.xml). By default, only strings.xml is used

--output

Output directory path (directory will be created automatically). Like, ~/Desktop/to_translate

By default creates to_translate folder in the current directory.

--clean

Clean the existing string.xml files for each language. This will remove strings that are in the localized language but not in the default language (they presumably got removed from the default langauge). It will also sort the strings so that they are in the same order as the default language.

Release History

  • 2015-07-16   v0.1.4   fix handling same resource name for different types
  • 2015-05-31   v0.1.3   support for multiple default string sources
  • 2015-01-05   v0.1.2   support for more language folders, better feedback and error handling
  • 2015-01-04   v0.1.1   xliff namespace support, better indentation handling
  • 2015-01-03   v0.1.0   Initial release

License

See the LICENSE file for license rights and limitations (MIT).

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].