0

I have custom library with flavors "water" and "blue" :

   flavorDimensions "water", "blue"

   productFlavors 
   {
   water 
   {
    flavorDimensions "water"
   }
   blue
   {
    flavorDimensions "blue"
   }
   }
   configurations 
   {
   waterDebugCompile
   waterReleaseCompile

   blueDebugCompile
   blueReleaseCompile
   }

Both overwrite TestA.class from "main" folder

 TestA.class from "main" has a method that toast "MAIN"
 TestA.class from "water" => "WATER"
 TestA.class from "blue" => "BLUE"

in app i have :

   dependencies {
   implementation project(':mylibrary')
   }

  flavorDimensions "water", "blue"

  productFlavors  {
     water {
        flavorDimensions "water"
        applicationId "com.test.water"
        matchingFallbacks = ['water']

     }
     blue {
        flavorDimensions "blue"
        applicationId "com.test.blue"
        matchingFallbacks = ['blue']
     }
  }

But when i select "blueDebug" variant for may app it toast "MAIN" and not "BLUE" as i am expected

Why ?

Thanks

BejanCorneliu
  • 65
  • 3
  • 13
  • why you have different dimensions? with different dimensions the full name of build would be like `waterBlueDebug` and `blueDebug` would have no sens ... if you wana have `waterDebug` or `blueDebug` then water and blue flav should be in the same dimension – Selvin Apr 17 '18 at 08:11
  • in lib or in app ? – BejanCorneliu Apr 17 '18 at 08:21

0 Answers0