-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update to latest Grade 6 version, worker configuration changed
- Loading branch information
Showing
10 changed files
with
313 additions
and
261 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
# This workflow will build a Java project with Gradle | ||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle | ||
|
||
name: Run build and tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
environment: CIRelease | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Set up JDK 1.8 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 1.8 | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- run: git fetch --all --tags | ||
|
||
- name: Create .gradle dir | ||
run: mkdir -p $HOME/.gradle | ||
- name: Install gpg secret key | ||
env: | ||
SIGNINGFILE: ${{ secrets.SIGNINGFILE }} | ||
run: | | ||
cat <(echo -e "${{ secrets.SIGNINGFILE }}") | gpg --batch --import | ||
gpg --list-secret-keys --keyid-format LONG | ||
- name: Export gpg file | ||
env: | ||
SIGNINGKEYID: ${{ secrets.SIGNINGKEYID }} | ||
SIGNINGPASSWORD: ${{ secrets.SIGNINGPASSWORD }} | ||
run: | | ||
gpg --batch --passphrase="$SIGNINGPASSWORD" --pinentry-mode loopback --export-secret-keys $SIGNINGKEYID > $HOME/.gradle/secrets.gpg | ||
- name: Create gradle sproperties | ||
env: | ||
APIKEY: ${{ secrets.APIKEY }} | ||
APISECRET: ${{ secrets.APISECRET }} | ||
SIGNINGKEYID: ${{ secrets.SIGNINGKEYID }} | ||
SIGNINGPASSWORD: ${{ secrets.SIGNINGPASSWORD }} | ||
SONATYPEPASSWORD: ${{ secrets.SONATYPEPASSWORD }} | ||
SONATYPEUSER: ${{ secrets.SONATYPEUSER }} | ||
run: echo -e "gradle.publish.key=$APIKEY\ngradle.publish.secret=$APISECRET\nsigning.keyId=$SIGNINGKEYID\nsigning.password=$SIGNINGPASSWORD\nsigning.secretKeyRingFile=$HOME/.gradle/secrets.gpg\nsonatypeUsername=$SONATYPEUSER\nsonatypePassword=$SONATYPEPASSWORD" > $HOME/.gradle/gradle.properties | ||
- name: Build and test with Gradle | ||
env: | ||
ISHUSERNAME: ${{ secrets.ISHUSERNAME }} | ||
ISHKEY: ${{ secrets.ISHKEY }} | ||
JAVA_OPTS: "-Xmx1024M -XX:MaxPermSize=512M -XX:ReservedCodeCacheSize=512M" | ||
GRADLE_OPTS: "-Dorg.gradle.daemon=true" | ||
run: ./gradlew test build :publishIntershopMvnPublicationToMavenRepository -s --scan | ||
- name: Post Build | ||
run: rm -f $HOME/.gradle/gradle.properties && rm -f $HOME/.docker/config.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# This workflow will build a Java project with Gradle | ||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle | ||
|
||
name: Run release build from tag | ||
|
||
on: | ||
push: | ||
tags: | ||
- '*' | ||
|
||
jobs: | ||
release: | ||
environment: CIRelease | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Set up JDK 1.8 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 1.8 | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- run: git fetch --all --tag | ||
- name: Create .gradle dir | ||
run: mkdir -p $HOME/.gradle | ||
- id: install-secret-key | ||
name: Install gpg secret key | ||
env: | ||
SIGNINGFILE: ${{ secrets.SIGNINGFILE }} | ||
run: | | ||
cat <(echo -e "${{ secrets.SIGNINGFILE }}") | gpg --batch --import | ||
gpg --list-secret-keys --keyid-format LONG | ||
- id: export-gpg-file | ||
name: Export gpg file | ||
env: | ||
SIGNINGKEYID: ${{ secrets.SIGNINGKEYID }} | ||
SIGNINGPASSWORD: ${{ secrets.SIGNINGPASSWORD }} | ||
run: | | ||
gpg --batch --passphrase="$SIGNINGPASSWORD" --pinentry-mode loopback --export-secret-keys $SIGNINGKEYID > $HOME/.gradle/secrets.gpg | ||
- name: Create gradle sproperties | ||
env: | ||
APIKEY: ${{ secrets.APIKEY }} | ||
APISECRET: ${{ secrets.APISECRET }} | ||
SIGNINGKEYID: ${{ secrets.SIGNINGKEYID }} | ||
SIGNINGPASSWORD: ${{ secrets.SIGNINGPASSWORD }} | ||
SONATYPEPASSWORD: ${{ secrets.SONATYPEPASSWORD }} | ||
SONATYPEUSER: ${{ secrets.SONATYPEUSER }} | ||
run: echo -e "gradle.publish.key=$APIKEY\ngradle.publish.secret=$APISECRET\nsigning.keyId=$SIGNINGKEYID\nsigning.password=$SIGNINGPASSWORD\nsigning.secretKeyRingFile=$HOME/.gradle/secrets.gpg\nsonatypeUsername=$SONATYPEUSER\nsonatypePassword=$SONATYPEPASSWORD" > $HOME/.gradle/gradle.properties | ||
- name: Run gradle release | ||
env: | ||
ISHUSERNAME: ${{ secrets.ISHUSERNAME }} | ||
ISHKEY: ${{ secrets.ISHKEY }} | ||
JAVA_OPTS: "-Xmx1024M -XX:MaxPermSize=512M -XX:ReservedCodeCacheSize=512M" | ||
GRADLE_OPTS: "-Dorg.gradle.daemon=true" | ||
run: ./gradlew -PrunOnCI=true test build :publishIntershopMvnPublicationToMavenRepository :publishPlugins -s --scan | ||
- name: Post Build | ||
run: rm -f $HOME/.gradle/gradle.properties |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
import com.jfrog.bintray.gradle.BintrayExtension | ||
import org.asciidoctor.gradle.jvm.AsciidoctorTask | ||
import org.jetbrains.dokka.gradle.DokkaTask | ||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile | ||
import java.util.Date | ||
|
||
/* | ||
* Copyright 2015 Intershop Communications AG. | ||
|
@@ -23,7 +21,7 @@ plugins { | |
// project plugins | ||
`java-gradle-plugin` | ||
groovy | ||
id("nebula.kotlin") version "1.3.61" | ||
kotlin("jvm") version "1.4.20" | ||
|
||
// test coverage | ||
jacoco | ||
|
@@ -34,23 +32,23 @@ plugins { | |
// publish plugin | ||
`maven-publish` | ||
|
||
// artifact signing - necessary on Maven Central | ||
signing | ||
|
||
// intershop version plugin | ||
id("com.intershop.gradle.scmversion") version "6.1.0" | ||
id("com.intershop.gradle.scmversion") version "6.2.0" | ||
|
||
// plugin for documentation | ||
id("org.asciidoctor.jvm.convert") version "2.4.0" | ||
id("org.asciidoctor.jvm.convert") version "3.3.0" | ||
|
||
// documentation | ||
id("org.jetbrains.dokka") version "0.10.0" | ||
id("org.jetbrains.dokka") version "0.10.1" | ||
|
||
// code analysis for kotlin | ||
id("io.gitlab.arturbosch.detekt") version "1.4.0" | ||
id("io.gitlab.arturbosch.detekt") version "1.15.0" | ||
|
||
// plugin for publishing to Gradle Portal | ||
id("com.gradle.plugin-publish") version "0.10.1" | ||
|
||
// plugin for publishing to jcenter | ||
id("com.jfrog.bintray") version "1.8.4" | ||
id("com.gradle.plugin-publish") version "0.13.0" | ||
} | ||
|
||
scm { | ||
|
@@ -61,6 +59,14 @@ group = "com.intershop.gradle.javacc" | |
description = "Gradle javacc plugin" | ||
version = scm.version.version | ||
|
||
val sonatypeUsername: String by project | ||
val sonatypePassword: String? by project | ||
|
||
repositories { | ||
mavenCentral() | ||
jcenter() | ||
} | ||
|
||
val pluginId = "com.intershop.gradle.javacc" | ||
|
||
gradlePlugin { | ||
|
@@ -97,7 +103,7 @@ detekt { | |
|
||
tasks { | ||
withType<Test>().configureEach { | ||
systemProperty("intershop.gradle.versions", "6.0, 6.1, 6.2") | ||
systemProperty("intershop.gradle.versions", "6.8") | ||
|
||
dependsOn("jar") | ||
} | ||
|
@@ -160,11 +166,10 @@ tasks { | |
jacocoTestReport.dependsOn("test") | ||
} | ||
|
||
getByName("bintrayUpload")?.dependsOn("asciidoctor") | ||
getByName("jar")?.dependsOn("asciidoctor") | ||
|
||
val compileKotlin by getting(KotlinCompile::class) { | ||
kotlinOptions.jvmTarget = "1.8" | ||
kotlinOptions.jvmTarget = JavaVersion.VERSION_1_8.toString() | ||
} | ||
|
||
val dokka by existing(DokkaTask::class) { | ||
|
@@ -206,68 +211,62 @@ publishing { | |
classifier = "docbook" | ||
} | ||
|
||
pom.withXml { | ||
val root = asNode() | ||
root.appendNode("name", project.name) | ||
root.appendNode("description", project.description) | ||
root.appendNode("url", "https://github.com/IntershopCommunicationsAG/${project.name}") | ||
|
||
val scm = root.appendNode("scm") | ||
scm.appendNode("url", "https://github.com/IntershopCommunicationsAG/${project.name}") | ||
scm.appendNode("connection", "[email protected]:IntershopCommunicationsAG/${project.name}.git") | ||
|
||
val org = root.appendNode("organization") | ||
org.appendNode("name", "Intershop Communications") | ||
org.appendNode("url", "http://intershop.com") | ||
|
||
val license = root.appendNode("licenses").appendNode("license") | ||
license.appendNode("name", "Apache License, Version 2.0") | ||
license.appendNode("url", "http://www.apache.org/licenses/LICENSE-2.0") | ||
license.appendNode("distribution", "repo") | ||
pom { | ||
name.set(project.name) | ||
description.set(project.description) | ||
url.set("https://github.com/IntershopCommunicationsAG/${project.name}") | ||
licenses { | ||
license { | ||
name.set("The Apache License, Version 2.0") | ||
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt") | ||
distribution.set("repo") | ||
} | ||
} | ||
organization { | ||
name.set("Intershop Communications AG") | ||
url.set("http://intershop.com") | ||
} | ||
developers { | ||
developer { | ||
id.set("m-raab") | ||
name.set("M. Raab") | ||
email.set("[email protected]") | ||
} | ||
} | ||
scm { | ||
connection.set("[email protected]:IntershopCommunicationsAG/${project.name}.git") | ||
developerConnection.set("[email protected]:IntershopCommunicationsAG/${project.name}.git") | ||
url.set("https://github.com/IntershopCommunicationsAG/${project.name}") | ||
} | ||
} | ||
} | ||
} | ||
repositories { | ||
maven { | ||
val releasesRepoUrl = "https://oss.sonatype.org/service/local/staging/deploy/maven2" | ||
val snapshotsRepoUrl = "https://oss.sonatype.org/content/repositories/snapshots" | ||
url = uri(if (version.toString().endsWith("SNAPSHOT")) snapshotsRepoUrl else releasesRepoUrl) | ||
credentials { | ||
username = sonatypeUsername | ||
password = sonatypePassword | ||
} | ||
} | ||
} | ||
} | ||
|
||
bintray { | ||
user = System.getenv("BINTRAY_USER") | ||
key = System.getenv("BINTRAY_KEY") | ||
|
||
setPublications("intershopMvn") | ||
|
||
pkg(delegateClosureOf<BintrayExtension.PackageConfig> { | ||
repo = "maven" | ||
name = project.name | ||
userOrg = "intershopcommunicationsag" | ||
|
||
setLicenses("Apache-2.0") | ||
vcsUrl = "https://github.com/IntershopCommunicationsAG/${project.name}" | ||
|
||
desc = project.description | ||
websiteUrl = "https://github.com/IntershopCommunicationsAG/${project.name}" | ||
issueTrackerUrl = "https://github.com/IntershopCommunicationsAG/${project.name}/issues" | ||
|
||
setLabels("intershop", "gradle", "plugin", "build", "javacc") | ||
publicDownloadNumbers = true | ||
|
||
version(delegateClosureOf<BintrayExtension.VersionConfig> { | ||
name = project.version.toString() | ||
desc = "${project.description} ${project.version}" | ||
released = Date().toString() | ||
vcsTag = project.version.toString() | ||
}) | ||
}) | ||
signing { | ||
sign(publishing.publications["intershopMvn"]) | ||
} | ||
|
||
dependencies { | ||
implementation(gradleKotlinDsl()) | ||
implementation(gradleApi()) | ||
implementation(localGroovy()) | ||
|
||
implementation("net.java.dev.javacc:javacc:4.2") | ||
|
||
testImplementation("commons-io:commons-io:2.2") | ||
testImplementation("com.intershop.gradle.test:test-gradle-plugin:3.4.0") | ||
testImplementation("com.intershop.gradle.test:test-gradle-plugin:3.7.0") | ||
testImplementation(gradleTestKit()) | ||
} | ||
|
||
repositories { | ||
jcenter() | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.