Skip to content

Commit 185675b

Browse files
authored
Merge pull request #455 from sschuberth/reuse-sha1
cli: Create an SPDX file with the pre-calculated SHA1
2 parents cafa198 + 28ef927 commit 185675b

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/scancode/cli.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -655,8 +655,7 @@ def save_results(files_count, scanned_files, format, input, output_file):
655655
# Skip directories.
656656
continue
657657

658-
file_entry = File(file_data.get('path'))
659-
file_entry.chk_sum = Algorithm('SHA1', file_sha1)
658+
file_entry = File(file_data.get('path'), Algorithm('SHA1', file_sha1))
660659

661660
file_licenses = file_data.get('licenses')
662661
if file_licenses:

0 commit comments

Comments
 (0)