0

On our Android app we're passing strings resources via build script using the resValue, something like this:

android {
    compileSdkVersion 25
    buildToolsVersion "25.0.2"

    defaultConfig {
       resValue "string", "foo", "foo_value"
       resValue "string", "bar", "bar_value"
       ... etc

How to add translated version of those strings. To go on values-de, values-ch, values-sp, etc folders?

Budius
  • 39,391
  • 16
  • 102
  • 144
  • maybe [this one](http://stackoverflow.com/questions/36105494/localizing-string-resources-added-via-build-gradle-using-resvalue) helps? – Blackbelt Feb 07 '17 at 12:01
  • @Blackbelt not really. We're trying to inject values via CI, so in reality the values are coming from a `System.getenv(key)` command. Maybe I'll check into just download a complete `.xml` and replace in the project. – Budius Feb 07 '17 at 14:02

1 Answers1

0

Apparently it is not possible to do it from the gradle file as mentioned here.
If you just want to use the values, better use the buildConfigField instead

Community
  • 1
  • 1
psykid
  • 418
  • 5
  • 15