Find in What Jar a Class Is

Oh my. Somebody’s been exceedingly verbose… Here’s another attempt:

 
---

Comment

  1. Nice indeed.

    Being more of a stone men, I tend to use shell for that :

    #!/bin/sh if [ -z “$2” ] then echo Usage: $0 Directory ClassName exit 1 fi for f in $(find $1 -name ‘*.jar’) do jar tf $f | grep “$2” && echo “[in $f]” done

    To be completely honest, I never remember it correctly (damn jar options) and I copy it every time for my snippets … And it’s been stolen from here : http://www.jamesmurty.com/2008/02/19/find-class-in-jar/

    Pierre Rust · 2013-04-22 22:06 · #

your_ip_is_blacklisted_by sbl.spamhaus.org

---