Skip to content

Instantly share code, notes, and snippets.

@ssavva05
Forked from craigew/pom.xml
Created August 30, 2019 14:07
Show Gist options
  • Save ssavva05/d0d305f2161ddccefc6100805db9418f to your computer and use it in GitHub Desktop.
Save ssavva05/d0d305f2161ddccefc6100805db9418f to your computer and use it in GitHub Desktop.
Example of profiles for dev and release
<profiles>
<profile>
<id>dev</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.liquibase</groupId>
<artifactId>liquibase-maven-plugin</artifactId>
<configuration>
<dropFirst>true</dropFirst>
<contexts>test</contexts>
<propertyFile>src/main/liquibase/properties/liquibase-dev.properties</propertyFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>update</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<skipTests>false</skipTests>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>release</id>
<build>
<plugins>
<plugin>
<groupId>org.liquibase</groupId>
<artifactId>liquibase-maven-plugin</artifactId>
<configuration>
<dropFirst>false</dropFirst>
<propertyFile>src/main/liquibase/properties/liquibase-release.properties</propertyFile>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>update</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<skipTests>true</skipTests>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment