Whamcloud - gitweb
LU-16707 scripts: ignore some files in license-status 33/57833/2
authorTimothy Day <timday@amazon.com>
Mon, 20 Jan 2025 21:07:13 +0000 (16:07 -0500)
committerOleg Drokin <green@whamcloud.com>
Fri, 7 Feb 2025 03:36:11 +0000 (03:36 +0000)
Many files in-tree don't need a SPDX tag - so lets
ignore them in license-status.

Test-Parameters: trivial
Signed-off-by: Timothy Day <timday@amazon.com>
Change-Id: I31a0ae474fce78885e0391544500c2339dae66d7
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/57833
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
contrib/scripts/license-status

index 7a60610..9d7d273 100755 (executable)
@@ -4,7 +4,7 @@
 #
 # Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved.
 #
-# Copyright (c) 2023-2024, Amazon and/or its affiliates. All rights reserved.
+# Copyright (c) 2023-2025, Amazon and/or its affiliates. All rights reserved.
 # Use is subject to license terms.
 #
 
 #
 
 export files="${1:-$(pwd)}"
+export file_paths=$(git ls-files "$files" | grep -v -f <(cat <<EOF
+Documentation
+LICENSES
+gitignore
+COPYING
+mailmap
+MAINTAINERS
+README
+requirements
+SECURITY
+kernel_patches
+crypto_patches
+EOF
+))
 
-for file in $(git ls-files "$files"); do
+for file in $file_paths; do
        if head -20 "$file" | grep -Ee 'SPDX' > /dev/null; then
                license="$(grep SPDX "$file" | awk '{ print $3; exit; }')"
                printf "%-10s %-15s %-s\n" "SPDX" "$license" "$file"