Skip to content

Commit

Permalink
Merge pull request #25 from jburel/dependency
Browse files Browse the repository at this point in the history
Dependency
  • Loading branch information
jburel authored Nov 18, 2024
2 parents 6f8ed82 + b37092e commit 12b1822
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 89 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

jobs:
build:
uses: ome/action-workflows/.github/workflows/gradle_build.yml@v2.1
uses: ome/action-workflows/.github/workflows/gradle_build.yml@main
publish_snapshots:
if: ${{ github.ref == 'refs/heads/master' && github.repository_owner == 'ome' }}
needs: build
Expand Down
26 changes: 13 additions & 13 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,26 @@ kotlinDslPluginOptions {

repositories {
mavenCentral()
gradlePluginPortal()
maven {
setUrl("https://artifacts.openmicroscopy.org/artifactory/maven")
}
}

java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8

allprojects {
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
kotlinOptions {
jvmTarget = JavaVersion.VERSION_1_8.toString()
}
}
}

dependencies {
implementation(kotlin("gradle-plugin"))
implementation("org.jfrog.buildinfo:build-info-extractor-gradle:4.9.3")
implementation("org.ajoberstar:grgit:1.9.1") {
setForce(true)
}
implementation("org.ajoberstar:gradle-git:1.7.1")
implementation("org.ajoberstar:gradle-git-publish:0.3.3")
implementation("org.ajoberstar.grgit:grgit-core:5.3.0")
implementation("org.ajoberstar.grgit:grgit-gradle:5.3.0")
implementation("org.ajoberstar.git-publish:gradle-git-publish:4.2.2")
}

gradlePlugin {
Expand Down Expand Up @@ -57,9 +61,5 @@ gradlePlugin {
id = "org.openmicroscopy.plugin-publishing"
implementationClass = "org.openmicroscopy.PluginPublishingPlugin"
}
register("release-plugin") {
id = "org.openmicroscopy.release"
implementationClass = "org.openmicroscopy.ReleasePlugin"
}
}
}
18 changes: 7 additions & 11 deletions buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,19 @@ kotlinDslPluginOptions {
experimentalWarning.set(false)
}

configure<JavaPluginConvention> {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}

repositories {
jcenter()
maven {
setUrl("https://artifacts.openmicroscopy.org/artifactory/maven")
}
mavenCentral()
}

dependencies {
implementation(kotlin("gradle-plugin"))
implementation("org.jfrog.buildinfo:build-info-extractor-gradle:4.9.3")
implementation("org.ajoberstar:grgit:1.9.1") {
setForce(true)
}
implementation("org.ajoberstar:gradle-git:1.7.1")
implementation("org.ajoberstar:gradle-git-publish:0.3.3")
implementation("org.ajoberstar.grgit:grgit-core:5.3.0")
implementation("org.ajoberstar.grgit:grgit-gradle:5.3.0")
implementation("org.ajoberstar.git-publish:gradle-git-publish:4.2.2")
}

gradlePlugin {
Expand Down
11 changes: 9 additions & 2 deletions buildSrc/src/main/kotlin/org/openmicroscopy/PluginHelper.kt
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package org.openmicroscopy

import com.google.common.base.CaseFormat
import org.gradle.api.Action
import org.gradle.api.Project
import org.gradle.api.artifacts.Configuration
Expand Down Expand Up @@ -98,7 +97,15 @@ class PluginHelper {
}

fun Project.camelCaseName(): String {
return CaseFormat.LOWER_HYPHEN.to(CaseFormat.LOWER_CAMEL, name)
val builder = StringBuilder()
for (v in name.split("-")) {
if (builder.toString() == "") {
builder.append(v)
} else {
builder.append(v.substring(0, 1).toUpperCase()).append(v.substring(1))
}
}
return builder.toString()
}
}

Expand Down
62 changes: 0 additions & 62 deletions src/main/kotlin/org/openmicroscopy/ReleasePlugin.kt

This file was deleted.

0 comments on commit 12b1822

Please sign in to comment.