Skip to content

Commit

Permalink
add javadoc and gpg signing
Browse files Browse the repository at this point in the history
  • Loading branch information
mscheong01 committed Apr 2, 2023
1 parent 3b60417 commit b882de7
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ on:
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.OSSRH_GPG_SECRET_KEY }}
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }}

jobs:
deploy:
Expand Down
10 changes: 10 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ plugins {
id("com.google.protobuf") version "0.9.2" apply false
`maven-publish`
id("org.jlleitschuh.gradle.ktlint") version "11.3.1"
signing
}

group = "io.github.mscheong01"
Expand Down Expand Up @@ -115,3 +116,12 @@ tasks.create("updateVersion") {
}
}
}

if (project.hasProperty("releaseVersion")) {
signing {
val signingKey: String? by project
val signingPassword: String? by project
useInMemoryPgpKeys(signingKey, signingPassword)
sign(publishing.publications)
}
}
1 change: 1 addition & 0 deletions core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ dependencies {

java {
withSourcesJar()
withJavadocJar()
}

publishing {
Expand Down
1 change: 0 additions & 1 deletion example/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ dependencies {
}

protobuf {

protoc {
artifact = "com.google.protobuf:protoc:${rootProject.ext["protobufVersion"]}"
}
Expand Down
4 changes: 4 additions & 0 deletions generator/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ plugins {
application
}

java {
withJavadocJar()
}

application {
mainClass.set("io.github.mscheong01.krotodc.MainExecutor")
}
Expand Down

0 comments on commit b882de7

Please sign in to comment.