Skip to content

Instantly share code, notes, and snippets.

@echeran
Last active December 27, 2015 07:42
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 echeran/add95eedb308c946ec98 to your computer and use it in GitHub Desktop.
Save echeran/add95eedb308c946ec98 to your computer and use it in GitHub Desktop.
mvn-lein-test - pom.xml
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>com.mycompany.app</groupId>
<artifactId>my-app</artifactId>
<version>1</version>
<repositories>
<repository>
<id>clojars</id>
<name>Clojars</name>
<url>http://clojars.org/repo</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>org.clojure</groupId>
<artifactId>clojure</artifactId>
<version>1.7.0</version>
</dependency>
<dependency>
<groupId>leiningen</groupId>
<artifactId>leiningen</artifactId>
<version>2.5.3</version>
</dependency>
</dependencies>
<pluginRepositories>
<pluginRepository>
<id>clojars</id>
<name>Clojars</name>
<url>http://clojars.org/repo</url>
</pluginRepository>
</pluginRepositories>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.4.0</version>
<executions>
<execution>
<id>lein-clean</id>
<phase>clean</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>java</executable>
<arguments>
<argument>-classpath</argument>
<classpath/>
<argument>clojure.main</argument>
<argument>-m</argument>
<argument>leiningen.core.main</argument>
<argument>clean</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>lein-test</id>
<phase>test</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>java</executable>
<arguments>
<argument>-classpath</argument>
<classpath/>
<argument>clojure.main</argument>
<argument>-m</argument>
<argument>leiningen.core.main</argument>
<argument>test</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>lein-compile</id>
<phase>compile</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>java</executable>
<arguments>
<argument>-classpath</argument>
<classpath/>
<argument>clojure.main</argument>
<argument>-m</argument>
<argument>leiningen.core.main</argument>
<argument>compile</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>pkg-lein-clean</id>
<phase>package</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>java</executable>
<arguments>
<argument>-classpath</argument>
<classpath/>
<argument>clojure.main</argument>
<argument>-m</argument>
<argument>leiningen.core.main</argument>
<argument>clean</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>pkg-lein-uberjar</id>
<phase>package</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>java</executable>
<arguments>
<argument>-classpath</argument>
<classpath/>
<argument>clojure.main</argument>
<argument>-m</argument>
<argument>leiningen.core.main</argument>
<argument>uberjar</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.4</version>
<executions>
<execution>
<id>default-jar</id>
<phase/>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<version>2.4</version>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>
</project>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment