Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 2 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,11 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up JDK 8
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: 8

- name: Grant execute permission for compile/gradlew
working-directory: ./compile
run: chmod +x gradlew
java-version: 21

- name: Grant execute permission for compile-java-test/gradlew
working-directory: ./compile-java-test
Expand All @@ -37,7 +33,6 @@ jobs:
run: chmod +x gradlew

- name: Build plugin
working-directory: ./compile
run: ./gradlew build

- name: Test plugin against Java
Expand All @@ -54,13 +49,11 @@ jobs:

- name: Set version
id: set-version
working-directory: ./compile
run: ./gradlew properties | grep "^version:" | awk '{print $2}' | { read v; echo "::set-output name=version::$v"; }

- name: Print version
run: echo ${{ steps.set-version.outputs.version }}

- name: Publish plugin
if: github.event_name == 'push' && endsWith(steps.set-version.outputs.version, 'SNAPSHOT') == false
working-directory: ./compile
run: ./gradlew publishPlugins -Pgradle.publish.key=${{ secrets.GRADLE_PUBLISH_KEY }} -Pgradle.publish.secret=${{ secrets.GRADLE_PUBLISH_SECRET }}
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,3 @@
/.metadata
/.idea/
.factorypath
.sdkmanrc
4 changes: 4 additions & 0 deletions .sdkmanrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Enable auto-env through the sdkman_auto_env config
# Add key=value pairs of SDKs to use below
java=21-zulu

21 changes: 21 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
plugins {
java
id("net.researchgate.release") version "3.0.2"
}

configure<net.researchgate.release.ReleaseExtension> {
newVersionCommitMessage.set("[Gradle Release Plugin] - [skip ci] new version commit: ")
tagTemplate.set("v\$version")
git {
requireBranch.set("master")
}
}

allprojects {
apply(plugin = "java")
tasks {
test {
useJUnitPlatform()
}
}
}
14 changes: 8 additions & 6 deletions compile-java-test/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,16 @@ buildscript {
}
}

apply plugin: 'java'
plugins {
id 'java'
}

apply plugin: 'org.domaframework.doma.compile'

ext.domaVersion = '2.29.0'
ext.domaVersion = '3.0.0'

java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
toolchain.languageVersion.set(JavaLanguageVersion.of( 17))
}

test {
Expand All @@ -30,8 +32,8 @@ repositories {
}

dependencies {
annotationProcessor "org.seasar.doma:doma:$domaVersion"
implementation "org.seasar.doma:doma:$domaVersion"
annotationProcessor "org.seasar.doma:doma-processor:$domaVersion"
implementation "org.seasar.doma:doma-core:$domaVersion"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.11.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.11.1'
}
2 changes: 1 addition & 1 deletion compile-java-test/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
23 changes: 11 additions & 12 deletions compile-kotlin-test/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,26 +6,25 @@ buildscript {
}
dependencies {
classpath "org.domaframework.doma:compile"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.7.22"
}
}

plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm' version '2.0.20'
id 'org.jetbrains.kotlin.kapt' version '2.0.20'
}

apply plugin: 'org.domaframework.doma.compile'
apply plugin: 'kotlin'
apply plugin: 'kotlin-kapt'

ext.domaVersion = '2.29.0'
ext.domaVersion = '3.0.0'

kapt {
includeCompileClasspath = false
}

compileKotlin {
kotlinOptions.jvmTarget = '1.8'
}

compileTestKotlin {
kotlinOptions.jvmTarget = '1.8'
java {
toolchain.languageVersion.set(JavaLanguageVersion.of(17))
}

test {
Expand All @@ -39,8 +38,8 @@ repositories {
}

dependencies {
kapt "org.seasar.doma:doma:$domaVersion"
implementation "org.seasar.doma:doma:$domaVersion"
kapt "org.seasar.doma:doma-processor:$domaVersion"
implementation "org.seasar.doma:doma-core:$domaVersion"
implementation "org.jetbrains.kotlin:kotlin-stdlib"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.11.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.11.1'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
24 changes: 11 additions & 13 deletions compile-mix-test/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,25 @@ buildscript {
}
dependencies {
classpath "org.domaframework.doma:compile"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.7.22"
}
}

plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm' version '2.0.20'
id 'org.jetbrains.kotlin.kapt' version '2.0.20'
}

apply plugin: 'org.domaframework.doma.compile'
apply plugin: 'java'
apply plugin: 'kotlin'
apply plugin: 'kotlin-kapt'

ext.domaVersion = '2.29.0'
ext.domaVersion = '3.0.0'

kapt {
includeCompileClasspath = false
}

compileKotlin {
kotlinOptions.jvmTarget = '1.8'
}

compileTestKotlin {
kotlinOptions.jvmTarget = '1.8'
java {
toolchain.languageVersion.set(JavaLanguageVersion.of( 17))
}

test {
Expand All @@ -40,8 +38,8 @@ repositories {
}

dependencies {
kapt "org.seasar.doma:doma:$domaVersion"
implementation "org.seasar.doma:doma:$domaVersion"
kapt "org.seasar.doma:doma-processor:$domaVersion"
implementation "org.seasar.doma:doma-core:$domaVersion"
implementation "org.jetbrains.kotlin:kotlin-stdlib"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.11.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.11.1'
Expand Down
2 changes: 1 addition & 1 deletion compile-mix-test/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
60 changes: 0 additions & 60 deletions compile/build.gradle

This file was deleted.

68 changes: 68 additions & 0 deletions compile/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
plugins {
id("groovy")
id("java-gradle-plugin")
id("com.gradle.plugin-publish") version "1.3.0"
id("com.diffplug.spotless") version "6.25.0"
}

gradlePlugin {
website.set("https://github.com/domaframework/doma-compile-plugin")
vcsUrl.set("https://github.com/domaframework/doma-compile-plugin.git")
plugins {
create("compilePlugin") {
id = "org.domaframework.doma.compile"
displayName = "Doma Compile Plugin"
description = "Allows annotation processors to read Doma resources at compile-time"
implementationClass = "org.seasar.doma.gradle.compile.CompilePlugin"
tags.set(listOf("doma", "compile", "annotation-processing"))
}
}
}

sourceSets {
main {
java {
setSrcDirs(emptyList<String>())
}
groovy {
setSrcDirs(listOf("src/main/groovy", "src/main/java"))
}
}
}

spotless {
java {
googleJavaFormat("1.23.0")
}
}

java {
toolchain.languageVersion.set(JavaLanguageVersion.of(17))
}

repositories {
mavenCentral()
}

dependencies {
testImplementation("org.junit.jupiter:junit-jupiter-api:5.11.1")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.11.1")
}

tasks {
test {
useJUnitPlatform()
}

javadoc {
enabled = false
}

groovydoc {
enabled = false
}

build {
dependsOn(spotlessApply)
}
}
1 change: 0 additions & 1 deletion compile/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
group=org.domaframework.doma
version=2.0.1-SNAPSHOT
Binary file removed compile/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
5 changes: 0 additions & 5 deletions compile/gradle/wrapper/gradle-wrapper.properties

This file was deleted.

Loading
Loading