android-localization-helper


Source link: https://github.com/jordanjoz1/android-localization-helper

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:

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).

Resources

A smart seek bar for android with multiple junction points at random seek position.

Fastest way to run your gradle tasks.

RubberStamp is an Android library that makes it easy for you to add a watermark to your images.

Features

  • Add a watermark to your images.
  • It can be text or another image.
  • Multiple ways and features to customize how the watermark looks including attributes like font, color, opacity, size, shadow properties, etc.
  • Flexible API that has multiple pre-defined options to get started quickly.
  • Ability to tile your watermark across an image.

This example describes how use Espresso in Android-Kotlin using MVP, Dagger2, Retrofit.

A set of RxJava2 Extensions to get/set values of SharedPreferences in a super simple way.

Tempo is a Kotlin library for Android to get the current time from multiple sources: SNTP, GPS; or your own time source.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes