diff --git a/src/fosslight_source/cli.py b/src/fosslight_source/cli.py index a30dcdef..cf821e24 100755 --- a/src/fosslight_source/cli.py +++ b/src/fosslight_source/cli.py @@ -170,7 +170,7 @@ def create_report_file(_start_time, scanned_result, license_list, selected_scann output_file = f"fosslight_report_src_{_start_time}" if scanned_result: - scanned_result = sorted(scanned_result, key=lambda row: (''.join(row.licenses))) + scanned_result = sorted(scanned_result, key=lambda row: (row.exclude, row.file)) if selected_scanner == 'scancode' or output_extension == _json_ext: sheet_list[SCANOSS_SHEET_NAME] = [scan_item.get_row_to_print() for scan_item in scanned_result] diff --git a/tests/test_files/test/temp.cpp b/tests/test_files/test/temp.cpp new file mode 100644 index 00000000..80190433 --- /dev/null +++ b/tests/test_files/test/temp.cpp @@ -0,0 +1,12 @@ +/* + * SPDX-FileCopyrightText: Copyright 2022 LG Electronics Inc. + * SPDX-License-Identifier: Apache-2.0 + * DownloadLocation: https://github.com/browserify/acorn-node + */ +#include + +int main() +{ + std::cout << "Hello, world!" << std::endl; + return 0; +}