java - How to programmatically search text in jar file? -
i want search sources.jar occurrence of search token.
in bash, extract jar stream , grep string:
unzip -p sources.jar | grep $search_token
in java, reading entries via jarinputstream looks rather tedious. there better/simpler way (for both, looping , grepping)?
is there better/simpler way (for both, looping , grepping)?
in short, no (probably).
(i guess might lucky, , find existing java utility command has written. don't rate chances though.)
update
it lucky day!
http://metastatic.org/source/jargrep.java
note code gpl 2. respect license!
Comments
Post a Comment