Skip to content

Commit 5e9290c

Browse files
committed
Fix Dependabot config
* Fix `publish-maven.gradle` and its `apply`
1 parent 9e4907b commit 5e9290c

File tree

3 files changed

+87
-103
lines changed

3 files changed

+87
-103
lines changed

.github/dependabot.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,9 @@ updates:
1111
- package-ecosystem: gradle
1212
directory: /
1313
schedule:
14-
interval: weekly
15-
day: saturday
14+
interval: monthly
15+
registries:
16+
- spring-commercial
1617
ignore:
1718
- dependency-name: '*'
1819
update-types:
@@ -43,8 +44,7 @@ updates:
4344
- package-ecosystem: github-actions
4445
directory: /
4546
schedule:
46-
interval: weekly
47-
day: saturday
47+
interval: monthly
4848
labels:
4949
- 'type: task'
5050
groups:

build.gradle

Lines changed: 31 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,12 @@ buildscript {
1616

1717
plugins {
1818
id 'base'
19-
id 'project-report'
20-
id 'idea'
19+
id 'io.spring.nohttp' version '0.0.11' apply false
2120
id 'org.ajoberstar.grgit' version '4.1.1'
22-
id 'io.spring.nohttp' version '0.0.11'
23-
id 'io.spring.dependency-management' version '1.1.5' apply false
21+
id 'io.spring.dependency-management' version '1.1.5'
2422
id 'org.asciidoctor.jvm.pdf' version '3.3.2'
2523
id 'org.asciidoctor.jvm.convert' version '3.3.2'
26-
id 'com.github.spotbugs' version '6.0.14'
24+
id 'com.github.spotbugs' version '6.0.15'
2725
}
2826

2927
description = 'Spring AMQP'
@@ -73,9 +71,14 @@ ext {
7371
javaProjects = subprojects - project(':spring-amqp-bom')
7472
}
7573

76-
nohttp {
77-
source.include '**/src/**'
78-
source.exclude '**/*.gif', '**/*.ks'
74+
75+
if (isCI) {
76+
apply plugin: 'io.spring.nohttp'
77+
78+
nohttp {
79+
source.include '**/src/**'
80+
source.exclude '**/*.gif', '**/*.ks'
81+
}
7982
}
8083

8184
allprojects {
@@ -130,10 +133,8 @@ apply from: 'commercial-settings.gradle'
130133

131134
configure(javaProjects) { subproject ->
132135
apply plugin: 'java-library'
133-
apply plugin: 'java'
134136
apply plugin: 'eclipse'
135137
apply plugin: 'idea'
136-
apply plugin: 'project-report'
137138
apply plugin: 'checkstyle'
138139
apply plugin: 'kotlin'
139140
apply plugin: 'kotlin-spring'
@@ -203,27 +204,6 @@ configure(javaProjects) { subproject ->
203204
ext.xLintArg = '-Xlint:all,-options,-processing,-deprecation'
204205
[compileJava, compileTestJava]*.options*.compilerArgs = [xLintArg]
205206

206-
publishing {
207-
publications {
208-
mavenJava(MavenPublication) {
209-
suppressAllPomMetadataWarnings()
210-
from components.java
211-
pom.withXml {
212-
def pomDeps = asNode().dependencies.first()
213-
subproject.configurations.providedImplementation.allDependencies.each { dep ->
214-
pomDeps.remove(pomDeps.'*'.find { it.artifactId.text() == dep.name })
215-
pomDeps.appendNode('dependency').with {
216-
it.appendNode('groupId', dep.group)
217-
it.appendNode('artifactId', dep.name)
218-
it.appendNode('version', dep.version)
219-
it.appendNode('scope', 'provided')
220-
}
221-
}
222-
}
223-
}
224-
}
225-
}
226-
227207
task updateCopyrights {
228208
onlyIf { !isCI }
229209
inputs.files(modifiedFiles.filter { f -> f.path.contains(subproject.name) })
@@ -328,6 +308,26 @@ configure(javaProjects) { subproject ->
328308

329309
check.dependsOn javadoc
330310

311+
publishing {
312+
publications {
313+
mavenJava(MavenPublication) {
314+
suppressAllPomMetadataWarnings()
315+
from components.java
316+
pom.withXml {
317+
def pomDeps = asNode().dependencies.first()
318+
subproject.configurations.providedImplementation.allDependencies.each { dep ->
319+
pomDeps.remove(pomDeps.'*'.find { it.artifactId.text() == dep.name })
320+
pomDeps.appendNode('dependency').with {
321+
it.appendNode('groupId', dep.group)
322+
it.appendNode('artifactId', dep.name)
323+
it.appendNode('version', dep.version)
324+
it.appendNode('scope', 'provided')
325+
}
326+
}
327+
}
328+
}
329+
}
330+
}
331331
}
332332

333333
project('spring-amqp') {

publish-maven.gradle

Lines changed: 52 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -1,81 +1,65 @@
1-
apply plugin: 'maven-publish'
1+
allprojects {
2+
apply plugin: 'maven-publish'
23

3-
publishing {
4-
publications {
5-
mavenJava(MavenPublication) {
6-
pom {
7-
afterEvaluate {
8-
name = project.description
9-
description = project.description
10-
}
11-
url = linkScmUrl
12-
organization {
13-
name = 'Spring IO'
14-
url = 'https://spring.io/projects/spring-amqp'
15-
}
16-
licenses {
17-
license {
18-
name = 'Apache License, Version 2.0'
19-
url = 'https://www.apache.org/licenses/LICENSE-2.0.txt'
20-
distribution = 'repo'
4+
publishing {
5+
publications {
6+
mavenJava(MavenPublication) {
7+
pom {
8+
afterEvaluate {
9+
name = project.description
10+
description = project.description
2111
}
22-
}
23-
scm {
2412
url = linkScmUrl
25-
connection = linkScmConnection
26-
developerConnection = linkScmDevConnection
27-
}
28-
developers {
29-
developer {
30-
id = 'artembilan'
31-
name = 'Artem Bilan'
32-
email = 'artem.bilan@broadcom.com'
33-
roles = ['project lead']
34-
}
35-
developer {
36-
id = 'garyrussell'
37-
name = 'Gary Russell'
38-
email = 'github@gprussell.net'
39-
roles = ['project lead emeritus']
13+
organization {
14+
name = 'Spring IO'
15+
url = 'https://spring.io/projects/spring-amqp'
4016
}
41-
developer {
42-
id = 'sobychacko'
43-
name = 'Soby Chacko'
44-
email = 'soby.chacko@broadcom.com'
45-
roles = ['contributor']
17+
licenses {
18+
license {
19+
name = 'Apache License, Version 2.0'
20+
url = 'https://www.apache.org/licenses/LICENSE-2.0.txt'
21+
distribution = 'repo'
22+
}
4623
}
47-
developer {
48-
id = 'dsyer'
49-
name = 'Dave Syer'
50-
email = 'david.syer@broadcom.com'
51-
roles = ['project founder']
24+
scm {
25+
url = linkScmUrl
26+
connection = linkScmConnection
27+
developerConnection = linkScmDevConnection
5228
}
53-
developer {
54-
id = 'markfisher'
55-
name = 'Mark Fisher'
56-
email = 'mark.fisher@broadcom.com'
57-
roles = ['project founder']
29+
developers {
30+
developer {
31+
id = 'artembilan'
32+
name = 'Artem Bilan'
33+
email = 'artem.bilan@broadcom.com'
34+
roles = ['project lead']
35+
}
36+
developer {
37+
id = 'garyrussell'
38+
name = 'Gary Russell'
39+
email = 'github@gprussell.net'
40+
roles = ['project lead emeritus']
41+
}
42+
developer {
43+
id = 'markfisher'
44+
name = 'Mark Fisher'
45+
email = 'mark.ryan.fisher@gmail.com'
46+
roles = ['project founder and lead emeritus']
47+
}
5848
}
59-
developer {
60-
id = 'markpollack'
61-
name = 'Mark Pollack'
62-
email = 'mark.pollack@broadcom.com'
63-
roles = ['project founder']
49+
issueManagement {
50+
system = 'GitHub'
51+
url = linkIssue
6452
}
6553
}
66-
issueManagement {
67-
system = 'GitHub'
68-
url = linkIssue
69-
}
70-
}
71-
versionMapping {
72-
usage('java-api') {
73-
fromResolutionResult()
74-
}
75-
usage('java-runtime') {
76-
fromResolutionResult()
54+
versionMapping {
55+
usage('java-api') {
56+
fromResolutionResult()
57+
}
58+
usage('java-runtime') {
59+
fromResolutionResult()
60+
}
7761
}
7862
}
7963
}
8064
}
81-
}
65+
}

0 commit comments

Comments
 (0)