0

For this Normally I used the command jar uvf app.war c:/key.txt This command copy key.txt file to the app.war folder. But I want, Key should copy to the sub folder of the app.war. For example after unzipping app/WEB-INF/key.txt.

Mark
  • 3,609
  • 1
  • 22
  • 33
Tamanna Iruu
  • 191
  • 3
  • 4
  • 12
  • possible duplicate of [how to add a java class to a folder within a jar file](http://stackoverflow.com/questions/1044243/how-to-add-a-java-class-to-a-folder-within-a-jar-file) – Schabowy Apr 19 '14 at 08:43

1 Answers1

2

You have to create directory WEB-INF beside war archive and put there your file key.txt. Then simply execute jar uvf app.war WEB-INF/key.txt

Reference: Updating a JAR File

Schabowy
  • 121
  • 1
  • 3