https://kotlinlang.org logo
Title
e

Emil Kantis

06/15/2021, 7:26 PM
When in a JVM project, what makes gradle/maven pull in
kotest-*-jvm
rather than just
kotest-*
? I have noticed I have an issue where
kotest-runner-junit5
is pulled in as
kotest-runner-junit5-jvm
but
kotest-assertions-json
is just added as-is and I can't use it as a result.. 😕
s

sam

06/15/2021, 7:29 PM
Gradle knows because of this "attribute" thing it supports
the kotlin gradle plugin is configuring it behind the scenes
e

Emil Kantis

06/15/2021, 7:30 PM
hmm, okay
s

sam

06/15/2021, 7:30 PM
You can always force it by adding -jvm to the dependency
e

Emil Kantis

06/15/2021, 7:31 PM
yeah, I did that for now.. just confused why: • it's working in 1 project but not another 1 • why all other kotest dependencies are added correctly, but not this one
some gradle cache issue perhaps..
s

sam

06/15/2021, 7:34 PM
perhaps, I think its all a bit black magic
and in general I think gradle is the worst designed API/DSL on the planet
worse even than sbt
e

Emil Kantis

06/15/2021, 7:36 PM
but you still use it for kotest iirc? 🙂 personally I like it, I can't stand the verbosity of maven..
But I've seen how some abuse the extensibility of gradle to make it a nightmare..
s

sam

06/15/2021, 7:37 PM
I use it because you need to if you want a multi platform project
and it's not even the extensibility for me. It's the fact the DSL is so badly designed with confusing nomenclature, then combined with the disaster that is groovy
s

Sourabh Rawat

06/15/2021, 8:01 PM
@sam do we(generally speaking) have a better build system than gradle? I am not very experienced other build systems. I tried maven in some projects. Immediately, wrote a migration to gradle. But yes, groovy was a bad bad choice.
s

sam

06/15/2021, 8:04 PM
I prefer maven because it's declarative so you don't have the power of a full language, but that's an unpopular opinion because... Xml I guess?
s

Sourabh Rawat

06/15/2021, 8:09 PM
XML yeah. A pom.xml just feel bloated with tags to me.
s

sam

06/15/2021, 8:10 PM
they could support yml
:also-yes: 1