@@ -31,7 +31,7 @@ def update_readme(summary):
31
31
curl = "Yes" if "curl" in installers else "No"
32
32
url = "https://installer.to/" + tool_shortname
33
33
value_matrix .append ([name , apt , yum , pacman , apk , dnf , curl , url ])
34
- print ( value_matrix )
34
+
35
35
writer .value_matrix = value_matrix
36
36
table_md = writer .dumps ()
37
37
try :
@@ -46,32 +46,28 @@ def update_readme(summary):
46
46
readme_md .write (readme )
47
47
readme_md .close ()
48
48
except Error as e :
49
- print ( e )
49
+ logging . error ( 'Error occurred when trying to update README.md, error: ' + e )
50
50
51
51
52
52
def update_summary (name , shortname , description , installers ):
53
53
try :
54
54
with open ("./installers.toml" , "r+" ) as installer_summary :
55
55
summaary = installer_summary .read ()
56
- print (summaary )
57
56
parsed_summary_toml = toml .loads (summaary )
58
- print (parsed_summary_toml )
59
57
if shortname not in parsed_summary_toml :
60
58
parsed_summary_toml [shortname ] = {}
61
59
parsed_summary_toml [shortname ]['name' ] = name
62
60
parsed_summary_toml [shortname ]['name' ] = name
63
61
parsed_summary_toml [shortname ]['description' ] = description
64
62
parsed_summary_toml [shortname ]['installers' ] = "," .join (installers )
65
- print (parsed_summary_toml )
66
63
installer_summary .seek (0 ) # sets point at the beginning of the file
67
64
installer_summary .truncate () # Clear previous content
68
65
installer_summary .write (toml .dumps (parsed_summary_toml ))
69
66
installer_summary .close ()
70
67
71
68
update_readme (parsed_summary_toml )
72
69
except IOError as e :
73
- print ("Error" , e )
74
- pass
70
+ logging .error ('Error occurred when trying to update installers.toml, error: ' + e )
75
71
76
72
def get_method_case (method ):
77
73
if method in methods :
@@ -167,7 +163,6 @@ def generate(path):
167
163
168
164
installer_sh .close ()
169
165
update_summary (parsed_toml ['name' ], parsed_toml ['shortname' ], parsed_toml ['description' ], installer_methods )
170
- print ("installer_methods" ,installer_methods )
171
166
172
167
except IOError as x :
173
168
if x .errno == errno .EACCES :
0 commit comments