scancode-toolkit icon indicating copy to clipboard operation
scancode-toolkit copied to clipboard

Introduce Rules with YAML frontmatter #3049

Open AyanSinhaMahapatra opened this issue 3 years ago • 2 comments

  • Delete all .yml files for rules
  • Modify .RULE files to contain their data as YAML frontmatter
  • Merge these files preserving history

Reference: https://github.com/nexB/scancode-toolkit/issues/3049 Signed-off-by: Ayan Sinha Mahapatra [email protected]

AyanSinhaMahapatra avatar Aug 24 '22 14:08 AyanSinhaMahapatra

The merging of the .RULE and .yml files to .RULE files with YAML frontmatter has been done such that the line history is preserved.

This blogpost has been followed for the same.

Though note that this preserves only line history, i.e. entire history isn't tracked as the files are renamed (and git doesn't track history for renamed files see here). But you can still get the file history for these files by using git log --follow file_path

AyanSinhaMahapatra avatar Aug 29 '22 16:08 AyanSinhaMahapatra

@pombredanne btw, should we do the same for .LICENSE files?

AyanSinhaMahapatra avatar Sep 05 '22 10:09 AyanSinhaMahapatra

This is already all in https://github.com/nexB/scancode-toolkit/pull/3100 ... so closing.

pombredanne avatar Oct 28 '22 16:10 pombredanne