This is an automated email from the ASF dual-hosted git repository.

jamesfredley pushed a commit to branch apache-coordinates
in repository https://gitbox.apache.org/repos/asf/grails-forge.git

commit 7c53c375e0d2003bd77be6a697ed892cd637b29d
Author: James Fredley <[email protected]>
AuthorDate: Wed Apr 30 16:00:05 2025 -0400

    Remove maven/nexus publishing which stopped being published after 6.2.0
---
 .github/workflows/gradle.yml                       |   8 -
 .github/workflows/mavenCentral.yml                 |  40 ----
 .github/workflows/release.yml                      |  20 +-
 README.md                                          |   4 +-
 build.gradle                                       |  24 ---
 buildSrc/build.gradle                              |   1 -
 ...g.grails.forge.internal.published-module.gradle | 212 ---------------------
 gradle.properties                                  |   1 -
 8 files changed, 2 insertions(+), 308 deletions(-)

diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml
index 14f314b..217a2de 100644
--- a/.github/workflows/gradle.yml
+++ b/.github/workflows/gradle.yml
@@ -36,14 +36,6 @@ jobs:
           unzip cli -d tmp
           mv tmp/grails-forge-cli-* tmp/cli
           ./tmp/cli/bin/grails --version
-      - name: "📤 Publish to Apache Snapshot Repo"
-        id: publish
-        if: steps.build.outcome == 'success' && github.event_name == 'push' && 
matrix.java == '17' && github.repository_owner == 'apache'
-        env:
-          MAVEN_PUBLISH_USERNAME: ${{ secrets.NEXUS_USER }}
-          MAVEN_PUBLISH_PASSWORD: ${{ secrets.NEXUS_PW  }}
-          MAVEN_PUBLISH_URL: ${{ secrets.GRAILS_NEXUS_PUBLISH_SNAPSHOT_URL }}
-        run: ./gradlew publishToSonatype
   linux:
     name: "Build Linux Native CLI"
     runs-on: ubuntu-latest
diff --git a/.github/workflows/mavenCentral.yml 
b/.github/workflows/mavenCentral.yml
deleted file mode 100644
index 9faa7dd..0000000
--- a/.github/workflows/mavenCentral.yml
+++ /dev/null
@@ -1,40 +0,0 @@
-name: "Maven Central Sync"
-on:
-  workflow_dispatch:
-    inputs:
-      release_version:
-        description: 'Release version (eg: 1.2.3)'
-        required: true
-jobs:
-  build:
-    name: "Maven Central Sync"
-    runs-on: ubuntu-latest
-    steps:
-      - name: "📥 Checkout repository"
-        uses: actions/checkout@v4
-        with:
-          ref: v${{ github.event.inputs.release_version }}
-      - name: "☕️ Setup JDK"
-        uses: actions/setup-java@v4
-        with:
-          distribution: 'liberica'
-          java-version: '17'
-      - name: "🐘 Setup Gradle"
-        uses: gradle/actions/setup-gradle@v4
-        with:
-          develocity-access-key: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
-      - name: "🔐 Generate secring file"
-        env:
-          SECRING_FILE: ${{ secrets.SECRING_FILE }}
-        run: echo $SECRING_FILE | base64 -d > ${{ github.workspace 
}}/secring.gpg
-      - name: "📤 Publish to Sonatype OSSRH"
-        env:
-          SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
-          SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
-          SIGNING_KEY: ${{ secrets.SIGNING_KEY }}
-          SIGNING_PASSPHRASE: ${{ secrets.SIGNING_PASSPHRASE }}
-        run: >
-          ./gradlew
-          -Psigning.secretKeyRingFile=${{ github.workspace }}/secring.gpg
-          publishToSonatype
-          closeAndReleaseSonatypeStagingRepository
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 38e812b..c51e89a 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -4,7 +4,7 @@ on:
     types: [published]
 jobs:
   build:
-    name: "Release artifacts to Bintray, Maven Central & SDKMAN, and publish 
documentation"
+    name: "Release artifacts to GitHub release and SDKMAN plus publish source 
& documentation"
     runs-on: ubuntu-latest
     permissions:
       contents: write  #  to create release
@@ -34,24 +34,6 @@ jobs:
           RELEASE_SCRIPT_PATH: '.github/scripts/setReleasedGrailsVersion.sh'
       - name: "🔨 Build All"
         run: ./gradlew grails-forge-cli:assemble
