Thursday, October 7, 2010

How to list all the jar contents in one line and redirect the output to a text file for easy searching

1. place all the jar files in a directory on a linux server

2.
$ cd jardirectory

3. list the files
$ for file in `ls | grep ".jar"`; do `unzip -l $file >> jarcontents.txt` ; done

4. use vi and search for entries
vi jarcontents.txt
In vi, type forward slash, and your search string.

No comments:

Post a Comment