No, this has not been fixed so far, also see https://code.google.com/p/android/issues/detail?id=208474
On Tuesday, February 10, 2015 at 1:38:09 AM UTC+1, Marcelo Benites wrote: > > I am currently trying to add dependencies in afterEvaluate as well. Is it > fixed? Is there any workaround for that? > > On Thursday, February 6, 2014 at 8:09:34 AM UTC-2, Alexander Osmanov wrote: >> >> Thank you for your response Xavier. Then I'll wait for fixes :) >> >> On Thursday, February 6, 2014 3:10:15 AM UTC+1, Xavier Ducrohet wrote: >>> >>> It's not currently possible due to how we process dependencies, unless, >>> maybe, you apply your plugin before the android one (in order to have its >>> afterEvaluate be called before ours). This would be very fragile though. >>> >>> There's work being done to fix this but it's going to be a few months at >>> least. >>> >>> >>> On Wed, Feb 5, 2014 at 3:39 PM, Alexander Osmanov <[email protected]> >>> wrote: >>> >>>> Hi, >>>> >>>> I am writing a Gradle plugin that would add compile dependencies >>>> based on values I declare in extension. More specifically in extension I >>>> declare a version of a lib I want to be added. So like this: >>>> >>>> awslibs { >>>> awslib1 { >>>> version '1.0.0' >>>> } >>>> } >>>> >>>> However in plugin "apply" method this extension object is not yet >>>> populated, i. e. empty. I try to read it's values in afterEvaluate and add >>>> dependencies. It works great with Gradle (i. e. command line gradle run) >>>> but not with Android studio. I suspect it fetches dependecies only once >>>> and >>>> before I add new one. >>>> >>>> Is there a way to add dependency so AS could see it or is there any API >>>> for adding dependencies planned (similar to recent API for adding >>>> generated >>>> code folders to model)? >>>> >>>> Thanks, >>>> Alex. >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "adt-dev" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to [email protected]. >>>> For more options, visit https://groups.google.com/groups/opt_out. >>>> >>> >>> >>> >>> -- >>> Xavier Ducrohet >>> Android SDK Tech Lead >>> Google Inc. >>> http://developer.android.com | http://tools.android.com >>> >>> Please do not send me questions directly. Thanks! >>> >> -- You received this message because you are subscribed to the Google Groups "adt-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
