Separate a script to get all jdeps reports

This commit is contained in:
Sanne Grinovero
2018-07-06 12:24:25 +01:00
parent e240d66ddd
commit f525d77ca5

23
jdeps-reports.sh Executable file
View File

@@ -0,0 +1,23 @@
#!/usr/bin/env bash
# Expects JDK 10+ on classpath
## Update the classpath definition used by this script:
mvn dependency:build-classpath -Dmdep.outputFile=cp.txt > /dev/null
CLASSPATH=`cat cp.txt`
echo "Listing `jdeps --print-module-deps` for each dependency individually:"
IFS=':'; CLASSPATH_ARRAY=($CLASSPATH); unset IFS;
for dep in ${CLASSPATH_ARRAY[@]}
do
echo " "
echo "Dependency: $dep"
jdeps --print-module-deps $dep
done
echo " "
# TODO : combined report not supported by jdeps?
#echo "Listing `jdeps --print-module-deps` for all dependencies combined:"
#jdeps --print-module-deps -cp $CLASSPATH