Skip to content

Commit 3fdbf0f

Browse files
authored
Merge pull request jenkinsci#243 from timja/update-pom
Cleanup pom, add bom
2 parents c1aa272 + b50f85b commit 3fdbf0f

7 files changed

Lines changed: 52 additions & 93 deletions

File tree

pom.xml

Lines changed: 24 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<groupId>org.jenkins-ci.plugins</groupId>
77
<artifactId>plugin</artifactId>
8-
<version>4.10</version>
8+
<version>4.15</version>
99
<relativePath />
1010
</parent>
1111

@@ -50,15 +50,18 @@
5050
<revision>1.33.0</revision>
5151
<changelist>-SNAPSHOT</changelist>
5252
<gitHubRepo>jenkinsci/github-plugin</gitHubRepo>
53-
<jenkins.version>2.164.3</jenkins.version>
53+
<jenkins.version>2.222.4</jenkins.version>
5454
<release.skipTests>false</release.skipTests>
5555
<maven.javadoc.skip>true</maven.javadoc.skip>
5656
<findbugs-maven-plugin.version>3.0.4</findbugs-maven-plugin.version>
5757
<hamcrest.version>2.2</hamcrest.version>
5858
<concurrency>1</concurrency>
5959
<java.level>8</java.level>
6060
<workflow.version>1.14.2</workflow.version>
61-
<configuration-as-code.version>1.32</configuration-as-code.version>
61+
<tagNameFormat>v@{project.version}</tagNameFormat>
62+
<spotbugs.threshold>Low</spotbugs.threshold>
63+
<spotbugs.effort>Max</spotbugs.effort>
64+
<spotbugs.failOnError>false</spotbugs.failOnError>
6265
</properties>
6366

6467
<repositories>
@@ -79,7 +82,7 @@
7982
<dependency>
8083
<groupId>org.apache.commons</groupId>
8184
<artifactId>commons-lang3</artifactId>
82-
<version>3.9</version>
85+
<version>3.11</version>
8386
</dependency>
8487
<dependency>
8588
<groupId>org.apache.commons</groupId>
@@ -95,43 +98,31 @@
9598
<dependency>
9699
<groupId>org.jenkins-ci.plugins</groupId>
97100
<artifactId>git</artifactId>
98-
<version>3.4.0</version>
99101
</dependency>
100102

101103
<dependency>
102104
<groupId>org.jenkins-ci.plugins</groupId>
103105
<artifactId>scm-api</artifactId>
104-
<version>2.2.0</version>
105106
</dependency>
106107

107108
<dependency>
108109
<groupId>org.jenkins-ci.plugins</groupId>
109110
<artifactId>credentials</artifactId>
110-
<version>2.1.13</version>
111111
</dependency>
112112

113113
<dependency>
114114
<groupId>org.jenkins-ci.plugins</groupId>
115115
<artifactId>plain-credentials</artifactId>
116-
<version>1.1</version>
117-
</dependency>
118-
119-
<dependency>
120-
<groupId>org.jenkins-ci.plugins</groupId>
121-
<artifactId>structs</artifactId>
122-
<version>1.17</version>
123116
</dependency>
124117

125118
<dependency>
126119
<groupId>org.jenkins-ci.plugins</groupId>
127120
<artifactId>token-macro</artifactId>
128-
<version>1.12.1</version>
129121
</dependency>
130122

131123
<dependency>
132124
<groupId>org.jenkins-ci.plugins</groupId>
133125
<artifactId>display-url-api</artifactId>
134-
<version>2.0</version>
135126
</dependency>
136127

137128
<dependency>
@@ -153,7 +144,6 @@
153144
<dependency>
154145
<groupId>org.jenkins-ci.plugins</groupId>
155146
<artifactId>apache-httpcomponents-client-4-api</artifactId>
156-
<version>4.5.3-2.1</version>
157147
<scope>test</scope>
158148
</dependency>
159149

@@ -181,7 +171,6 @@
181171
<dependency>
182172
<groupId>junit</groupId>
183173
<artifactId>junit</artifactId>
184-
<version>4.13</version>
185174
<scope>test</scope>
186175
</dependency>
187176

@@ -196,29 +185,24 @@
196185
<dependency>
197186
<groupId>org.jenkins-ci.plugins</groupId>
198187
<artifactId>matrix-auth</artifactId>
199-
<version>1.1</version>
200188
<scope>test</scope>
201189
</dependency>
202190

203191
<dependency>
204192
<groupId>io.jenkins</groupId>
205193
<artifactId>configuration-as-code</artifactId>
206-
<version>${configuration-as-code.version}</version>
207194
<scope>test</scope>
208195
</dependency>
209196

210197
<dependency>
211-
<groupId>io.jenkins</groupId>
212-
<artifactId>configuration-as-code</artifactId>
213-
<version>${configuration-as-code.version}</version>
214-
<classifier>tests</classifier>
198+
<groupId>io.jenkins.configuration-as-code</groupId>
199+
<artifactId>test-harness</artifactId>
215200
<scope>test</scope>
216201
</dependency>
217202

218203
<dependency>
219204
<groupId>org.jenkins-ci.plugins.workflow</groupId>
220205
<artifactId>workflow-cps</artifactId>
221-
<version>${workflow.version}</version>
222206
<scope>test</scope>
223207
<exclusions>
224208
<exclusion>
@@ -228,11 +212,15 @@
228212
</exclusion>
229213
</exclusions>
230214
</dependency>
215+
<dependency>
216+
<groupId>org.jenkins-ci.plugins.workflow</groupId>
217+
<artifactId>workflow-durable-task-step</artifactId>
218+
<scope>test</scope>
219+
</dependency>
231220

232221
<dependency>
233222
<groupId>org.jenkins-ci.plugins.workflow</groupId>
234223
<artifactId>workflow-job</artifactId>
235-
<version>${workflow.version}</version>
236224
<scope>test</scope>
237225
</dependency>
238226

@@ -290,24 +278,24 @@
290278
</exclusions>
291279
</dependency>
292280

293-
<dependency>
294-
<groupId>xml-apis</groupId>
295-
<artifactId>xml-apis</artifactId>
296-
<version>1.4.01</version>
297-
<scope>test</scope>
298-
</dependency>
299-
300281
<dependency>
301282
<groupId>io.rest-assured</groupId>
302283
<artifactId>rest-assured</artifactId>
303-
<version>3.3.0</version>
284+
<version>4.3.3</version>
304285
<scope>test</scope>
305286
</dependency>
306287

307288
</dependencies>
308289

309290
<dependencyManagement>
310291
<dependencies>
292+
<dependency>
293+
<groupId>io.jenkins.tools.bom</groupId>
294+
<artifactId>bom-2.222.x</artifactId>
295+
<version>20</version>
296+
<scope>import</scope>
297+
<type>pom</type>
298+
</dependency>
311299
<dependency>
312300
<groupId>org.jenkins-ci</groupId>
313301
<artifactId>annotation-indexer</artifactId>
@@ -321,7 +309,7 @@
321309
<plugin>
322310
<groupId>nl.geodienstencentrum.maven</groupId>
323311
<artifactId>sass-maven-plugin</artifactId>
324-
<version>2.14</version>
312+
<version>3.7.2</version>
325313
<executions>
326314
<execution>
327315
<goals>
@@ -336,7 +324,7 @@
336324

337325
<plugin>
338326
<artifactId>maven-checkstyle-plugin</artifactId>
339-
<version>2.16</version>
327+
<version>3.1.1</version>
340328
<executions>
341329
<execution>
342330
<id>checkstyle</id>
@@ -359,38 +347,6 @@
359347
</suppressionsLocation>
360348
</configuration>
361349
</plugin>
362-
363-
<plugin>
364-
<groupId>org.codehaus.mojo</groupId>
365-
<artifactId>findbugs-maven-plugin</artifactId>
366-
<version>${findbugs-maven-plugin.version}</version>
367-
<configuration>
368-
<effort>Max</effort>
369-
<threshold>Low</threshold>
370-
<xmlOutput>true</xmlOutput>
371-
<failOnError>false</failOnError>
372-
</configuration>
373-
<executions>
374-
<execution>
375-
<goals>
376-
<goal>check</goal>
377-
</goals>
378-
</execution>
379-
</executions>
380-
</plugin>
381-
382-
<plugin>
383-
<artifactId>maven-release-plugin</artifactId>
384-
<configuration>
385-
<tagNameFormat>v@{project.version}</tagNameFormat>
386-
<mavenExecutorId>forked-path</mavenExecutorId>
387-
<useReleaseProfile>false</useReleaseProfile>
388-
<preparationGoals>clean install</preparationGoals>
389-
<goals>deploy</goals>
390-
<arguments>${arguments}</arguments>
391-
<releaseProfiles>jenkins-release,${releaseProfiles}</releaseProfiles>
392-
</configuration>
393-
</plugin>
394350
</plugins>
395351
</build>
396352
</project>

