Skip to content

Commit

Permalink
fix: correct config of maven assembly plugin (#116)
Browse files Browse the repository at this point in the history
use `mvn package` to generate single JAR with dependencies

fixes #109
  • Loading branch information
nielm authored May 27, 2024
1 parent 6ea341e commit 380799b
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "1.22.0"
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ mvn generate-resources compile exec:java \
### Generate JAR with dependencies and run from JAR file

```sh
mvn clean generate-resources compile assembly:assembly
mvn clean generate-resources compile package

java -jar target/spanner-ddl-diff-*-jar-with-dependencies.jar \
--allowRecreateIndexes \
Expand Down
17 changes: 16 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.google.cloud.solutions</groupId>
<artifactId>spanner-ddl-diff</artifactId>
<version>1.0</version>
<version>1.22.0</version>
<name>spanner-ddl-diff</name>
<description>Spanner DDL parser and differ</description>
<properties>
Expand All @@ -40,6 +40,7 @@
<auto-value.version>1.10.4</auto-value.version>
<error-prone.version>2.27.1</error-prone.version>
<maven-checkstyle-plugin.version>3.3.1</maven-checkstyle-plugin.version>
<maven-assembly-plugin.version>3.7.1</maven-assembly-plugin.version>
</properties>
<dependencies>
<dependency>
Expand Down Expand Up @@ -106,6 +107,10 @@
<artifactId>maven-failsafe-plugin</artifactId>
<version>${maven-surefire-plugin.version}</version>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>${maven-assembly-plugin.version}</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
Expand Down Expand Up @@ -246,6 +251,7 @@
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>${maven-assembly-plugin.version}</version>
<configuration>
<archive>
<manifest>
Expand All @@ -256,6 +262,15 @@
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<goals>
<goal>single</goal>
</goals>
<phase>package</phase>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.diffplug.spotless</groupId>
Expand Down
14 changes: 14 additions & 0 deletions release-please-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"packages": {
".": {
"changelog-path": "CHANGELOG.md",
"release-type": "maven",
"bump-minor-pre-major": false,
"bump-patch-for-minor-pre-major": false,
"draft": false,
"prerelease": false,
"include-component-in-tag": false
}
},
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json"
}

0 comments on commit 380799b

Please sign in to comment.