Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Various updates before 5.0.0-M1 #165

Merged
merged 5 commits into from
Jan 8, 2025
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
27 changes: 10 additions & 17 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
java: ['17']
java: ['17', '21']
env:
WORKSPACE: ${{ github.workspace }}
GRADLE_OPTS: -Xmx1500m -Dfile.encoding=UTF-8
Expand All @@ -36,35 +36,28 @@ jobs:
- name: "🏃 Run Tests"
if: github.event_name == 'pull_request'
id: tests
run: ./gradlew check
run: ./gradlew check --continue
- name: "🔨 Build project"
if: github.event_name == 'push'
id: build
run: ./gradlew build
- name: "📄 Publish Test Report"
if: steps.build.outcome == 'failure' || steps.tests.outcome == 'failure'
uses: scacap/action-surefire-report@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
report_paths: '**/build/test-results/test/TEST-*.xml'
run: ./gradlew build --continue
- name: "📤 Publish Snapshot"
if: steps.build.outcome == 'success' && github.event_name == 'push' && matrix.java == '17'
if: github.event_name == 'push' && steps.build.outcome == 'success' && matrix.java == '17'
env:
ARTIFACTORY_USERNAME: ${{ secrets.ARTIFACTORY_USERNAME }}
ARTIFACTORY_PASSWORD: ${{ secrets.ARTIFACTORY_PASSWORD }}
run: publish
run: ./gradlew publish
- name: "✍️ Generate Documentation"
id: docs
if: success() && github.event_name == 'push' && matrix.java == '17'
run: ./gradlew docs
- name: "📤 Publish to Github Pages"
if: steps.publish.outcome == 'success' && github.event_name == 'push' && matrix.java == '17'
if: github.event_name == 'push' && steps.publish.outcome == 'success' && matrix.java == '17'
uses: grails/github-pages-deploy-action@grails
env:
TARGET_REPOSITORY: ${{ github.repository }}
GH_TOKEN: ${{ secrets.GH_TOKEN }}
BRANCH: gh-pages
FOLDER: build/docs
DOC_FOLDER: gh-pages
COMMIT_EMAIL: grails-build@users.noreply.github.com
COMMIT_NAME: grails-build
COMMIT_NAME: grails-build
DOC_FOLDER: gh-pages
FOLDER: build/docs
GH_TOKEN: ${{ secrets.GH_TOKEN }}
17 changes: 8 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ jobs:
release:
runs-on: ubuntu-latest
env:
GIT_USER_NAME: 'grails-build'
GIT_USER_EMAIL: 'grails-build@users.noreply.github.com'
GIT_USER_NAME: grails-build
GIT_USER_EMAIL: grails-build@users.noreply.github.com
steps:
- name: "📥 Checkout repository"
uses: actions/checkout@v4
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: 'liberica'
java-version: '17'
java-version: 17
distribution: liberica
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
with:
Expand All @@ -38,7 +38,6 @@ jobs:
SONATYPE_STAGING_PROFILE_ID: ${{ secrets.SONATYPE_STAGING_PROFILE_ID }}
SIGNING_KEY: ${{ secrets.SIGNING_KEY }}
SIGNING_PASSPHRASE: ${{ secrets.SIGNING_PASSPHRASE }}
SECRING_FILE: ${{ secrets.SECRING_FILE }}
run: >
./gradlew
-Psigning.secretKeyRingFile=${{ github.workspace }}/secring.gpg
Expand All @@ -55,13 +54,13 @@ jobs:
uses: grails/github-pages-deploy-action@grails
env:
BETA: ${{ contains(steps.release_version.outputs.release_version, 'M') || contains(steps.release_version.outputs.release_version, 'RC') }}
TARGET_REPOSITORY: ${{ github.repository }}
GH_TOKEN: ${{ secrets.GH_TOKEN }}
BRANCH: gh-pages
FOLDER: docs/build/docs
DOC_FOLDER: gh-pages
COMMIT_EMAIL: ${{ env.GIT_USER_EMAIL }}
COMMIT_NAME: ${{ env.GIT_USER_NAME }}
DOC_FOLDER: gh-pages
FOLDER: docs/build/docs
GH_TOKEN: ${{ secrets.GH_TOKEN }}
TARGET_REPOSITORY: ${{ github.repository }}
VERSION: ${{ steps.release_version.outputs.release_version }}
- name: "⚙️ Run post-release"
if: steps.publish.outcome == 'success' && steps.docs.outcome == 'success' && success()
Expand Down
33 changes: 1 addition & 32 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,32 +1 @@
buildscript {
repositories {
maven { url "https://plugins.gradle.org/m2/" }
}
dependencies {
classpath "io.github.gradle-nexus:publish-plugin:1.3.0"
}
}

version = project.projectVersion

ext.isSnapshot = project.projectVersion.endsWith('-SNAPSHOT')
ext.isReleaseVersion = !isSnapshot

if (isReleaseVersion) {
apply plugin: 'maven-publish'
apply plugin: "io.github.gradle-nexus.publish-plugin"

nexusPublishing {
repositories {
sonatype {
def ossUser = System.getenv("SONATYPE_USERNAME") ?: project.hasProperty("sonatypeOssUsername") ? project.sonatypeOssUsername : ''
def ossPass = System.getenv("SONATYPE_PASSWORD") ?: project.hasProperty("sonatypeOssPassword") ? project.sonatypeOssPassword : ''
def ossStagingProfileId = System.getenv("SONATYPE_STAGING_PROFILE_ID") ?: project.hasProperty("sonatypeOssStagingProfileId") ? project.sonatypeOssStagingProfileId : ''
nexusUrl = uri("https://s01.oss.sonatype.org/service/local/")
username = ossUser
password = ossPass
stagingProfileId = ossStagingProfileId
}
}
}
}
version = project.projectVersion
Loading
Loading