Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
Vampire committed Sep 15, 2024
1 parent 7f4d362 commit 851fd13
Show file tree
Hide file tree
Showing 12 changed files with 1,123 additions and 150 deletions.
2 changes: 2 additions & 0 deletions gradle/build-logic/build-logic.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,14 @@ plugins {

dependencies {
implementation(files(libs.javaClass.superclass.protectionDomain.codeSource.location))
implementation(files(kotlinWrappers.javaClass.superclass.protectionDomain.codeSource.location))
implementation(plugin(libs.plugins.versions))
implementation(plugin(libs.plugins.dependency.analysis))
implementation(plugin(libs.plugins.release))
implementation(plugin(libs.plugins.grgit))
implementation(plugin(libs.plugins.github))
implementation(plugin(libs.plugins.kotlin.multiplatform))
implementation(plugin(libs.plugins.kotlin.jsPlainObjects))
implementation(":dependency-updates-report-aggregation")
implementation(libs.build.inject)
implementation(libs.build.github.api)
Expand Down
6 changes: 5 additions & 1 deletion gradle/build-logic/settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,13 @@ dependencyResolutionManagement {
repositoriesMode.set(FAIL_ON_PROJECT_REPOS)

versionCatalogs {
create("libs") {
val libs by registering {
from(files("../libs.versions.toml"))
}

val kotlinWrappers by registering {
from("org.jetbrains.kotlin-wrappers:kotlin-wrappers-catalog:0.0.1-pre.807")
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,17 @@ package net.kautler

import net.kautler.util.npm
import org.gradle.accessors.dm.LibrariesForLibs
import org.gradle.accessors.dm.LibrariesForKotlinWrappers
import org.jetbrains.kotlin.gradle.targets.js.nodejs.NodeJsExec
import org.jetbrains.kotlin.gradle.tasks.IncrementalSyncTask

plugins {
kotlin("multiplatform")
kotlin("plugin.js-plain-objects")
}

val libs = the<LibrariesForLibs>()
val kotlinWrappers = the<LibrariesForKotlinWrappers>()

kotlin {
js {
Expand All @@ -37,10 +40,10 @@ kotlin {
sourceSets {
jsMain {
dependencies {
implementation(libs.build.kotlin.jsPlainObjects)
implementation(libs.kotlinx.coroutines.core)
implementation(dependencies.platform(libs.kotlin.wrappers.bom))
implementation(libs.kotlin.wrapper.js)
implementation(libs.kotlin.wrapper.node)
implementation(kotlinWrappers.js)
implementation(kotlinWrappers.node)
implementation(npm(libs.build.vercel.ncc))
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ package net.kautler
import net.kautler.dao.action.GitHubAction
import net.kautler.util.npm
import org.gradle.accessors.dm.LibrariesForLibs
import org.gradle.accessors.dm.LibrariesForKotlinWrappers
import org.jetbrains.kotlin.gradle.targets.js.nodejs.NodeJsExec
import org.jetbrains.kotlin.gradle.targets.js.nodejs.NodeJsRootExtension
import org.jetbrains.kotlin.gradle.tasks.IncrementalSyncTask
Expand All @@ -29,6 +30,7 @@ plugins {
}

val libs = the<LibrariesForLibs>()
val kotlinWrappers = the<LibrariesForKotlinWrappers>()

kotlin {
js {
Expand All @@ -41,10 +43,9 @@ kotlin {
jsMain {
dependencies {
implementation(libs.kotlinx.coroutines.core)
implementation(dependencies.platform(libs.kotlin.wrappers.bom))
implementation(libs.kotlin.wrapper.actions.toolkit)
implementation(libs.kotlin.wrapper.js)
implementation(libs.kotlin.wrapper.node)
implementation(kotlinWrappers.actions.toolkit)
implementation(kotlinWrappers.js)
implementation(kotlinWrappers.node)
implementation(npm(libs.semver))
implementation(npm(libs.nullWritable))
}
Expand Down
7 changes: 2 additions & 5 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ build-node = "20.11.0"
build-snakeyaml = "2.0"
build-vercel-ncc = "0.36.1"
kotlin = "2.0.20"
kotlin-wrappers = "1.0.0-pre.529"
kotlinx-coroutines = "1.6.4"
nullWritable = "1.0.5"
semver = "7.3.8"
Expand All @@ -35,15 +34,12 @@ workflows-kotlin = "2.0.20"
[libraries]
build-github-api = { module = "org.kohsuke:github-api", version.ref = "build-github-api" }
build-inject = { module = "javax.inject:javax.inject", version.ref = "build-inject" }
build-kotlin-jsPlainObjects = { module = "org.jetbrains.kotlin:kotlin-js-plain-objects" }
build-kotlinx-serialization-bom = { module = "org.jetbrains.kotlinx:kotlinx-serialization-bom", version.ref = "build-kotlinx-serialization" }
build-kotlinx-serialization-core = { module = "org.jetbrains.kotlinx:kotlinx-serialization-core" }
build-kotlinx-serialization-json = { module = "org.jetbrains.kotlinx:kotlinx-serialization-json" }
build-snakeyaml = { module = "org.yaml:snakeyaml", version.ref = "build-snakeyaml" }
build-vercel-ncc = { module = "vercel:ncc", version.ref = "build-vercel-ncc" }
kotlin-wrapper-actions-toolkit = { module = "org.jetbrains.kotlin-wrappers:kotlin-actions-toolkit" }
kotlin-wrapper-js = { module = "org.jetbrains.kotlin-wrappers:kotlin-js" }
kotlin-wrapper-node = { module = "org.jetbrains.kotlin-wrappers:kotlin-node" }
kotlin-wrappers-bom = { module = "org.jetbrains.kotlin-wrappers:kotlin-wrappers-bom", version.ref = "kotlin-wrappers" }
kotlinx-coroutines-core = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "kotlinx-coroutines" }
nullWritable = { module = "<unscoped>:null-writable", version.ref = "nullWritable" }
semver = { module = "<unscoped>:semver", version.ref = "semver" }
Expand All @@ -63,6 +59,7 @@ dependency-analysis = { id = "com.autonomousapps.dependency-analysis", version.r
github = { id = "net.wooga.github", version.ref = "build-gradle-plugin-github" }
grgit = { id = "org.ajoberstar.grgit.service", version.ref = "build-gradle-plugin-grgit" }
kotlin-multiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" }
kotlin-jsPlainObjects = { id = "org.jetbrains.kotlin.plugin.js-plain-objects", version.ref = "kotlin" }
refresh-versions = { id = "de.fayard.refreshVersions", version.ref = "build-gradle-plugin-refresh-versions" }
release = { id = "net.researchgate.release", version.ref = "build-gradle-plugin-release" }
versions = { id = "com.github.ben-manes.versions", version.ref = "build-gradle-plugin-versions" }
Loading

0 comments on commit 851fd13

Please sign in to comment.