Search code examples
bashsearchclassjararchive

bash command: search for class in file system of jars


I'm wanting to recursively search my maven repository (an n folder deep heirachy of jars) for a specific class inside an unknown jar.

jar -tvf myJar.jar | grep ClassIWant.class works great for a known jar but I'm having problems piping/chaining bash commands to achieve a recursive search.

Any hints much appreciated.

Related: BASH :: find file in archive from command line


Solution

  • Post already exists. Solved here Find a jar file given the class name? Thanks for the alternatives.