Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/pull-request-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,9 @@ jobs:
- name: Build with Apache Maven
if: ${{ matrix.os != 'windows-latest' }}
run: mvn -U clean install -Djava.awt.headless=true -fae -B -Peverything
- name: Fail if there are uncommitted changes in public-suffix-list.txt
shell: bash
run: |
[[ -z $(git status --porcelain rt/transports/http/src/main/resources/mozilla/public-suffix-list.txt) ]] || { echo 'There are uncommitted changes in public-suffix-list.txt'; git status; git diff; exit 1; }
env:
MAVEN_OPTS: "-Xmx1024M"
19 changes: 16 additions & 3 deletions parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@
<cxf.geronimo.openapi.version>1.0.15</cxf.geronimo.openapi.version>
<cxf.glassfish.el.version>4.0.2</cxf.glassfish.el.version>
<cxf.glassfish.json.version>2.0.1</cxf.glassfish.json.version>
<cxf.groovy.version>4.0.27</cxf.groovy.version>
<cxf.hamcrest.version>3.0</cxf.hamcrest.version>
<cxf.hazelcast.version>5.5.0</cxf.hazelcast.version>
<cxf.hibernate.em.version>6.6.15.Final</cxf.hibernate.em.version>
Expand Down Expand Up @@ -585,7 +586,19 @@
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
<version>4.0.27</version>
<version>${cxf.groovy.version}</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.codehaus.gmaven</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<version>2.1.1</version>
<dependencies>
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
<version>${cxf.groovy.version}</version>
</dependency>
</dependencies>
</plugin>
Expand Down Expand Up @@ -2231,7 +2244,7 @@
<name>ekstazi</name>
</property>
</activation>

<build>
<plugins>
<plugin>
Expand All @@ -2252,7 +2265,7 @@
</execution>
</executions>
</plugin>

<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
Expand Down
100 changes: 46 additions & 54 deletions rt/transports/http/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -157,60 +157,52 @@
</extensions>
</configuration>
</plugin>
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>1.13.0</version>
<executions>
<execution>
<id>download-public-suffix-list</id>
<phase>generate-sources</phase>
<goals>
<goal>wget</goal>
</goals>
<configuration>
<url>${cxf.public.suffix.list.url}</url>
<outputDirectory>${project.build.outputDirectory}/mozilla</outputDirectory>
<outputFileName>public-suffix-list.txt</outputFileName>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>
com.googlecode.maven-download-plugin
</groupId>
<artifactId>
download-maven-plugin
</artifactId>
<versionRange>
[1.2.0,)
</versionRange>
<goals>
<goal>wget</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
<profiles>
<profile>
<id>online</id>
<activation>
<property>
<!-- Active by default, Inactive with -Doffline -->
<name>!offline</name>
</property>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.gmaven</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<executions>
<execution>
<id>download-public-suffix-list</id>
<phase>generate-sources</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<!-- Download the suffix file and store it locally only if the content changes -->
<!-- so that the file timestamp does not change on every build -->
<source>
import java.nio.file.Files
def newContent = new URL(project.properties['cxf.public.suffix.list.url']).text
String relPath = 'src/main/resources/mozilla/public-suffix-list.txt'
def destPath = java.nio.file.Path.of(project.properties['project.basedir'] + relPath)
if (!Files.exists(destPath) || !newContent.equals(destPath.getText('UTF-8'))) {
Files.createDirectories(destPath.getParent())
destPath.setText(newContent.toString(), 'UTF-8')
println('🚀 Updating ' + relPath)
} else {
println('✅ Up to date: ' + relPath)
}
</source>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>

</profile>
</profiles>
</project>
Loading
Loading