Remove the transformed output directory before executing JakartaTransformer

Closes #30086

Signed-off-by: rmartinc <rmartinc@redhat.com>
This commit is contained in:
rmartinc 2024-06-03 13:21:26 +02:00 committed by Marek Posolda
parent 56c955df20
commit 536534dd25
5 changed files with 9 additions and 26 deletions

View file

@ -94,8 +94,8 @@
<configuration>
<target>
<property name="plugin_classpath" refid="maven.plugin.classpath" />
<delete dir="${jakarta-transformer-target}"/>
<java classname="org.eclipse.transformer.cli.JakartaTransformerCLI" fork="true">
<arg value="-o" />
<arg value="${jakarta-transformer-sources}" />
<arg value="${jakarta-transformer-target}" />
<classpath>

View file

@ -115,8 +115,8 @@
<configuration>
<target>
<property name="plugin_classpath" refid="maven.plugin.classpath" />
<delete dir="${jakarta-transformer-target}"/>
<java classname="org.eclipse.transformer.cli.JakartaTransformerCLI" fork="true">
<arg value="-o" />
<arg value="${jakarta-transformer-sources}" />
<arg value="${jakarta-transformer-target}" />
<classpath>

View file

@ -55,8 +55,8 @@
<configuration>
<target>
<property name="plugin_classpath" refid="maven.plugin.classpath" />
<delete dir="${jakarta-transformer-target}"/>
<java classname="org.eclipse.transformer.cli.JakartaTransformerCLI" fork="true">
<arg value="-o" />
<arg value="${jakarta-transformer-sources}" />
<arg value="${jakarta-transformer-target}" />
<classpath>

View file

@ -93,24 +93,14 @@
<configuration>
<target>
<property name="plugin_classpath" refid="maven.plugin.classpath"/>
<delete dir="${jakarta-transformer-target}"/>
<java classname="org.eclipse.transformer.cli.JakartaTransformerCLI" fork="true">
<arg value="-o"/>
<arg value="${jakarta-transformer-sources}"/>
<arg value="${jakarta-transformer-target}"/>
<classpath>
<pathelement path="${plugin_classpath}"/>
</classpath>
</java>
<!-- Possibility to override classes for admin-client-jee -->
<!-- Remove this comment in that case
<touch>
<fileset dir="${jakarta-transformer-target}"/>
</touch>
<copy todir="${jakarta-transformer-target}" overwrite="false">
<fileset dir="${jakarta-transformer-target}/tmp"/>
</copy>
<delete dir="${jakarta-transformer-target}/tmp"/>
-->
</target>
</configuration>
</execution>

View file

@ -16,8 +16,8 @@
<maven.compiler.target>17</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jakarta-transformer-sources>${project.basedir}/../servlets</jakarta-transformer-sources>
<jakarta-transformer-target>${project.basedir}</jakarta-transformer-target>
<jakarta-transformer-sources>${project.basedir}/../servlets/src</jakarta-transformer-sources>
<jakarta-transformer-target>${project.basedir}/src</jakarta-transformer-target>
</properties>
<dependencies>
@ -96,21 +96,14 @@
<configuration>
<target>
<property name="plugin_classpath" refid="maven.plugin.classpath"/>
<delete dir="${jakarta-transformer-target}"/>
<java classname="org.eclipse.transformer.cli.JakartaTransformerCLI" fork="true">
<arg value="-o"/>
<arg value="${jakarta-transformer-sources}"/>
<arg value="${jakarta-transformer-target}/tmp"/>
<arg value="${jakarta-transformer-target}"/>
<classpath>
<pathelement path="${plugin_classpath}"/>
</classpath>
</java>
<touch>
<fileset dir="${jakarta-transformer-target}"/>
</touch>
<copy todir="${jakarta-transformer-target}" overwrite="false">
<fileset dir="${jakarta-transformer-target}/tmp"/>
</copy>
<delete dir="${jakarta-transformer-target}/tmp"/>
</target>
</configuration>
</execution>