#NEWLINE# def put_text_file_contents( self , path , contents , versioned = True ) : #NEWLINE# #INDENT# versioned_path = ( self . get_versionized_path ( path , contents ) if versioned else path ) #NEWLINE# abs_versioned_path = self . get_abspath ( versioned_path ) #NEWLINE# self . create_dirs_for_file ( abs_versioned_path ) #NEWLINE# open ( abs_versioned_path , 'wb' ) . write ( contents . encode ( self . config . get ( 'global.encoding' , 'utf-8' ) ) ) #NEWLINE# if versioned : #NEWLINE# #INDENT# self . busted_paths . append ( ( path , versioned_path ) )