#NEWLINE# def _copy_file( self , filename , destination ) : #NEWLINE# #INDENT# filepath = os . path . join ( THIS_FOLDER , filename ) #NEWLINE# def do_it( ) : #NEWLINE# #INDENT# shutil . copyfile ( filepath , destination ) #NEWLINE# #UNINDENT# if self . creating : #NEWLINE# #INDENT# do_it ( ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( not os . path . exists ( destination ) ) : #NEWLINE# #INDENT# do_it ( ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# old_version_filepath = os . path . join ( self . old_version_path , 'iepy' , 'instantiation' , filename ) #NEWLINE# if ( os . path . exists ( old_version_filepath ) and filecmp . cmp ( old_version_filepath , destination ) ) : #NEWLINE# #INDENT# do_it ( ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if filecmp . cmp ( filepath , self ) : #NEWLINE# #INDENT# return #NEWLINE# #UNINDENT# self . preserve_old_file_version_as_copy ( destination ) #NEWLINE# do_it ( )