Did this blog help you solve a problem? Tip me with Bitcoins at: 17dQktcAmU4urXz7tGk2sbuiCqykm3WLs6

Wednesday, November 11, 2009

Unpack a Java .war file on Mac OX S

Unpacking Java .war file on a Mac is not hard at all. For this demonstration, I'll use the sample.war file that comes with the Tomcat Installation.

Step 1: Fire up the terminal



Step 2: cd to the directory where the .war resides. In this case I moved it from the Tomcat directories to /sample beforehand.

# cd /sample

Step 3: Unpack the .war with the following command:

# jar -xvf sample.war



The contents of the .war are unpacked for you and placed in the same folder as the .war file.




Piece of Cake!!

1 comment:

Anonymous said...

Very helpful, thank you!