File tree 1 file changed +9
-2
lines changed
1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change 660
660
661
661
import os
662
662
import sys
663
+ import logging
664
+
665
+ logging .basicConfig (level = logging .INFO , format = "[%(asctime)s]: %(message)s:" )
666
+
663
667
try :
664
668
argv = sys .argv [1 :]
665
669
project_config = ["" , "" , "" ]
679
683
f .write (config_files [filepath ]["data" ].format (project_name = project_name , short_description = shortdescription ))
680
684
elif filepath == "CONTRIBUTING.md" :
681
685
f .write (config_files [filepath ]["data" ].format (project_name = project_name , repo_name = repo_name ))
682
- f .write (config_files [filepath ]["data" ])
686
+ else :
687
+ f .write (config_files [filepath ]["data" ])
688
+ logging .info (f"wrote the file { filepath } " )
683
689
else :
684
- print (f"{ filepath } is already exists" )
690
+ logging . info (f"{ filepath } is already exists" )
685
691
except Exception as e :
692
+ logging .info (f"error - { e } " )
686
693
raise e
You can’t perform that action at this time.
0 commit comments