Plugins renaming: kotlinx-<buildSystem>-serialization-plugin
This commit is contained in:
+4
-4
@@ -46,7 +46,7 @@ If your maven build is failing with Out-Of-Memory errors, set JVM options for ma
|
||||
|
||||
## Kotlin serialization Gradle Plugin
|
||||
|
||||
First, build all the above. Then run `./gradlew :kotlin-serialization:install` to install it to your local maven repository.
|
||||
First, build all the above. Then run `./gradlew :kotlinx-gradle-serialization-plugin:publishToMavenLocal` to install it to your local maven repository.
|
||||
|
||||
When it is installed in local maven repository, you can add it as a dependency in buildscript classpath and apply it:
|
||||
|
||||
@@ -60,13 +60,13 @@ buildscript {
|
||||
|
||||
dependencies {
|
||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.1-SNAPSHOT"
|
||||
classpath "org.jetbrains.kotlinx:kotlin-serialization:0.1"
|
||||
classpath "org.jetbrains.kotlinx:kotlinx-gradle-serialization-plugin:0.1"
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: 'kotlin'
|
||||
apply plugin: 'kotlin-serialization'
|
||||
apply plugin: 'kotlinx-serialization'
|
||||
|
||||
```
|
||||
|
||||
You can also obtain it from bintray: https://bintray.com/kotlin/kotlinx/kotlinx.serialization
|
||||
You can also obtain it from bintray: https://bintray.com/kotlin/kotlinx/kotlinx.serialization.plugin
|
||||
@@ -15,7 +15,7 @@
|
||||
</properties>
|
||||
|
||||
<groupId>org.jetbrains.kotlinx</groupId>
|
||||
<artifactId>kotlin-maven-serialization</artifactId>
|
||||
<artifactId>kotlinx-maven-serialization-plugin</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<version>0.1</version>
|
||||
|
||||
|
||||
+1
-1
@@ -24,7 +24,7 @@ import org.jetbrains.kotlin.maven.*
|
||||
|
||||
val SERIALIZATION_COMPILER_PLUGIN_ID = "org.jetbrains.kotlinx.serialization"
|
||||
|
||||
@Component(role = KotlinMavenPluginExtension::class, hint = "kotlin-serialization")
|
||||
@Component(role = KotlinMavenPluginExtension::class, hint = "kotlinx-serialization")
|
||||
class KotlinSerializationMavenPlugin : KotlinMavenPluginExtension {
|
||||
@Requirement
|
||||
lateinit var logger: Logger
|
||||
|
||||
@@ -47,13 +47,35 @@ jar {
|
||||
from(targetSrc) { include("META-INF/**") }
|
||||
}
|
||||
|
||||
apply plugin: 'maven-publish'
|
||||
|
||||
task sourceJar(type: Jar, dependsOn: classes) {
|
||||
classifier 'sources'
|
||||
from sourceSets.main.allSource
|
||||
}
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
mavenProject(MavenPublication) {
|
||||
from components.java
|
||||
groupId project.group
|
||||
artifactId project.name
|
||||
version project.version
|
||||
|
||||
artifact sourceJar {
|
||||
classifier "sources"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
bintray {
|
||||
user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER')
|
||||
key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : System.getenv('BINTRAY_API_KEY')
|
||||
configurations = ['archives']
|
||||
publications = ['mavenProject']
|
||||
pkg {
|
||||
repo = 'kotlinx'
|
||||
name = 'kotlinx.serialization'
|
||||
name = 'kotlinx.serialization.plugin'
|
||||
userOrg = 'kotlin'
|
||||
licenses = ['Apache-2.0']
|
||||
vcsUrl = 'https://github.com/JetBrains/kotlin/tree/rr/kotlinx.serialization/libraries'
|
||||
|
||||
+1
-1
@@ -38,7 +38,7 @@ class SerializationGradleSubplugin : Plugin<Project> {
|
||||
class SerializationKotlinGradleSubplugin : KotlinGradleSubplugin<AbstractCompile> {
|
||||
companion object {
|
||||
val SERIALIZATION_GROUP_NAME = "org.jetbrains.kotlinx"
|
||||
val SERIALIZATION_ARTIFACT_NAME = "kotlin-serialization"
|
||||
val SERIALIZATION_ARTIFACT_NAME = "kotlinx-gradle-serialization-plugin"
|
||||
}
|
||||
|
||||
override fun isApplicable(project: Project, task: AbstractCompile) = SerializationGradleSubplugin.isEnabled(project)
|
||||
|
||||
Reference in New Issue
Block a user