Skip to content

Instantly share code, notes, and snippets.

@cypai
Created December 5, 2015 01:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cypai/a745d85285eafb3c90a5 to your computer and use it in GitHub Desktop.
Save cypai/a745d85285eafb3c90a5 to your computer and use it in GitHub Desktop.
sevntu-checkstyle-sonar-plugin pom
<?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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.github.sevntu.checkstyle</groupId>
<artifactId>sevntu-checkstyle-sonar-plugin</artifactId>
<version>1.17.0</version>
<packaging>sonar-plugin</packaging>
<name>SevNTU Checkstyle Sonar Extension Plugin</name>
<description>SevNTU Checkstyle extension plugin for Sonar</description>
<dependencies>
<dependency>
<groupId>org.codehaus.sonar</groupId>
<artifactId>sonar-plugin-api</artifactId>
<version>2.8</version>
</dependency>
<dependency>
<groupId>com.github.sevntu.checkstyle</groupId>
<artifactId>sevntu-checks</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>2.4.2</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<dependencyReducedPomLocation>${project.build.directory}/dependency-reduced-pom.xml</dependencyReducedPomLocation>
<artifactSet>
<includes>
<include>com.github.sevntu.checkstyle</include>
</includes>
</artifactSet>
<relocations>
<relocation>
<pattern>com.google.common</pattern>
<shadedPattern>com.puppycrawl.tools.checkstyle.guava</shadedPattern>
</relocation>
</relocations>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>xml-maven-plugin</artifactId>
<version>1.0</version>
<executions>
<execution>
<goals>
<goal>validate</goal>
</goals>
</execution>
</executions>
<configuration>
<validationSets>
<validationSet>
<dir>src/main/resources/com/github/sevntu/checkstyle/sonar</dir>
</validationSet>
</validationSets>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.sonar</groupId>
<artifactId>sonar-packaging-maven-plugin</artifactId>
<version>1.7</version>
<extensions>true</extensions>
<configuration>
<pluginClass>com.github.sevntu.checkstyle.sonar.CheckstyleExtensionPlugin</pluginClass>
<basePlugin>checkstyle</basePlugin>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>wagon-maven-plugin</artifactId>
<version>1.0-beta-4</version>
<configuration>
<fromFile>${project.build.directory}/${project.build.finalName}.jar</fromFile>
<url>file://${basedir}/../gh-pages/sonar/</url>
</configuration>
</plugin>
</plugins>
</build>
<!-- That profile is from https://github.com/SonarSource/sonar-developer-toolset/tree/master/eclipse/m2e-error-disabler-plugin
to avoid errors in Eclipse -->
<profiles>
<profile>
<id>m2e</id>
<activation>
<!-- This profile is active only when used from Eclipse m2e and is used
only to store settings. -->
<property>
<name>m2e.version</name>
</property>
</activation>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.codehaus.sonar</groupId>
<artifactId>sonar-packaging-maven-plugin</artifactId>
<versionRange>[1.0,)</versionRange>
<goals>
<goal>check-dependencies</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.codehaus.mojo</groupId>
<artifactId>gwt-maven-plugin</artifactId>
<versionRange>[1.0,)</versionRange>
<goals>
<goal>compile</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.codehaus.sonar</groupId>
<artifactId>sonar-dev-maven-plugin</artifactId>
<versionRange>[1.0,)</versionRange>
<goals>
<goal>trim</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<versionRange>[1.0,)</versionRange>
<goals>
<goal>unpack</goal>
<goal>copy</goal>
<goal>copy-dependencies</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.codehaus.mojo</groupId>
<artifactId>native2ascii-maven-plugin</artifactId>
<versionRange>[1.0-alpha-1,)</versionRange>
<goals>
<goal>native2ascii</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
</profile>
</profiles>
</project>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment