aboutsummaryrefslogtreecommitdiffstats
path: root/framework/src/onos/utils/jdvue/bin/jdvue-scan
blob: 216c68d7e412b99d2033fb0045d36ed913544251 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/bash
#-------------------------------------------------------------------------------
#   Java Package Dependency scanner
#
#   written by Thomas Vachuska
#                                                                    -- Doobs --
#-------------------------------------------------------------------------------

find "${@:-.}" -type f -name \*.java \
    | grep -v -E '/lost+found/|/target/' \
    | xargs grep -E "^[ \t]*import .*;.*|^[ \t]*package .*;.*" \
    | tr -d '\r' > jpd.db