https://kotlinlang.org logo
#announcements
Title
# announcements
m

myanmarking

06/19/2017, 5:09 PM
is there any way of applying the kotlin plugin in every module without the need to apply plugin: ‘kotlin-android’ ?
h

h0tk3y

06/19/2017, 5:12 PM
myanmarking: something like
Copy code
subprojects { 
    apply plugin: 'kotlin-android'
}
m

myanmarking

06/19/2017, 5:13 PM
Copy code
Error:(28, 0) Extension with name ‘android’ does not exist. Currently registered extension names: [ext, kotlin]
for some reason, i can’t
h

h0tk3y

06/19/2017, 5:16 PM
@myanmarking Try
subprojects { afterEvaluate { apply plugin: 'kotlin-android' } }
, but then in your subprojects buildscripts you'll have to configure Kotlin in
afterEvaluate { ... }
blocks as well, if you need.
m

myanmarking

06/19/2017, 5:16 PM
ok. thanks for your hellp
r

restioson

06/19/2017, 6:11 PM
I wonder if this would work if you used the new plugin syntax?