Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/osfunapps/os_android_strings_extractor-py

This module will extract an Android strings.xml file to a nice excel (xlsx) file, in order to prepare it for translation
https://github.com/osfunapps/os_android_strings_extractor-py

android automation excel osfunapps python strings tools translation utils xls xlsx xml

Last synced: 2 months ago
JSON representation

This module will extract an Android strings.xml file to a nice excel (xlsx) file, in order to prepare it for translation

Awesome Lists containing this project

README

        

Introduction
------------
This project's aim is to help with the translation of an Android app.
It will extract the strings.xml file of an app to a nice readable xlsx file, which can be sent to translators to work on.

If, after the translators will finish translating the file, you also interested in converting the translated file back to a strings.xml file,
use the complementary library ([os_android_strings_importer-py](https://github.com/osfunapps/os_android_strings_importer-py))

## Installation
Install via pip:

pip install os_android_strings_extractor

## Usage

Say you have this *strings.xml* file:
```xml

Memorizer
Capital
Country
Add List
Settings
Lists Settings
Save
DELETE
%1$s Entries
%1$s Entry
Like: Date In History
To: Event
Like: Spanish
To: Hebrew
Go
total entries: %1$s
hard entries: %1$s
Lists

```
Convert it to a readable excel file:

```python
from os_android_strings_extractor import strings_extractor

strings_extractor.extract_to_xlsx(strings_file_path='/path/to/strings.xml',
output_path='/your/output/file.xlsx',
src_language='English',
languages_list=['French', 'German', 'Hindi'])
```

And you will get the output:
![Alt text](os_android_strings_extractor/example_img.png?raw=true "Title")
(notice the worksheets at the bottom -> 'French', 'German', 'Hindi')


## Links
[os_android_strings_importer-py](https://github.com/osfunapps/os_android_strings_importer-py) -> Will import an xlsx file (made by os_android_strings_extractor) and convert it to an Android strings.xml file, after translation.

## Licence
MIT