3232
3333from deltacode import DeltaCode
3434from deltacode import __version__
35- from deltacode .utils import deltas , get_notice , collect_errors , get_notice_for_cli
35+ from deltacode .utils import deltas , get_notice , collect_errors
3636
3737
3838def write_json (deltacode , outfile , all_delta_types = False ):
@@ -57,8 +57,7 @@ def write_json(deltacode, outfile, all_delta_types=False):
5757 simplejson .dump (results , outfile , iterable_as_array = True , indent = 2 )
5858 outfile .write ('\n ' )
5959 if outfile .name != '<stdout>' :
60- "This condition arises when we are required to print in the json file and the value of -j in not the console terminal"
61- click .secho (get_notice_for_cli (),fg = "green" )
60+ "This condition arises when we are required to print in the json file and the value of -j in not the console terminal"
6261 click .echo ('deltas_count: {}' .format (len ([d for d in deltas (deltacode , all_delta_types )])))
6362 click .echo ('delta_stats: ' )
6463 for stat in deltacode .stats .to_dict ():
@@ -68,13 +67,9 @@ def write_json(deltacode, outfile, all_delta_types=False):
6867 delta_count = 1
6968 for delta in deltacode .deltas :
7069 if delta .status != "unmodified" :
71- click .echo ("\n " )
72- click .secho ("delta {}" .format (delta_count ))
70+ click .echo ("delta {}" .format (delta_count ))
7371 click .echo (delta )
7472 delta_count += 1
75- click .secho ("#" * 211 + "\n " ,fg = "yellow" )
76- click .secho (" " * 70 + "All deltas are generated, view the json file for details" + "\n " , fg = "green" )
77- click .secho ("#" * 211 ,fg = "yellow" )
7873
7974 except Exception as e :
8075 "This exception arises when outfile has no name attribute"
0 commit comments