Skip to content

Commit

Permalink
Exclude from maven release spring-context-indexer and spring-instrument
Browse files Browse the repository at this point in the history
  • Loading branch information
cesarhernandezgt committed Sep 17, 2024
1 parent 2d2d37c commit 6c8231e
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 11 deletions.
29 changes: 19 additions & 10 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -303,20 +303,29 @@ configure(allprojects) { project ->
}


// Configuration for the subprojects to ensure all are published
configure(subprojects) { subproject ->
apply plugin: 'maven-publish'
def excludedModules = ['spring-context-indexer', 'spring-instrument', 'spring-framework-bom']

publishing {
repositories {
maven {
url = uri("https://repository.tomitribe.com/service/local/staging/deploy/maven2")
credentials {
username = project.repoUser
password = project.repoPassword
// Configuration for the subprojects to ensure all are published except excluded ones
configure(subprojects) { subproject ->
// Check if the subproject is not in the excluded list
if (!excludedModules.contains(subproject.name)) {
// Apply the 'maven-publish' plugin only to the included modules
apply plugin: 'maven-publish'

publishing {
repositories {
maven {
url = uri("https://repository.tomitribe.com/service/local/staging/deploy/maven2")
credentials {
username = project.repoUser
password = project.repoPassword
}
}
}
}
} else {
// Print or log information about excluded projects
logger.lifecycle("Skipping publishing for project: ${subproject.name}")
}
}

Expand Down
2 changes: 1 addition & 1 deletion framework-bom/framework-bom.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description = "Spring Framework (Bill of Materials)"
apply plugin: 'java-platform'
apply from: "$rootDir/gradle/publications.gradle"

group = "org.springframework"
group = "org.tomitribe.springframework"

dependencies {
constraints {
Expand Down

0 comments on commit 6c8231e

Please sign in to comment.