Skip to content

Commit

Permalink
added code to the pom to generate an empty javadoc jar
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt Stump committed May 29, 2012
1 parent fbe3d86 commit 669ce71
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 11 deletions.
31 changes: 20 additions & 11 deletions pom.xml
Expand Up @@ -50,17 +50,6 @@
<testSourceDirectory>test</testSourceDirectory>

<plugins>

<plugin>
<groupId>com.sourceninja</groupId>
<artifactId>sourceninja-maven-plugin</artifactId>
<version>0.1.1-SNAPSHOT</version>
<configuration>
<id>${env.PRODUCT_ID}</id>
<token>${env.PRODUCT_TOKEN}</token>
</configuration>
</plugin>

<plugin>
<artifactId>maven-plugin-plugin</artifactId>
<version>2.6</version>
Expand Down Expand Up @@ -96,6 +85,26 @@
</configuration>
</plugin>

<plugin>
<artifactId>exec-maven-plugin</artifactId>
<groupId>org.codehaus.mojo</groupId>
<executions>
<execution><!-- Run our version calculation script -->
<id>Generate Empty Javadoc</id>
<phase>package</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>${basedir}/scripts/emtpy-jar.sh</executable>
<arguments>
<argument>${project.build.directory}/${name}-${version}-javadoc.jar</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>

<plugin>
<artifactId>maven-source-plugin</artifactId>
<version>2.1.2</version>
Expand Down
10 changes: 10 additions & 0 deletions scripts/emtpy-jar.sh
@@ -0,0 +1,10 @@
#!/bin/sh
OUTPATH=$1

UUID=`uuidgen`
INPATH="/tmp/$UUID"

mkdir -p $INPATH
echo "Nobody here but us chickens" > $INPATH/README
jar cf $OUTPATH -C $INPATH README
rm -rf $INPATH

0 comments on commit 669ce71

Please sign in to comment.