Skip to content

Commit b6d0489

Browse files
committed
Makes it easier to run samples from command line
1 parent 81fb052 commit b6d0489

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

apps/sparkpost-samples-app/pom.xml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
<artifactId>sparkpost-samples-app</artifactId>
1010
<name>Example use SparkPost library</name>
1111
<url>/apps/sparkpost-samples-app/</url>
12+
<packaging>jar</packaging>
1213

1314
<dependencies>
1415
<dependency>
@@ -73,6 +74,31 @@
7374
</execution>
7475
</executions>
7576
</plugin>
77+
78+
<!-- Maven Shade Plugin -->
79+
<plugin>
80+
<groupId>org.apache.maven.plugins</groupId>
81+
<artifactId>maven-shade-plugin</artifactId>
82+
<version>2.3</version>
83+
<executions>
84+
<!-- Run shade goal on package phase -->
85+
<execution>
86+
<phase>package</phase>
87+
<goals>
88+
<goal>shade</goal>
89+
</goals>
90+
<configuration>
91+
<transformers>
92+
<!-- add Main-Class to manifest file -->
93+
<transformer
94+
implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
95+
<mainClass>com.sparkpost.samples.DeliverabilityMetricsSample</mainClass>
96+
</transformer>
97+
</transformers>
98+
</configuration>
99+
</execution>
100+
</executions>
101+
</plugin>
76102
</plugins>
77103
</build>
78104

0 commit comments

Comments
 (0)