Skip to content

Commit ef814b0

Browse files
authored
[Build] Explicitly include Gherkin as a dependency for shading (#2518)
With Maven 3.8.5 as used in CI only direct dependencies can be shaded. So to build correctly Gherkin has to be included as a direct dependency. This however confuses revapi because it does not seem to account for shading. And has been disabled for now.
1 parent bb05e25 commit ef814b0

File tree

4 files changed

+37
-8
lines changed

4 files changed

+37
-8
lines changed

core/pom.xml

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
1+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
23
<modelVersion>4.0.0</modelVersion>
34

45
<parent>
@@ -45,6 +46,10 @@
4546
</dependencyManagement>
4647

4748
<dependencies>
49+
<dependency>
50+
<groupId>io.cucumber</groupId>
51+
<artifactId>gherkin</artifactId>
52+
</dependency>
4853
<dependency>
4954
<groupId>io.cucumber</groupId>
5055
<artifactId>cucumber-gherkin</artifactId>
@@ -228,7 +233,7 @@
228233
<id>enforce-dependency-convergence</id>
229234
<configuration>
230235
<rules>
231-
<dependencyConvergence />
236+
<dependencyConvergence/>
232237
</rules>
233238
</configuration>
234239
<goals>
@@ -265,12 +270,13 @@
265270
<include>io.cucumber:gherkin</include>
266271
</includes>
267272
</artifactSet>
268-
<relocations>
269-
<relocation>
270-
<pattern>gherkin</pattern>
271-
<shadedPattern>io.cucumber.core.internal.gherkin</shadedPattern>
272-
</relocation>
273-
</relocations>
273+
<!-- Do not enable relocation. Stuck with it until the next major. -->
274+
<!--<relocations>-->
275+
<!-- <relocation>-->
276+
<!-- <pattern>io.cucumber.gherkin</pattern>-->
277+
<!-- <shadedPattern>io.cucumber.core.internal.gherkin</shadedPattern>-->
278+
<!-- </relocation>-->
279+
<!--</relocations>-->
274280
<filters>
275281
<filter>
276282
<artifact>io.cucumber:gherkin</artifact>

gherkin-messages/pom.xml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,15 @@
5757

5858
<build>
5959
<plugins>
60+
<!-- Not quite compatible with the transition to Maven 3.8.3 #2518 -->
61+
<plugin>
62+
<groupId>org.revapi</groupId>
63+
<artifactId>revapi-maven-plugin</artifactId>
64+
<configuration>
65+
<skip>true</skip>
66+
</configuration>
67+
</plugin>
68+
6069
<plugin>
6170
<groupId>org.apache.maven.plugins</groupId>
6271
<artifactId>maven-shade-plugin</artifactId>

java/pom.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,13 @@
9090
<plugin>
9191
<groupId>org.codehaus.gmaven</groupId>
9292
<artifactId>groovy-maven-plugin</artifactId>
93+
<dependencies>
94+
<dependency>
95+
<groupId>io.cucumber</groupId>
96+
<artifactId>gherkin</artifactId>
97+
<version>${gherkin.version}</version>
98+
</dependency>
99+
</dependencies>
93100
<executions>
94101
<execution>
95102
<id>generate-i18n-sources</id>

java8/pom.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,13 @@
9191
<plugin>
9292
<groupId>org.codehaus.gmaven</groupId>
9393
<artifactId>groovy-maven-plugin</artifactId>
94+
<dependencies>
95+
<dependency>
96+
<groupId>io.cucumber</groupId>
97+
<artifactId>gherkin</artifactId>
98+
<version>${gherkin.version}</version>
99+
</dependency>
100+
</dependencies>
94101
<executions>
95102
<execution>
96103
<id>generate-i18n-sources</id>

0 commit comments

Comments
 (0)