diff options
Diffstat (limited to 'xlint')
-rwxr-xr-x | xlint | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/xlint b/xlint index 7ad0658..8d4775f 100755 --- a/xlint +++ b/xlint @@ -243,13 +243,14 @@ for template; do done fi - if [ -f /usr/share/spdx/license.lst ]; then + : ${LICENSE_LIST:=/usr/share/spdx/license.lst} + if [ -f "${LICENSE_LIST}" ]; then sed -n 's/license="\(.*\)"/\1/p' "$template" | tr , "\n" | while read -r l; do if echo "$l" | grep -q 'custom:'; then continue fi - if ! grep -q "^${l}$" /usr/share/spdx/license.lst; then + if ! grep -q "^${l}$" "${LICENSE_LIST}"; then scan "license=.*$l" "license '$l' is not SPDX" fi done |