fosslight-util 1.4.47__py3-none-any.whl → 1.4.48__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- fosslight_util/cover.py +19 -6
- fosslight_util/output_format.py +1 -1
- {fosslight_util-1.4.47.dist-info → fosslight_util-1.4.48.dist-info}/METADATA +1 -1
- {fosslight_util-1.4.47.dist-info → fosslight_util-1.4.48.dist-info}/RECORD +8 -8
- {fosslight_util-1.4.47.dist-info → fosslight_util-1.4.48.dist-info}/LICENSE +0 -0
- {fosslight_util-1.4.47.dist-info → fosslight_util-1.4.48.dist-info}/WHEEL +0 -0
- {fosslight_util-1.4.47.dist-info → fosslight_util-1.4.48.dist-info}/entry_points.txt +0 -0
- {fosslight_util-1.4.47.dist-info → fosslight_util-1.4.48.dist-info}/top_level.txt +0 -0
fosslight_util/cover.py
CHANGED
|
@@ -9,16 +9,31 @@ from fosslight_util.help import print_package_version
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
class CoverItem:
|
|
12
|
-
tool_name_key = "Tool
|
|
13
|
-
tool_version_key = "Tool version"
|
|
12
|
+
tool_name_key = "Tool information"
|
|
14
13
|
start_time_key = "Start time"
|
|
15
14
|
python_ver_key = "Python version"
|
|
16
15
|
analyzed_path_key = "Analyzed path"
|
|
17
16
|
excluded_path_key = "Excluded path"
|
|
18
17
|
comment_key = "Comment"
|
|
19
18
|
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
PKG_NAMES = [
|
|
20
|
+
"fosslight_scanner",
|
|
21
|
+
"fosslight_source",
|
|
22
|
+
"fosslight_dependency",
|
|
23
|
+
"fosslight_binary"
|
|
24
|
+
]
|
|
25
|
+
|
|
26
|
+
def __init__(self, tool_name="", start_time="", input_path="", comment="", exclude_path=[], simple_mode=True):
|
|
27
|
+
if simple_mode:
|
|
28
|
+
self.tool_name = f'{tool_name} v{print_package_version(tool_name, "", False)}'
|
|
29
|
+
else:
|
|
30
|
+
first_pkg = f'{self.PKG_NAMES[0]} v{print_package_version(self.PKG_NAMES[0], "", False)}'
|
|
31
|
+
remaining_pkgs = ", ".join([
|
|
32
|
+
f'{pkg_name} v{print_package_version(pkg_name, "", False)}'
|
|
33
|
+
for pkg_name in self.PKG_NAMES[1:]
|
|
34
|
+
])
|
|
35
|
+
self.tool_name = f'{first_pkg} ({remaining_pkgs})'
|
|
36
|
+
|
|
22
37
|
if start_time:
|
|
23
38
|
date, time = start_time.split('_')
|
|
24
39
|
self.start_time = f'{date}, {time[0:2]}:{time[2:4]}'
|
|
@@ -28,7 +43,6 @@ class CoverItem:
|
|
|
28
43
|
self.exclude_path = ", ".join(exclude_path)
|
|
29
44
|
self.comment = comment
|
|
30
45
|
|
|
31
|
-
self.tool_version = print_package_version(self.tool_name, "", False)
|
|
32
46
|
self.python_version = f'{sys.version_info.major}.{sys.version_info.minor}'
|
|
33
47
|
|
|
34
48
|
def __del__(self):
|
|
@@ -37,7 +51,6 @@ class CoverItem:
|
|
|
37
51
|
def get_print_json(self):
|
|
38
52
|
json_item = {}
|
|
39
53
|
json_item[self.tool_name_key] = self.tool_name
|
|
40
|
-
json_item[self.tool_version_key] = self.tool_version
|
|
41
54
|
json_item[self.start_time_key] = self.start_time
|
|
42
55
|
json_item[self.python_ver_key] = self.python_version
|
|
43
56
|
json_item[self.analyzed_path_key] = self.input_path
|
fosslight_util/output_format.py
CHANGED
|
@@ -116,7 +116,7 @@ def write_output_file(output_file_without_ext, file_extension, sheet_list, exten
|
|
|
116
116
|
if file_extension == '.xlsx':
|
|
117
117
|
success, msg = write_result_to_excel(result_file, sheet_list, extended_header, hide_header, cover)
|
|
118
118
|
elif file_extension == '.csv':
|
|
119
|
-
success, msg, result_file = write_result_to_csv(result_file, sheet_list)
|
|
119
|
+
success, msg, result_file = write_result_to_csv(result_file, sheet_list, False, extended_header)
|
|
120
120
|
elif file_extension == '.json':
|
|
121
121
|
success, msg = write_opossum(result_file, sheet_list)
|
|
122
122
|
elif file_extension == '.yaml':
|
|
@@ -4,11 +4,11 @@ fosslight_util/compare_yaml.py,sha256=0bapoyS0yrzkiK70K57E8-3wZ_D6mZAJ-24Eq9TYBl
|
|
|
4
4
|
fosslight_util/constant.py,sha256=j9uhncoC2Fn4j4ATNsjUoS91nVXhyGzU6xLyWFj941A,1834
|
|
5
5
|
fosslight_util/convert_excel_to_yaml.py,sha256=7ZsAMMQJIEXrmcl_28nSHvFpGMi1ZiRZYpEfI5O8vP8,2298
|
|
6
6
|
fosslight_util/correct.py,sha256=O8c4vIl5Hdc46Ijr63LfcTjIZE5fgqN2iKRadHqluUU,6253
|
|
7
|
-
fosslight_util/cover.py,sha256=
|
|
7
|
+
fosslight_util/cover.py,sha256=qqqKzxqFwKimal764FaugRUBcHWdeKt8af6xeK0mH8E,2040
|
|
8
8
|
fosslight_util/download.py,sha256=X-R2RTWwmhx_LSIBZhIxzPTJZ2GwasZnhIsZ5m3hUig,14997
|
|
9
9
|
fosslight_util/help.py,sha256=xhAf43fuRLOU3TE7jqaxVTizVn4aANDvHaHYQAdaqYc,2154
|
|
10
10
|
fosslight_util/oss_item.py,sha256=Wc2ka8cZc3D9JiJXl4-Y69A_qcGuyMiyYq053Srq638,7267
|
|
11
|
-
fosslight_util/output_format.py,sha256=
|
|
11
|
+
fosslight_util/output_format.py,sha256=ltHniHwu9y0i-OV-Go1tWiqJBAnWgiVMlLV_cd_Ymlg,4907
|
|
12
12
|
fosslight_util/parsing_yaml.py,sha256=m1kg6sYBJTmLmobsD-fjFxOz2NuIVjUvoEvXxmvBOpU,4561
|
|
13
13
|
fosslight_util/read_excel.py,sha256=3zW2F6Azj4ufsrStBQGArBDCLG-BTJGG54HIqMxlx_A,5392
|
|
14
14
|
fosslight_util/set_log.py,sha256=GsUtbtqmYKgBltHzeaxV3H9gaUWMYQYDJEhr_LdEGoo,3258
|
|
@@ -23,9 +23,9 @@ fosslight_util/write_yaml.py,sha256=nzuIPdjOAOM4NS5VtU-KFrft41fKEF05-cl0OlEHj7Y,
|
|
|
23
23
|
fosslight_util/resources/frequentLicenselist.json,sha256=GUhzK6tu7ok10fekOnmVmUgIGRC-acGABZKTNKfDyYA,4776157
|
|
24
24
|
fosslight_util/resources/frequent_license_nick_list.json,sha256=ryU2C_6ZxHbz90_sUN9OvI9GXkCMLu7oGcmd9W79YYo,5005
|
|
25
25
|
fosslight_util/resources/licenses.json,sha256=mK55z-bhY7Mjpj2KsO1crKGGL-X3F6MBFQJ0zLlx010,240843
|
|
26
|
-
fosslight_util-1.4.
|
|
27
|
-
fosslight_util-1.4.
|
|
28
|
-
fosslight_util-1.4.
|
|
29
|
-
fosslight_util-1.4.
|
|
30
|
-
fosslight_util-1.4.
|
|
31
|
-
fosslight_util-1.4.
|
|
26
|
+
fosslight_util-1.4.48.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
27
|
+
fosslight_util-1.4.48.dist-info/METADATA,sha256=U88pKw2oNZkRupvkU6Gwn2txiPm7yI1sGI1L0GdWrQA,6418
|
|
28
|
+
fosslight_util-1.4.48.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
29
|
+
fosslight_util-1.4.48.dist-info/entry_points.txt,sha256=bzXX5i7HZ13V8BLKvtu_9KO3ZjtRypH-XszOXT6I3bU,69
|
|
30
|
+
fosslight_util-1.4.48.dist-info/top_level.txt,sha256=2qyYWGLakgBRy4BqoBNt-I5C29tBr_e93e5e1pbuTGA,15
|
|
31
|
+
fosslight_util-1.4.48.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|