-      - name: "🔐 Generate secring file"
-        env:
-          SECRING_FILE: ${{ secrets.SECRING_FILE }}
-        run: echo $SECRING_FILE | base64 -d > ${{ github.workspace 
}}/secring.gpg
-      - name: "📤 Publish to Sonatype OSSRH"
-        env:
-          SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
-          SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
-          SONATYPE_NEXUS_URL: ${{ secrets.SONATYPE_NEXUS_URL }}
-          SONATYPE_STAGING_PROFILE_ID: ${{ secrets.SONATYPE_STAGING_PROFILE_ID 
}}
-          SIGNING_KEY: ${{ secrets.SIGNING_KEY }}
-          SIGNING_PASSPHRASE: ${{ secrets.SIGNING_PASSPHRASE }}
-        run: >
-          ./gradlew
-          -Psigning.secretKeyRingFile=${{ github.workspace }}/secring.gpg
-          publishToSonatype
-          closeSonatypeStagingRepository
-          docs
       - name: "📤 Upload CLI Zip"
         id: upload-release-asset
         uses: actions/upload-release-asset@v1
diff --git a/README.md b/README.md
index 5902cb5..c98347c 100644
--- a/README.md
+++ b/README.md
@@ -47,9 +47,7 @@ See the [Snapshot 
Documentation](https://grails.github.io/grails-forge/snapshot/
 
 ## Snapshots and Releases
 
-Snapshots are automatically published to [Apache Snapshot 
Repo](https://repository.apache.org/content/groups/snapshots/org/apache/grails/forge/)
 using [Github Actions](https://github.com/apache/grails-forge/actions).
-
-Releases are published to Maven Central via [Github 
Actions](https://github.com/apache/grails-forge/actions).
+Releases are published to SDKMan via [Github 
Actions](https://github.com/apache/grails-forge/actions).
 
 A release is performed with the following steps:
 
diff --git a/build.gradle b/build.gradle
index f8c1a5d..f05b02c 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,34 +1,10 @@
 plugins {
-    id "io.github.gradle-nexus.publish-plugin"
     id "org.grails.forge.internal.aggregator"
 }
 
 version project.projectVersion
 group "org.apache.grails.forge"
 
-def ossUser = System.getenv("MAVEN_PUBLISH_USERNAME")
-def ossPass = System.getenv("MAVEN_PUBLISH_PASSWORD")
-def ossStagingProfileId = System.getenv("SONATYPE_STAGING_PROFILE_ID") ?: 
project.hasProperty("sonatypeOssStagingProfileId") ? 
project.sonatypeOssStagingProfileId : ''
-
-if (!ossUser?.isEmpty() && !ossPass?.isEmpty()) {
-    String version = String.valueOf(rootProject.getVersion());
-    if ("unspecified".equals(version)) {
-        throw new RuntimeException("The root project doesn't define a version. 
Please set the version in the root project.");
-    }
-    nexusPublishing {
-        repositories {
-            sonatype {
-                allowInsecureProtocol = 
rootProject.hasProperty("allowInsecurePublishing")
-                username = ossUser
-                password = ossPass
-                stagingProfileId = ossStagingProfileId
-                nexusUrl = uri("https://s01.oss.sonatype.org/service/local/";)
-                snapshotRepositoryUrl = uri(System.getenv('MAVEN_PUBLISH_URL') 
?: 'https://repository.apache.org/content/repositories/snapshots')
-            }
-        }
-    }
-}
-
 // buildSrc tests fail occasionally without running clean first
 build {
     dependsOn clean
diff --git a/buildSrc/build.gradle b/buildSrc/build.gradle
index 3d71880..8c07ec8 100644
--- a/buildSrc/build.gradle
+++ b/buildSrc/build.gradle
@@ -31,7 +31,6 @@ dependencies {
     implementation 
"com.diffplug.spotless:spotless-plugin-gradle:$spotlessVersion"
     implementation "io.spring.nohttp:nohttp-gradle:$nohttpGradleVersion"
     implementation 
"gradle.plugin.com.github.johnrengelman:shadow:$shadowVersion"
-    implementation "io.github.gradle-nexus:publish-plugin:$nexusPublishVersion"
     implementation 
"org.gradle.test-retry:org.gradle.test-retry.gradle.plugin:$testRetryVersion"
 }
 
diff --git 
a/buildSrc/src/main/groovy/org.grails.forge.internal.published-module.gradle 
b/buildSrc/src/main/groovy/org.grails.forge.internal.published-module.gradle
index 1180b04..7b325ba 100644
--- a/buildSrc/src/main/groovy/org.grails.forge.internal.published-module.gradle
+++ b/buildSrc/src/main/groovy/org.grails.forge.internal.published-module.gradle
@@ -1,226 +1,14 @@
 plugins {
     id "org.grails.forge.internal.base-module"
-    id 'maven-publish'
-    id 'signing'
 }
 
-
 ExtraPropertiesExtension ext = extensions.getByType(ExtraPropertiesExtension)
 
-ext."signing.keyId" = project.hasProperty("signing.keyId") ? 
project.getProperty('signing.keyId') : System.getenv('SIGNING_KEY')
-ext."signing.secretKeyRingFile" = 
project.hasProperty("signing.secretKeyRingFile") ? 
project.getProperty('signing.secretKeyRingFile') : 
"${System.properties['user.home']}${File.separator}.gnupg${File.separator}secring.gpg"
-ext."signing.password" = project.hasProperty("signing.password") ? 
project.getProperty('signing.password') : System.getenv('SIGNING_PASSPHRASE')
-
-def ossUser = System.getenv("MAVEN_PUBLISH_USERNAME")
-def ossPass = System.getenv("MAVEN_PUBLISH_PASSWORD")
-def ossStagingProfileId = System.getenv("SONATYPE_STAGING_PROFILE_ID") ?: 
project.hasProperty("sonatypeOssStagingProfileId") ? 
project.sonatypeOssStagingProfileId : ''
-
-ext.pomInfo = {
-    if 
(project.extensions.getByType(ExtraPropertiesExtension).has('startPomInfo')) {
-        ext.startPomInfo.delegate = delegate
-        ext.startPomInfo.call()
-    }
-    delegate.name project.title
-    delegate.description project.projectDesc
-    delegate.url project.findProperty('projectUrl')
-
-    delegate.licenses {
-        delegate.license {
-            delegate.name 'The Apache Software License, Version 2.0'
-            delegate.url 'http://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"
-    }
-
-    if(project.hasProperty('developers')) {
-        delegate.developers {
-            for(dev in project.findProperty('developers').split(',')) {
-                delegate.developer {
-                    delegate.id "puneetbehl"
-                    delegate.name "Puneet Behl"
-                }
-            }
-        }
-    }
-    if 
(project.extensions.getByType(ExtraPropertiesExtension).has('extraPomInfo')) {
-        ext.extraPomInfo.delegate = delegate
-        ext.extraPomInfo.call()
-    }
-}
-
 java {
     withSourcesJar()
     withJavadocJar()
 }
 
-project.afterEvaluate {
-    boolean isPlatform = project.plugins.findPlugin("java-platform") != null
-
-    publishing {
-        repositories {
-            def externalRepo = 
providers.systemProperty("org.grails.publishing.uri")
-                    .forUseAtConfigurationTime()
-                    .orNull
-            if (externalRepo) {
-
-                def externalRepoUsername = 
providers.systemProperty("org.grails.publishing.username")
-                        .forUseAtConfigurationTime()
-                        .orNull
-                def externalRepoPassword = 
providers.systemProperty("org.grails.publishing.password")
-
-                        .orNull
-
-                maven {
-                    name = "Grails Artifactory"
-                    url = externalRepo
-                    if(externalRepoUsername){
-                        credentials {
-                            username = externalRepoUsername
-                            password = externalRepoPassword
-                        }
-                    }
-                }
-            }
-
-            maven {
-                name = "Build"
-                url = 
"${rootProject.layout.buildDirectory.dir("repo").get().asFile.toURI()}"
-            }
-
-        }
-        publications {
-            if 
(project.extensions.findByType(PublishingExtension).publications.empty) {
-                maven(MavenPublication) { publication ->
-                    artifactId = project.getName()
-                    version = project.getVersion()
-                    if (!project.name.endsWith("bom")) {
-                        versionMapping {
-                            usage('java-api') {
-                                fromResolutionOf('runtimeClasspath')
-                            }
-                            usage('java-runtime') {
-                                fromResolutionResult()
-                            }
-                        }
-                    }
-
-                    if(project.hasProperty('shadowJarEnabled') && 
project.shadowJarEnabled == true) {
-                        // TODO: This code doesn't use Gradle publications, it 
hard codes publishing
-                        // which is easy to break and causes Gradle Module 
Metadata to be ignored
-                        // this should be replaced with a publication
-                        def shadowJar = tasks.named("shadowJar")
-                        artifact(shadowJar) {
-                            classifier = null
-                        }
-                        artifact(tasks.named('javadocJar'))
-                        artifact(tasks.named('sourcesJar'))
-                        pom.withXml { xml ->
-                            def xmlNode = xml.asNode()
-                            def dependenciesNode = 
xmlNode.appendNode('dependencies')
-                            Set<Dependency> visited = new HashSet<>()
-
-                            project.configurations.api.allDependencies.each {
-                                if (!(it instanceof SelfResolvingDependency)) {
-                                    def dependencyNode = 
dependenciesNode.appendNode('dependency')
-                                    dependencyNode.appendNode('groupId', 
it.group)
-                                    dependencyNode.appendNode('artifactId', 
it.name)
-                                    dependencyNode.appendNode('version', 
it.version)
-                                    dependencyNode.appendNode('scope', 
'compile')
-                                } else if (it instanceof ProjectDependency) {
-                                    def dependencyNode = 
dependenciesNode.appendNode('dependency')
-                                    dependencyNode.appendNode('groupId', 
project.group)
-                                    dependencyNode.appendNode('artifactId', 
"micronaut-$it.name")
-                                    dependencyNode.appendNode('version', 
project.version)
-                                    dependencyNode.appendNode('scope', 
'compile')
-                                }
-                                visited.add(it)
-                            }
-                            def runtimeHandler = {
-                                if (visited.contains(it)) {
-                                    return
-                                }
-                                if (!(it instanceof SelfResolvingDependency)) {
-                                    def dependencyNode = 
dependenciesNode.appendNode('dependency')
-                                    dependencyNode.appendNode('groupId', 
it.group)
-                                    dependencyNode.appendNode('artifactId', 
it.name)
-                                    dependencyNode.appendNode('version', 
it.version)
-                                    dependencyNode.appendNode('scope', 
'runtime')
-                                } else if (it instanceof ProjectDependency) {
-                                    def dependencyNode = 
dependenciesNode.appendNode('dependency')
-                                    dependencyNode.appendNode('groupId', 
project.group)
-                                    dependencyNode.appendNode('artifactId', 
"micronaut-$it.name")
-                                    dependencyNode.appendNode('version', 
project.version)
-                                    dependencyNode.appendNode('scope', 
'runtime')
-
-                                }
-                                visited.add(it)
-                            }
-                            
project.configurations.implementation.allDependencies.each (runtimeHandler)
-                            
project.configurations.runtimeOnly.allDependencies.each (runtimeHandler)
-                        }
-
-                        pom.withXml {
-                            def xml = asNode()
-
-                            xml.children().last() + pomInfo
-                        }
-                    } else {
-                        if (isPlatform) {
-                            from components.javaPlatform
-                            pom.withXml {
-                                def xml = asNode()
-
-                                xml.children().find {
-                                    it.name().localPart == 'packaging'
-                                } + ext.pomInfo
-                            }
-                        } else {
-                            if (components.findByName('java')) {
-                                from components.java
-                            }
-
-                            pom.withXml {
-                                def xml = asNode()
-                                xml.children().last() + ext.pomInfo
-                            }
-                        }
-                    }
-
-                }
-            }
-        }
-    }
-}
-
-if (ossUser && ossPass) {
-    if (ext."signing.keyId" && ext."signing.password") {
-        afterEvaluate {
-            if 
(project.extensions.findByType(PublishingExtension).publications.findByName('maven'))
 {
-                signing {
-                    required { !project.version.endsWith("-SNAPSHOT") && 
!project.hasProperty("skipSigning") }
-                    sign publishing.publications.maven
-                }
-                tasks.withType(Sign) {
-                    onlyIf { !project.version.endsWith("-SNAPSHOT") }
-                }
-            }
-        }
-    }
-
-    //do not generate extra load on Nexus with new staging repository if 
signing fails
-    
tasks.withType(io.github.gradlenexus.publishplugin.InitializeNexusStagingRepository).configureEach
 {
-        if (!tasks.withType(Sign).empty) {
-            shouldRunAfter(tasks.withType(Sign))
-        }
-    }
-}
-
 ['sourcesJar', 'javadocJar'].each { name ->
     tasks.named(name, Jar) {
         duplicatesStrategy = DuplicatesStrategy.EXCLUDE
diff --git a/gradle.properties b/gradle.properties
index a5ec8ec..b578f81 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -31,7 +31,6 @@ micronautBuildVersion=1.1.5
 micronautDocsVersion=2.0.0
 micronautGradlePlugins=5.4.10
 micronautVersion=3.10.4
-nexusPublishVersion=1.3.0
 nohttpGradleVersion=0.0.11
 objenesisVersion=3.4
 postgresqlVersion=42.7.5

Reply via email to