@@ -545,7 +545,7 @@ def main(override=None):
545
545
remote_file = requests_get_with_retry (headless_ie_url )
546
546
with open (headless_ie_file_path , "wb" ) as file :
547
547
file .write (remote_file .content )
548
- print ("Download Complete!\n " )
548
+ print ("%sDownload Complete!%s \n " % ( c1 , cr ) )
549
549
zip_file_path = headless_ie_file_path
550
550
zip_ref = zipfile .ZipFile (zip_file_path , "r" )
551
551
contents = zip_ref .namelist ()
@@ -589,7 +589,7 @@ def main(override=None):
589
589
zip_ref .close ()
590
590
os .remove (zip_file_path )
591
591
shutil .copyfile (driver_path , os .path .join (downloads_folder , filename ))
592
- print ("Unzip Complete!\n " )
592
+ print ("%sUnzip Complete!%s \n " % ( c2 , cr ) )
593
593
to_remove = [
594
594
"%s/%s/ruby_example/Gemfile" % (downloads_folder , h_ie_fn ),
595
595
"%s/%s/ruby_example/Gemfile.lock" % (downloads_folder , h_ie_fn ),
@@ -614,13 +614,16 @@ def main(override=None):
614
614
)
615
615
print ("Making [%s %s] executable ..." % (driver_file , use_version ))
616
616
make_executable (driver_path )
617
- print ("%s[%s] is now ready for use!%s" % (c1 , driver_file , cr ))
617
+ print (
618
+ "%s[%s %s] is now ready for use!%s"
619
+ % (c1 , driver_file , use_version , cr )
620
+ )
618
621
619
622
print ("\n Downloading %s from:\n %s ..." % (file_name , download_url ))
620
623
remote_file = requests_get_with_retry (download_url )
621
624
with open (file_path , "wb" ) as file :
622
625
file .write (remote_file .content )
623
- print ("Download Complete!\n " )
626
+ print ("%sDownload Complete!%s \n " % ( c1 , cr ) )
624
627
625
628
if file_name .endswith (".zip" ):
626
629
zip_file_path = file_path
@@ -639,14 +642,17 @@ def main(override=None):
639
642
zip_ref .extractall (downloads_folder )
640
643
zip_ref .close ()
641
644
os .remove (zip_file_path )
642
- print ("Unzip Complete!\n " )
645
+ print ("%sUnzip Complete!%s \n " % ( c2 , cr ) )
643
646
for f_name in contents :
644
647
new_file = os .path .join (downloads_folder , str (f_name ))
645
648
pr_file = c3 + new_file + cr
646
649
print ("The file [%s] was saved to:\n %s\n " % (f_name , pr_file ))
647
650
print ("Making [%s %s] executable ..." % (f_name , use_version ))
648
651
make_executable (new_file )
649
- print ("%s[%s] is now ready for use!%s" % (c1 , f_name , cr ))
652
+ print (
653
+ "%s[%s %s] is now ready for use!%s" %
654
+ (c1 , f_name , use_version , cr )
655
+ )
650
656
if copy_to_path and os .path .exists (LOCAL_PATH ):
651
657
path_file = LOCAL_PATH + f_name
652
658
shutil .copyfile (new_file , path_file )
@@ -709,7 +715,7 @@ def main(override=None):
709
715
zip_ref .extractall (downloads_folder )
710
716
zip_ref .close ()
711
717
os .remove (zip_file_path )
712
- print ("Unzip Complete!\n " )
718
+ print ("%sUnzip Complete!%s \n " % ( c2 , cr ) )
713
719
to_remove = [
714
720
"%s/Driver_Notes/credits.html" % downloads_folder ,
715
721
"%s/Driver_Notes/EULA" % downloads_folder ,
@@ -721,13 +727,17 @@ def main(override=None):
721
727
if os .path .exists (os .path .join (downloads_folder , "Driver_Notes/" )):
722
728
# Only works if the directory is empty
723
729
os .rmdir (os .path .join (downloads_folder , "Driver_Notes/" ))
730
+ pr_driver_path = c3 + driver_path + cr
724
731
print (
725
732
"The file [%s] was saved to:\n %s\n "
726
- % (driver_file , driver_path )
733
+ % (driver_file , pr_driver_path )
727
734
)
728
735
print ("Making [%s %s] executable ..." % (driver_file , use_version ))
729
736
make_executable (driver_path )
730
- print ("%s[%s] is now ready for use!%s" % (c1 , driver_file , cr ))
737
+ print (
738
+ "%s[%s %s] is now ready for use!%s"
739
+ % (c1 , driver_file , use_version , cr )
740
+ )
731
741
if copy_to_path and os .path .exists (LOCAL_PATH ):
732
742
path_file = LOCAL_PATH + f_name
733
743
shutil .copyfile (new_file , path_file )
@@ -755,7 +765,7 @@ def main(override=None):
755
765
zip_ref .extractall (downloads_folder )
756
766
zip_ref .close ()
757
767
os .remove (zip_file_path )
758
- print ("Unzip Complete!\n " )
768
+ print ("%sUnzip Complete!%s \n " % ( c2 , cr ) )
759
769
inner_driver = os .path .join (
760
770
downloads_folder , inner_folder , driver_file
761
771
)
@@ -770,7 +780,10 @@ def main(override=None):
770
780
)
771
781
print ("Making [%s %s] executable ..." % (driver_file , use_version ))
772
782
make_executable (driver_path )
773
- print ("%s[%s] is now ready for use!%s" % (c1 , driver_file , cr ))
783
+ print (
784
+ "%s[%s %s] is now ready for use!%s"
785
+ % (c1 , driver_file , use_version , cr )
786
+ )
774
787
if copy_to_path and os .path .exists (LOCAL_PATH ):
775
788
path_file = LOCAL_PATH + driver_file
776
789
shutil .copyfile (driver_path , path_file )
@@ -804,14 +817,17 @@ def main(override=None):
804
817
tar .extractall (downloads_folder )
805
818
tar .close ()
806
819
os .remove (tar_file_path )
807
- print ("Unzip Complete!\n " )
820
+ print ("%sUnzip Complete!%s \n " % ( c2 , cr ) )
808
821
for f_name in contents :
809
822
new_file = os .path .join (downloads_folder , str (f_name ))
810
823
pr_file = c3 + new_file + cr
811
824
print ("The file [%s] was saved to:\n %s\n " % (f_name , pr_file ))
812
825
print ("Making [%s %s] executable ..." % (f_name , use_version ))
813
826
make_executable (new_file )
814
- print ("%s[%s] is now ready for use!%s" % (c1 , f_name , cr ))
827
+ print (
828
+ "%s[%s %s] is now ready for use!%s"
829
+ % (c1 , f_name , use_version , cr )
830
+ )
815
831
if copy_to_path and os .path .exists (LOCAL_PATH ):
816
832
path_file = LOCAL_PATH + f_name
817
833
shutil .copyfile (new_file , path_file )
0 commit comments