diff options
author | 0x5c <dev@0x5c.io> | 2024-02-11 00:55:52 -0800 |
---|---|---|
committer | Leah Neukirchen <leah@vuxu.org> | 2024-05-12 17:55:44 +0200 |
commit | ba08489e60f65c3c38fef11ed2f0b22b39586e7b (patch) | |
tree | 48a7b843c4250d732e9eca609533a5c8738aaf73 | |
parent | 3d95c314f4a12d163e3e8e0cdcaba2f621b6c90b (diff) | |
download | xtools-ba08489e60f65c3c38fef11ed2f0b22b39586e7b.tar.gz xtools-ba08489e60f65c3c38fef11ed2f0b22b39586e7b.tar.xz xtools-ba08489e60f65c3c38fef11ed2f0b22b39586e7b.zip |
xlint: accept full SPDX licence expressions
This changes makes xlint gracefully accept full SPDX licence expressions, while still evaluating only the individual licences in xlint. See void-linux/void-packages#48303
-rwxr-xr-x | xlint | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/xlint b/xlint index d9b4b85..5e6f1f4 100755 --- a/xlint +++ b/xlint @@ -420,7 +420,8 @@ for argument; do : "${LICENSE_LIST:=/usr/share/spdx/license.lst}" if [ -f "${LICENSE_LIST}" ]; then sed -n 's/license="\(.*\)"/\1/p' "$template" | - sed 's/ WITH /,/g' | + sed -E 's/ (WITH|OR|AND) /,/g' | + sed 's/[()]//g' | tr , "\n" | while read -r l; do case "$l" in |