Skip to content
Snippets Groups Projects

Add a license scanning script

Merged Andrej Shadura requested to merge wip/andrewsh/license-scan into apertis/v2020pre
All threads resolved!

This adds a new license scanning script to integrate with the CI.

The script runs scan-copyright and compares its output with the previous version of itself.

If --fail-on-change is passed, it will stop on any difference and report an error. Otherwise, it will fail when it detects files with UNKNOWN license or one of the licenses on a blacklist.

The script uses of the following files to configure the scanning tool:

  • debian/apertis/copyright.whitelist, a gitignore-formatted files to exclude from the scanning process. Extra files can be specified using --extra-whitelist.
  • debian/apertis/copyright.yml, a YAML file mapping files to copyright statements and licenses. It can be used to give the scanning tool hints or completely override its output. The format is described in the Dpkg::Copyright::Scanner manual page.
  • debian/fill.copyright.blanks.yml: some Debian packages already ship a file with hints for scan-copyright; it is also used in the scanning process. The format is described in the Dpkg::Copyright::Scanner manual page.
  • debian/copyright-scan-patterns.yml: some Debian packages already ship a file telling the tool to ignore some files. The format is described in the Dpkg::Copyright::Scanner manual page. The check field is effectively useless, since the license scanning script adds a rule to enable scanning of all files, not just a select list of patterns.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Peter Senna Tschudin
  • Peter Senna Tschudin
  • Andrej Shadura added 3 commits

    added 3 commits

    • 20d009dc - Add a license scanning script
    • 71875097 - Relicense ci-buildpackage and ci-obs-upload as MPL 2.0
    • a76caa0a - Add a clear license statement to the updates scripts

    Compare with previous version

  • Emanuele Aina resolved all threads

    resolved all threads

  • merged

  • Please register or sign in to reply
    Loading