Skip to content

Commit

Permalink
Merge pull request #168 from a1603169/bug-build-issue
Browse files Browse the repository at this point in the history
Bug build issue
  • Loading branch information
KenjiOhtsuka authored Aug 25, 2024
2 parents f7c73ee + 334dc18 commit fbb6f54
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 60 deletions.
5 changes: 0 additions & 5 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,17 @@

buildscript {
repositories {
jcenter()
mavenCentral()
maven("https://plugins.gradle.org/m2/")
}

dependencies {
// for release
classpath("com.novoda:bintray-release:${property("bintray_version")}")
classpath("com.gradle.publish:plugin-publish-plugin:0.9.10")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${property("kotlin_version")}")
//classpath(group = "org.jetbrains.kotlin", name = "kotlin-script-runtime", version = property("kotlin_version") as String)
classpath("org.jetbrains.dokka:dokka-gradle-plugin:0.9.17")
}
}

plugins {
id("com.jfrog.bintray") version "1.8.4" apply false
kotlin("jvm") version "1.4.20" apply false
}
10 changes: 6 additions & 4 deletions document/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,14 @@ version rootProject.version

repositories {
mavenCentral()
jcenter()
maven {
url "https://maven.pkg.jetbrains.space/public/p/kotlinx-html/maven"
}
}

dependencies {
// Fill this in with the version of kotlinx in use in your project
def kotlinx_html_version = "0.6.11"
// Update kotlinx_html version to build
def kotlinx_html_version = "0.7.3"
// include for server side
implementation "org.jetbrains.kotlinx:kotlinx-html-jvm:${kotlinx_html_version}"
implementation 'org.codehaus.groovy:groovy-all:2.3.11'
Expand All @@ -27,4 +29,4 @@ compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}

mainClassName = "com.improve_future.harmonica.document.Main"
mainClassName = "com.improve_future.harmonica.document.Main"
89 changes: 39 additions & 50 deletions gradle-plugin/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,17 @@
* http://opensource.org/licenses/mit-license.php
*/

import com.jfrog.bintray.gradle.BintrayExtension.PackageConfig
import com.jfrog.bintray.gradle.BintrayExtension.VersionConfig
import org.gradle.api.publish.maven.MavenPom
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
import java.util.Date
import java.nio.file.Paths

plugins {
id("com.jfrog.bintray")
id("maven-publish")
id("java-library")
id("com.gradle.plugin-publish")
kotlin("jvm")
id("java-gradle-plugin")
//id("com.novoda.bintray-release")
id("org.jetbrains.dokka")
//jacoco
}
Expand All @@ -30,8 +26,8 @@ version = "2.0.0"

repositories {
mavenCentral()
maven("https://dl.bintray.com/kotlin/exposed")
maven("https://jitpack.io")
maven("https://maven.pkg.jetbrains.space/public/p/kotlinx-html/maven")
}

dependencies {
Expand Down Expand Up @@ -60,6 +56,8 @@ dependencies {

implementation("org.reflections:reflections:0.9.11")

// Latest version of kotlinx-html
implementation("org.jetbrains.kotlinx:kotlinx-html-jvm:0.7.3")

testImplementation("org.jetbrains.kotlin:kotlin-test")
testImplementation("org.jetbrains.kotlin:kotlin-test-junit5")
Expand Down Expand Up @@ -129,34 +127,6 @@ pluginBundle {
}

val githubUrl = "https://github.com/KenjiOhtsuka/harmonica"
bintray {
user = System.getenv("BINTRAY_USER")
key = System.getenv("BINTRAY_KEY")
pkg(closureOf<PackageConfig> {
repo = "m"
name = "Harmonica"
userOrg = "kenjiohtsuka"
setLicenses("GPL-3.0")
vcsUrl = githubUrl

version(closureOf<VersionConfig> {
name = project.version as String
released = Date().toString()
vcsTag = project.version as String
})
})
}

// for Bintray (jcenter)
//publish {
// userOrg = "kenjiohtsuka"
// groupId = project.group
// artifactId = "harmonica" // project.artifacts
// publishVersion = project.version
// desc = "Kotlin Database Migration Took"
// website = "https://github.com/KenjiOhtsuka/harmonica"
// //repoName = ""
//}

val pomConfig: MavenPom.() -> Unit = {
description.set("Kotlin Database Migration Tool")
Expand Down Expand Up @@ -186,23 +156,42 @@ val pomConfig: MavenPom.() -> Unit = {
// Create the publication with the pom configuration:
publishing {
publications {
register<MavenPublication>("MyPublication") {
from(components.getByName("java"))
artifact("sourcesJar")
artifact("javadocJar")
groupId = "com.improve_future"
artifactId = "harmonica"
version = project.version as String
pomConfig(pom)
create<MavenPublication>("mavenJava") {
from(components["java"])
artifact(tasks["sourcesJar"])
artifact(tasks["javadocJar"])

pom {
name.set("Harmonica")
description.set("Kotlin Database Migration Tool")
url.set("https://github.com/KenjiOhtsuka/harmonica")
licenses {
license {
name.set("MIT License")
url.set("http://opensource.org/licenses/mit-license.php")
}
}
developers {
developer {
id.set("kenjiohtsuka")
name.set("Kenji Otsuka")
email.set("[email protected]")
}
}
scm {
url.set("https://github.com/KenjiOhtsuka/harmonica")
}
}
}
register<MavenPublication>("GradlePublication") {
from(components.getByName("java"))
artifact("sourcesJar")
artifact("javadocJar")
groupId = "com.improve_future.harmonica"
artifactId = "gradle-plugin"
version = project.version as String
pomConfig(pom)
}
repositories {
maven {
name = "OSSRH"
url = uri("https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/")
credentials {
username = System.getenv("MAVEN_USERNAME")
password = System.getenv("MAVEN_PASSWORD")
}
}
}
}
}
1 change: 0 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,3 @@
#

kotlin_version=1.4.20
bintray_version=0.8.0

0 comments on commit fbb6f54

Please sign in to comment.