我創建了一個簡單的Maven項目(打包類型 - Jar),它依賴於Spring和My Sql庫(mysql-connector)。當我用$mvn package
打包這個項目時,我在成功執行這個命令後得到了一個jar文件。jar-with-dependencies Maven Assembly
我也想在輸出中包括jar文件中所有的依賴,所以我加了一個「罐子與 - 依賴」裝配描述,但作爲文件說:
The `jar-with-dependencies` descriptor builds a JAR archive with the contents of the main project jar along with the unpacked contents of all the project’s runtime dependencies.
我想包括JAR
表單中的依賴項,而不是unpacked
的方式。我怎樣才能做到這一點?