java-tutorials/maven-modules/maven-profiles/pom.xml

96 lines
3.0 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<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">
<modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung</groupId>
<artifactId>maven-profiles</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>maven-profiles</name>
<profiles>
<profile>
<id>no-tests</id>
<properties>
<maven.test.skip>true</maven.test.skip>
</properties>
</profile>
<profile>
<id>integration-tests</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
</profile>
<profile>
<id>mutation-tests</id>
</profile>
<profile>
<id>active-on-jdk-11</id>
<activation>
<jdk>11</jdk>
</activation>
</profile>
<profile>
<id>active-on-windows-10</id>
<activation>
<os>
<name>windows 10</name>
<family>Windows</family>
<arch>amd64</arch>
<version>10.0</version>
</os>
</activation>
</profile>
<profile>
<id>active-on-property-environment</id>
<activation>
<property>
<name>environment</name>
<value>!test</value>
</property>
</activation>
</profile>
<profile>
<id>active-on-missing-file</id>
<activation>
<file>
<missing>target/testreport.html</missing>
</file>
</activation>
</profile>
<profile>
<id>active-on-present-file</id>
<activation>
<file>
<exists>target/artifact.jar</exists>
</file>
</activation>
</profile>
<profile>
<id>show-active-profiles</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-help-plugin</artifactId>
<version>${help.plugin.version}</version>
<executions>
<execution>
<id>show-profiles</id>
<phase>compile</phase>
<goals>
<goal>active-profiles</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<properties>
<help.plugin.version>3.2.0</help.plugin.version>
</properties>
</project>