Skip to content

Commit cb52d8c

Browse files
committed
Upgrade to Gradle 8.1 / update dependencies / pipeline for publishing
1 parent b94f0e2 commit cb52d8c

File tree

8 files changed

+59
-29
lines changed

8 files changed

+59
-29
lines changed

.github/workflows/ci-build.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Build Plugin
2+
on: [ push, pull_request ]
3+
jobs:
4+
gradle-build:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- name: git clone
8+
uses: actions/checkout@v3.5.2
9+
- name: Set up JDK
10+
uses: actions/setup-java@v3.11.0
11+
with:
12+
distribution: temurin
13+
java-version: 11
14+
- name: gradle build
15+
id: gradle
16+
uses: gradle/gradle-build-action@v2.4.2
17+
with:
18+
arguments: checkAllVersions

.github/workflows/ci-build.yml

Lines changed: 0 additions & 24 deletions
This file was deleted.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
name: Validate Gradle Wrapper
2+
on: [ push, pull_request ]
3+
jobs:
4+
validation:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- uses: actions/checkout@v3.5.2
8+
- uses: gradle/wrapper-validation-action@v1.0.6

.github/workflows/release.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Publish Release
2+
on:
3+
push:
4+
tags:
5+
- 'v*'
6+
jobs:
7+
release-build:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: git clone
11+
uses: actions/checkout@v3.5.2
12+
- name: Set up JDK
13+
uses: actions/setup-java@v3.11.0
14+
with:
15+
distribution: temurin
16+
java-version: 11
17+
- name: Set up Gradle
18+
uses: gradle/gradle-build-action@v2.4.2
19+
- run: "./gradlew :publishPlugin --no-configuration-cache"
20+
env:
21+
SIGNING_KEY: ${{ secrets.SIGNING_KEY }}
22+
SIGNING_PASSPHRASE: ${{ secrets.SIGNING_PASSPHRASE }}
23+
GRADLE_PUBLISH_KEY: ${{ secrets.GRADLE_PUBLISH_KEY }}
24+
GRADLE_PUBLISH_SECRET: ${{ secrets.GRADLE_PUBLISH_SECRET }}

build.gradle.kts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,11 @@ dependencies {
4242
testRuntimeOnly("org.junit.vintage:junit-vintage-engine")
4343
}
4444

45+
// TODO This needs to be included in org.gradlex.internal.plugin-publish-conventions
46+
signing {
47+
useInMemoryPgpKeys(providers.environmentVariable("SIGNING_KEY").orNull, providers.environmentVariable("SIGNING_PASSPHRASE").orNull)
48+
}
49+
4550
tasks.test {
4651
useJUnitPlatform()
4752
maxParallelForks = 4
@@ -52,7 +57,7 @@ val checkAllVersions = tasks.register("checkAllVersions") {
5257
dependsOn(tasks.check)
5358
}
5459

55-
listOf("6.0.1", "6.4.1", "6.9.3", "7.0.2", "7.1.1", "7.2", "7.3.3", "7.4.2", "7.5.1", "7.6").forEach { gradleVersionUnderTest ->
60+
listOf("6.0.1", "6.4.1", "6.9.3", "7.0.2", "7.1.1", "7.2", "7.3.3", "7.4.2", "7.5.1", "7.6.1").forEach { gradleVersionUnderTest ->
5661
val testGradle = tasks.register<Test>("testGradle$gradleVersionUnderTest") {
5762
group = LifecycleBasePlugin.VERIFICATION_GROUP
5863
description = "Runs tests against Gradle $gradleVersionUnderTest"

gradle.properties

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
1-
org.gradle.parallel=true
21
org.gradle.caching=true
3-
org.gradle.unsafe.configuration-cache=true
2+
org.gradle.configuration-cache=true
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-rc-3-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
44
networkTimeout=10000
55
zipStoreBase=GRADLE_USER_HOME
66
zipStorePath=wrapper/dists

settings.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ pluginManagement {
77
}
88
}
99
plugins {
10-
id("com.gradle.enterprise") version "3.12.2"
10+
id("com.gradle.enterprise") version "3.13.3"
1111
id("gradlexbuild.build-parameters")
1212
}
1313

0 commit comments

Comments
 (0)