How to read a .war file?
.war files are packed. You can extract the information by using either of the following commands:
jar -xvf Sample.war
unzip Sample.war
You should then be able to run cd /usr/local/standalone/deployments/Sample.war/WEB-INF/classes/
.war
files are zipped archives.
You can list what they contain with either
jar tvf Sample.war
or
zipinfo Sample.war
Should you want to see the content of files stored in an archive, you need to first extract it somewhere:
mkdir /tmp/foo
cd /tmp/foo
unzip /usr/local/standalone/deployments/Sample.war
ls -l WEB-INF/classes/
If you don't want to extract the file you can use vim filename.war
to read the contents of the file. You can read subdirectories of files by selecting them and pressing enter.