-
Notifications
You must be signed in to change notification settings - Fork 117
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e5d060e
commit cb40070
Showing
7 changed files
with
130 additions
and
87 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 |
---|---|---|
|
@@ -7,6 +7,9 @@ on: | |
branches: | ||
- '[5-9].[0-9].x' | ||
workflow_dispatch: | ||
env: | ||
GIT_USER_NAME: 'grails-build' | ||
GIT_USER_EMAIL: '[email protected]' | ||
jobs: | ||
core-tests: | ||
if: github.event_name == 'pull_request' | ||
|
@@ -46,4 +49,44 @@ jobs: | |
with: | ||
arguments: | | ||
check | ||
-Dgeb.env=chromeHeadless | ||
-Dgeb.env=chromeHeadless | ||
publish_documentation: | ||
name: Publish Snapshot release | ||
runs-on: ubuntu-latest | ||
if: github.event_name == 'push' | ||
needs: build | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: gradle/wrapper-validation-action@v2 | ||
- uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 11 | ||
- name: Publish to Artifactory (repo.grails.org) | ||
uses: gradle/actions/setup-gradle@v3 | ||
env: | ||
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} | ||
ORG_GRADLE_PROJECT_artifactoryPublishUsername: ${{ secrets.ARTIFACTORY_USERNAME }} | ||
ORG_GRADLE_PROJECT_artifactoryPublishPassword: ${{ secrets.ARTIFACTORY_PASSWORD }} | ||
with: | ||
arguments: | | ||
-Dorg.gradle.internal.publish.checksums.insecure=true | ||
publish | ||
- name: Generate Documentation | ||
if: success() | ||
uses: gradle/actions/setup-gradle@v3 | ||
env: | ||
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} | ||
with: | ||
arguments: docs | ||
- name: Publish to Github Pages | ||
if: success() | ||
uses: micronaut-projects/github-pages-deploy-action@grails | ||
env: | ||
BRANCH: gh-pages | ||
COMMIT_EMAIL: ${{ env.GIT_USER_EMAIL }} | ||
COMMIT_NAME: ${{ env.GIT_USER_NAME }} | ||
FOLDER: docs/build/docs | ||
GH_TOKEN: ${{ secrets.GH_TOKEN }} | ||
TARGET_REPOSITORY: ${{ github.repository }} | ||
DOC_FOLDER: gh-pages |
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
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
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
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,42 @@ | ||
apply plugin: 'maven-publish' | ||
apply plugin: 'signing' | ||
|
||
ext { | ||
isReleaseVersion = !version.toString().endsWith("SNAPSHOT") | ||
ext.set('signing.keyId', project.findProperty('signing.keyId') ?: System.getenv('SIGNING_KEY')) | ||
ext.set('signing.password', project.findProperty('signing.password') ?: System.getenv('SIGNING_PASSPHRASE')) | ||
|
||
def pomInfo = { | ||
delegate.name project.title | ||
delegate.description project.projectDesc | ||
delegate.url projectUrl | ||
|
||
delegate.licenses { | ||
delegate.license { | ||
delegate.name 'Apache-2.0' | ||
delegate.url 'https://www.apache.org/licenses/LICENSE-2.0.txt' | ||
delegate.distribution 'repo' | ||
} | ||
} | ||
|
||
delegate.scm { | ||
delegate.url "scm:[email protected]:${githubSlug}.git" | ||
delegate.connection "scm:[email protected]:${githubSlug}.git" | ||
delegate.developerConnection "scm:[email protected]:${githubSlug}.git" | ||
} | ||
|
||
delegate.developers { | ||
delegate.developer { | ||
delegate.id = 'alvarosanchez' | ||
delegate.name = 'Alvaro Sanchez-Mariscal' | ||
} | ||
delegate.developer { | ||
delegate.id = 'jameskleeh' | ||
delegate.name = 'James Kleeh' | ||
} | ||
delegate.developer { | ||
delegate.id = 'jdaugherty' | ||
delegate.name = "James Daugherty" | ||
} | ||
} | ||
} | ||
|
||
publishing { | ||
|
@@ -12,58 +46,41 @@ publishing { | |
groupId = project.group | ||
version = project.version | ||
|
||
from components.java | ||
if(!isProfile) { | ||
from components.java | ||
|
||
artifact sourcesJar | ||
artifact javadocJar | ||
artifact sourcesJar | ||
artifact javadocJar | ||
} | ||
|
||
pom { | ||
name = 'Spring Security REST plugin' | ||
description = 'Grails plugin to implement token-based, RESTful authentication using Spring Security' | ||
url = project.projectUrl | ||
licenses { | ||
license { | ||
name = 'The Apache License, Version 2.0' | ||
url = 'https://www.apache.org/licenses/LICENSE-2.0.txt' | ||
} | ||
} | ||
developers { | ||
developer { | ||
id = 'alvarosanchez' | ||
name = 'Alvaro Sanchez-Mariscal' | ||
email = '' | ||
} | ||
developer { | ||
id = 'jameskleeh' | ||
name = 'James Kleeh' | ||
email = '' | ||
} | ||
developer { | ||
id = 'jdaugherty' | ||
name = "James Daugherty" | ||
email = '' | ||
} | ||
} | ||
scm { | ||
connection = project.scmConnection | ||
developerConnection = project.scmDeveloperConnection | ||
url = project.scmUrl | ||
pom.withXml { | ||
def pomNode = asNode() | ||
pomNode.children().last() + pomInfo | ||
} | ||
} | ||
} | ||
|
||
if (isSnapshot) { | ||
repositories { | ||
maven { | ||
credentials { | ||
username = project.findProperty('artifactoryPublishUsername') ?: '' | ||
password = project.findProperty('artifactoryPublishPassword') ?: '' | ||
} | ||
url = isProfile ? | ||
uri('https://repo.grails.org/grails/libs-snapshots-local') : | ||
uri('https://repo.grails.org/grails/plugins3-snapshots-local') | ||
|
||
|
||
} | ||
} | ||
} | ||
} | ||
|
||
afterEvaluate { | ||
signing { | ||
ext["signing.keyId"] = System.getenv('SIGNING_KEY_ID') | ||
ext["signing.password"] = System.getenv('SIGNING_PASSPHRASE') | ||
ext["signing.secretKeyRingFile"] = System.getenv('SECRING_FILE') | ||
|
||
required { | ||
isReleaseVersion && gradle.taskGraph.hasTask("publish") | ||
} | ||
sign publishing.publications.maven | ||
required = { isReleaseVersion && gradle.taskGraph.hasTask('publish') } | ||
sign(publishing.publications.maven) | ||
} | ||
} | ||
|
||
|
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
This file was deleted.
Oops, something went wrong.