docs: name only the roles that ship and drop their licence leftovers
Name the roles under roles/ in the README intro and the Galaxy description, and drop the NOTICE and REUSE.toml entries and licence texts (Apache-2.0, EUPL-1.2, MIT) of roles that are not in the Collection. The reuse_lint.py wrapper only tolerated those unused texts, so the hook runs plain `reuse lint`. The GPL-3.0-only reason is ufw's before.rules.j2. Remove HANDOFF.md and .reuse from build_ignore (neither has existed) and correct the galaxy.yml comment on dependency bounds. Part of #164 Assisted-by: Claude Code
This commit is contained in:
1 parent
a52ff9948d
commit
90928cdfc0
15 files changed
+25
-406
No files matched your search
@@ -1,47 +0,0 @@
|
||||
# SPDX-FileCopyrightText: Defame1297 and contributors
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
"""Run `reuse lint`, tolerating only unused licence texts.
|
||||
|
||||
LICENSES/ carries licence texts (GPL-3.0-only, Apache-2.0, MIT,
|
||||
EUPL-1.2) before the roles that use them exist; reuse >= 6 reports those as
|
||||
non-compliant. Every other finding still fails. Once the extraction waves have brought
|
||||
in files for all of them, delete UNUSED_ALLOWED and call `reuse lint` directly.
|
||||
"""
|
||||
|
||||
import json
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
UNUSED_ALLOWED = {"GPL-3.0-only", "Apache-2.0", "MIT", "EUPL-1.2"}
|
||||
|
||||
|
||||
def main() -> int:
|
||||
proc = subprocess.run(
|
||||
["reuse", "lint", "--json"], capture_output=True, text=True, check=False
|
||||
)
|
||||
try:
|
||||
report = json.loads(proc.stdout)
|
||||
except json.JSONDecodeError:
|
||||
sys.stderr.write(proc.stdout + proc.stderr)
|
||||
return 1
|
||||
problems = {}
|
||||
for key, value in report["non_compliant"].items():
|
||||
if key == "unused_licenses":
|
||||
value = [name for name in value if name not in UNUSED_ALLOWED]
|
||||
if value:
|
||||
problems[key] = value
|
||||
if problems:
|
||||
sys.stderr.write(
|
||||
"reuse lint found problems:\n" + json.dumps(problems, indent=2) + "\n"
|
||||
)
|
||||
return 1
|
||||
print(
|
||||
"reuse lint: compliant (unused licence texts tolerated: "
|
||||
+ ", ".join(sorted(UNUSED_ALLOWED))
|
||||
+ ")"
|
||||
)
|
||||
return 0
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.exit(main())
|
||||
@@ -105,7 +105,6 @@ IGNORED = (
|
||||
"scripts/ansible-lint.sh",
|
||||
"scripts/ansible-test-sanity.sh",
|
||||
"scripts/dev-setup.sh",
|
||||
"scripts/reuse_lint.py",
|
||||
"scripts/lock-requirements.sh",
|
||||
"scripts/select_molecule_scenarios.py",
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user