diff options
| author | Shulhan <ms@kilabit.info> | 2026-01-14 03:41:56 +0700 |
|---|---|---|
| committer | Shulhan <ms@kilabit.info> | 2026-01-14 04:10:44 +0700 |
| commit | ca472c1d51f3304c86c8e33876192e022ffc6e52 (patch) | |
| tree | 2fc5d3fd0bf7786cf2674c76364ae28971e9700d | |
| parent | a2bfa5ec9539f9063e33519e245ae00193783750 (diff) | |
| download | spdxconv-ca472c1d51f3304c86c8e33876192e022ffc6e52.tar.xz | |
README: describe how the flow of scan command
| -rw-r--r-- | README.md | 26 |
1 files changed, 26 insertions, 0 deletions
@@ -247,6 +247,32 @@ changes the behaviour of apply command. Deleting a line in the report means excluding the file from being processed by "apply" command. +The scan command work in the following way, + +(1) Check the file for SPDX-License-Identifier and SPDX-FileCopyrightText. +If both exist, skip the file. + +(2) For each match-license in the configuration, + +(2.1) If there is a match, record it as "match" and its line number +into the report. + +(2.2) If no match, use the default license from configuration, record it as +"default" with 0 line number in the report. + +(3) For each match-copyright in the configuration, + +(3.1) If there is a match, get the year, author, and contact; and record it +as "match" and its line number into the report. + +If the year is empty, try to get the year from the first commit of the file +using "git log --follow ..." command. +If no commit history or its not using git, use default copyright year from +configuration. + +(3.2) If there is no match, use default copyright year and text from +configuration, and record as "default" in the report. + ### spdxconv.report file format Each line in the report file is formatted using CSV and has several columns |
