Skip to content

Commit

Permalink
Move remaining publish properties to plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
drewhamilton committed Dec 16, 2023
1 parent c84bdea commit c05be74
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 21 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package dev.drewhamilton.poko.build

import com.vanniktech.maven.publish.MavenPublishBaseExtension
import com.vanniktech.maven.publish.SonatypeHost
import org.gradle.api.Action
import org.gradle.api.Plugin
import org.gradle.api.Project
Expand Down Expand Up @@ -48,7 +49,38 @@ class PokoBuildPlugin : Plugin<Project> {

pom {
name.set(pomName)

description.set("A Kotlin compiler plugin for generating equals, hashCode, and toString for plain old Kotlin objects.")
url.set("https://github.com/drewhamilton/Poko")

licenses {
license {
name.set("The Apache Software License, Version 2.0")
url.set("https://www.apache.org/licenses/LICENSE-2.0.txt")
distribution.set("repo")
}
}

scm {
url.set("https://github.com/drewhamilton/Poko/tree/main")
connection.set("scm:git:github.com/drewhamilton/Poko.git")
developerConnection.set("scm:git:ssh://github.com/drewhamilton/Poko.git")
}

developers {
developer {
id.set("drewhamilton")
name.set("Drew Hamilton")
email.set("[email protected]")
}
}
}

signAllPublications()
publishToMavenCentral(
host = SonatypeHost.DEFAULT,
automaticRelease = true,
)
}

project.pluginManager.apply("org.jetbrains.dokka")
Expand Down
21 changes: 0 additions & 21 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,6 @@ kotlin.code.style=official
PUBLISH_GROUP=dev.drewhamilton.poko
PUBLISH_VERSION=0.16.0-SNAPSHOT

#region More publish info
RELEASE_SIGNING_ENABLED=true
SONATYPE_HOST=DEFAULT
SONATYPE_AUTOMATIC_RELEASE=true

POM_DESCRIPTION=A Kotlin compiler plugin for generating equals, hashCode, and toString for plain old Kotlin objects.
POM_URL=https://github.com/drewhamilton/Poko

POM_LICENSE_NAME=The Apache Software License, Version 2.0
POM_LICENSE_URL=https://www.apache.org/licenses/LICENSE-2.0.txt
POM_LICENSE_DIST=repo

POM_SCM_URL=https://github.com/drewhamilton/Poko/tree/main
POM_SCM_CONNECTION=scm:git:github.com/drewhamilton/Poko.git
POM_SCM_DEV_CONNECTION=scm:git:ssh://github.com/drewhamilton/Poko.git

POM_DEVELOPER_ID=drewhamilton
POM_DEVELOPER_NAME=Drew Hamilton
POM_DEVELOPER_EMAIL=[email protected]
#endregion

# Uncomment to enable snapshot dependencies:
#snapshots_repository=https://oss.sonatype.org/content/repositories/snapshots
# Uncomment to enable dev versions of Kotlin dependencies:
Expand Down

0 comments on commit c05be74

Please sign in to comment.