I'm trying to use kotlinx datetime in KI but can't...
# kotlinx-datetime
s
I'm trying to use kotlinx datetime in KI but can't figure out the repository to use. has anyone used kotlinx datetime in KI? what repo should i point it to? I've tried a bunch of things but haven't figured out
b
Should be on maven central. Did you add -jvm artefact suffix though?
Kotlin scripting doesn't support gradle metadata
s
this was my first time trying to reference a maven artifact with KI and tried a few urls but didn't find anything that worked. I'll try to add the -jvm option though
so the repo urls I've been trying are
<https://repo.maven.apache.org/maven2/org/jetbrains/kotlinx/kotlinx-datetime-jvm/0.4.0/>
and
<https://repo.maven.apache.org/maven2/org/jetbrains/kotlinx/kotlinx-datetime/0.4.0/>
. I don't see any errors but when I try to use
:dependsOn
, I get
Could not find artifact
errors (the artifact it lists looks weird, for example
DependencyResolutionException: Could not find artifact org.jetbrains.kotlinx:kotlinx-datetime-jvm:jar:0.4.0
.
b
Repo url is not artifact url. Try https://repo.maven.apache.org/maven2 And then dependsOn
org.jetbrains.kotlinx:kotlinx-datetime-jvm:0.4.0
s
that works! thank you!