Last active
December 20, 2015 05:29
-
-
Save thvitt/6078291 to your computer and use it in GitHub Desktop.
A POM file to mirror a (composite) p2 repository and create a simple one out of it. Requires Maven 3, uses Tycho Extras.Use the properties to configure it first.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<project xmlns="http://maven.apache.org/POM/4.0.0"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>info.textgrid</groupId> | |
<artifactId>mirrortest</artifactId> | |
<packaging>pom</packaging> | |
<version>1.0-SNAPSHOT</version> | |
<prerequisites> | |
<maven>3.0.0</maven> | |
</prerequisites> | |
<properties> | |
<source>http://www.textgridlab.org/updates/stable</source> | |
<dest>${basedir}/target/repository</dest> | |
</properties> | |
<pluginRepositories> | |
<pluginRepository> | |
<id>dh-nexus-snapshots</id> | |
<name>Digital-Humanities.de's Nexus Snapshots</name> | |
<url>http://dev.digital-humanities.de/nexus/content/repositories/snapshots</url> | |
<layout>default</layout> | |
<snapshots> | |
<enabled>true</enabled> | |
<updatePolicy>always</updatePolicy> | |
<checksumPolicy>warn</checksumPolicy> | |
</snapshots> | |
</pluginRepository> | |
</pluginRepositories> | |
<build> | |
<plugins> | |
<plugin> | |
<groupId>org.eclipse.tycho.extras</groupId> | |
<artifactId>tycho-p2-extras-plugin</artifactId> | |
<version>0.18.1</version> | |
<executions> | |
<execution> | |
<id>copy-to-central-site</id> | |
<phase>package</phase> | |
<goals> | |
<goal>mirror</goal> | |
</goals> | |
<configuration> | |
<source> | |
<repository> | |
<url>${source}</url> | |
</repository> | |
</source> | |
<destination>${dest}</destination> | |
</configuration> | |
</execution> | |
</executions> | |
</plugin> | |
<plugin> | |
<groupId>info.textgrid.utils</groupId> | |
<artifactId>p2content-maven-plugin</artifactId> | |
<version>0.1-SNAPSHOT</version> | |
<executions> | |
<execution> | |
<id>generate-index-html</id> | |
<phase>install</phase> | |
<goals> | |
<goal>create</goal> | |
</goals> | |
<configuration> | |
<outputFile>${dest}/index.html</outputFile> | |
<repository>${dest}</repository> | |
</configuration> | |
</execution> | |
</executions> | |
</plugin> | |
</plugins> | |
</build> | |
</project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment