https://kotlinlang.org logo
Title
b

Bernhard

08/05/2018, 2:11 PM
just move that one out of the ext block as well?
c

Czar

08/05/2018, 2:12 PM
I don't understand the question.
b

Bernhard

08/05/2018, 2:13 PM
thats what I've got so far
so the stuff inside the builscript.ext block, where do I move that?
if I move it outside like https://dpaste.de/KkXa it fails with unresolved references
c

Czar

08/05/2018, 2:15 PM
In groovy file you're assigning values, but in kotlin you're trying to retrieve them
b

Bernhard

08/05/2018, 2:15 PM
from where? settings.gradle.kts?
c

Czar

08/05/2018, 2:16 PM
ext {
    kotlinVersion = '1.2.60'
}
would be the same as:
extra["kotlinVersion"] = "1.2.60"
b

Bernhard

08/05/2018, 2:16 PM
aaaaaaaah
c

Czar

08/05/2018, 2:16 PM
ext is a map
or Properties (don't remember)
Best practice though is to use a Versions object from
buildSrc
instead of
extra
This way you get auto-completion and Ctrl+clicks 🙂
b

Bernhard

08/05/2018, 2:21 PM
just starting out with gradle so I have very little knowledge yet. Still simpler than maven
c

Czar

08/05/2018, 2:23 PM
There are examples in the blog at the link I posted above
b

Bernhard

08/05/2018, 2:26 PM
hm, kinda looks like a hack
nonetheless thank you
c

Czar

08/05/2018, 2:27 PM
If you're just starting out I'd suggest to work through gradle docs: https://gradle.org/guides/#getting-started Actually using ext is a hack 🙂 buildSrc is way to go with gradle 😄
You're welcome
b

Bernhard

08/05/2018, 2:28 PM
I see 😞
🙂