src/main/java/org/jenkinsci/plugins/github/internal/GitHubClientCacheOps.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ protected String applyNullSafe(@Nonnull Cache cache) {
182182
private static class NotInCachesFilter implements DirectoryStream.Filter<Path> {
183183
private final Set<String> activeCacheNames;
184184

185-
public NotInCachesFilter(Set<String> activeCacheNames) {
185+
NotInCachesFilter(Set<String> activeCacheNames) {
186186
this.activeCacheNames = activeCacheNames;
187187
}
188188

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,13 @@
1-
global.config.url.is.empty=The Jenkins URL is empty. Explicitly set the Jenkins URL in the global configuration or in the GitHub plugin configuration to manage webhooks.
2-
global.config.hook.url.is.malformed=There is a malformed GitHub webhook URL in the global configuration ({0}). Please ensure that the Jenkins URL is valid and ends with a forward slash or use the webhook URL override.
1+
global.config.url.is.empty=The Jenkins URL is empty. Explicitly set the Jenkins URL in the global configuration \
2+
or in the GitHub plugin configuration to manage webhooks.
3+
global.config.hook.url.is.malformed=There is a malformed GitHub webhook URL in the global configuration ({0}). \
4+
Please ensure that the Jenkins URL is valid and ends with a forward slash or use the webhook URL override.
35
common.expandable.message.title=Expandable message
46
hooks.problem.administrative.monitor.displayname=GitHub Hooks Problems
5-
hooks.problem.administrative.monitor.description=Some of the webhooks failed to be registered or were removed. You can view a detailed list of them at this page. Also you can manage the list of ignored repos.
6-
github.trigger.check.method.warning.details=The webhook for repo {0}/{1} on {2} failed to be registered or was removed. More info can be found on the global configuration page. This message will be dismissed if Jenkins receives a PING event from repo webhook or if you add the repo to the ignore list in the global configuration.
7+
hooks.problem.administrative.monitor.description=Some of the webhooks failed to be registered or were removed. \
8+
You can view a detailed list of them at this page. Also you can manage the list of ignored repos.
9+
github.trigger.check.method.warning.details=The webhook for repo {0}/{1} on {2} failed to be registered \
10+
or was removed. \
11+
More info can be found on the global configuration page. This message will be dismissed if Jenkins receives \
12+
a PING event from repo webhook or if you add the repo to the ignore list in the global configuration.
713
unknown.error=Unknown error

src/main/resources/org/jenkinsci/plugins/github/admin/GitHubHookRegisterProblemMonitor/index.properties

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,11 @@ ignored.projects=Ignored Projects
55
project.header=Project
66
message.header=Message
77
help.for.problems=This table shows any problems with registering/removing repo webhooks. \
8-
A message will be dismissed if Jenkins receives a PING event from the corresponding repo webhook, or if you add the repo to the ignore list. These messages will not be saved to disk, \
8+
A message will be dismissed if Jenkins receives a PING event from the corresponding repo webhook, \
9+
or if you add the repo to the ignore list. These messages will not be saved to disk, \
910
so they will all be cleared when Jenkins restarts.
10-
help.for.ignored=This table lists any ignored projects. Any problem with the repos in this list will be declined by administrative monitor. \
11+
help.for.ignored=This table lists any ignored projects. Any problem with the repos in this list will be declined by \
12+
administrative monitor. \
1113
You can remove a repo from this list. This list will be saved on each change and reloaded when Jenkins restarts.
1214
help.for.page.and.debug.shows=This page shows problems with webhooks, and ignored projects.
1315
help.for.page.and.debug.system.pre=A detailed stacktrace for any of the problems can be found in the
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
view=View
22
dismiss=Dismiss
3-
hook.registering.problem=There were some problems while registering or removing one or more GitHub webhooks. Would you like to view the problems?
3+
hook.registering.problem=There were some problems while registering or removing one or more GitHub webhooks. \
4+
Would you like to view the problems?

src/test/java/org/jenkinsci/plugins/github/status/sources/ManuallyEnteredRepositorySourceTest.java

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,16 @@
66
import org.junit.runner.RunWith;
77
import org.kohsuke.github.GHRepository;
88
import org.mockito.Answers;
9-
import org.mockito.Matchers;
109
import org.mockito.Mock;
11-
import org.mockito.Mockito;
1210
import org.mockito.runners.MockitoJUnitRunner;
1311

1412
import java.io.PrintStream;
1513
import java.util.List;
1614

15+
import static org.hamcrest.MatcherAssert.assertThat;
1716
import static org.hamcrest.collection.IsCollectionWithSize.hasSize;
18-
import static org.junit.Assert.assertThat;
1917
import static org.mockito.Matchers.eq;
18+
import static org.mockito.Mockito.*;
2019
import static org.mockito.Mockito.doReturn;
2120
import static org.mockito.Mockito.verify;
2221

@@ -33,12 +32,11 @@ public class ManuallyEnteredRepositorySourceTest {
3332

3433
@Test
3534
public void nullName() {
36-
ManuallyEnteredRepositorySource instance = Mockito.spy(new ManuallyEnteredRepositorySource("https://github.com/jenkinsci/jenkins"));
37-
doReturn(null).when(instance).createName(Matchers.anyString());
35+
ManuallyEnteredRepositorySource instance = spy(new ManuallyEnteredRepositorySource("a"));
3836
doReturn(logger).when(listener).getLogger();
3937
List<GHRepository> repos = instance.repos(run, listener);
4038
assertThat("size", repos, hasSize(0));
4139
verify(listener).getLogger();
42-
verify(logger).printf(eq("Unable to match %s with a GitHub repository.%n"), eq("https://github.com/jenkinsci/jenkins"));
40+
verify(logger).printf(eq("Unable to match %s with a GitHub repository.%n"), eq("a"));
4341
}
4442
}

src/test/resources/checkstyle/checkstyle-config.xml

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0"?>
22
<!DOCTYPE module PUBLIC
33
"-//Puppy Crawl//DTD Check Configuration 1.3//EN"
4-
"http://www.puppycrawl.com/dtds/configuration_1_3.dtd">
4+
"https://checkstyle.org/dtds/configuration_1_3.dtd">
55

66
<!--
77
@@ -32,6 +32,7 @@
3232

3333

3434
<module name="Checker">
35+
<property name="cacheFile" value="${checkstyle.cache.file}"/>
3536
<!--
3637
If you set the basedir property below, then all reported file
3738
names will be relative to the specified directory. See
@@ -46,7 +47,11 @@
4647
<property name="lineSeparator" value="lf"/>
4748
</module>
4849

49-
50+
<!-- Checks for Size Violations. -->
51+
<!-- See https://checkstyle.org/config_sizes.html -->
52+
<module name="LineLength">
53+
<property name="max" value="120"/>
54+
</module>
5055

5156
<!-- Checks that property files contain the same keys. -->
5257
<!-- See http://checkstyle.sf.net/config_misc.html#Translation -->
@@ -69,8 +74,6 @@
6974

7075
<module name="TreeWalker">
7176

72-
<property name="cacheFile" value="${checkstyle.cache.file}"/>
73-
7477
<!-- required for SuppressWarningsFilter (and other Suppress* rules not used here) -->
7578
<!-- see http://checkstyle.sourceforge.net/config_annotation.html#SuppressWarningsHolder -->
7679
<module name="SuppressWarningsHolder"/>
@@ -123,9 +126,6 @@
123126

124127
<!-- Checks for Size Violations. -->
125128
<!-- See http://checkstyle.sf.net/config_sizes.html -->
126-
<module name="LineLength">
127-
<property name="max" value="120"/>
128-
</module>
129129
<module name="MethodLength"/>
130130
<module name="ParameterNumber"/>
131131

@@ -185,10 +185,6 @@
185185
<!-- Miscellaneous other checks. -->
186186
<!-- See http://checkstyle.sf.net/config_misc.html -->
187187
<module name="ArrayTypeStyle"/>
188-
<module name="TodoComment">
189-
<property name="format" value="(TODO)|(FIXME)"/>
190-
<property name="severity" value="info"/>
191-
</module>
192188
<!--<module name="FinalParameters"/>-->
193189
<module name="UpperEll"/>
194190

0 commit comments

Comments
 (0)