How to Change Spring Repackage Boot Boot File?

I want to change the application.properties of the jar file after building the spring boot application. I used jar xf to extract the jar file and then changed the properties file, but after jar-ed ( jar -0cf ) it did not work with the printout:

there is no main attribute of the manifest in <filename> .jar

Anyway, to do this and how?

+5
source share
1 answer

A jar file is just a zip file. You can open it and add the file using any tools that manage zip files.

Or if you want to update using the jar command line, you can do this using this syntax.

jar uf jar-file input-file(s)

As described here:

https://docs.oracle.com/javase/tutorial/deployment/jar/update.html

+1
source

Source: https://habr.com/ru/post/1261117/


All Articles