#NEWLINE# def find_version( * file_paths ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# f = codecs . open ( os . path . join ( here , * file_paths ) , 'r' , 'latin1' ) #NEWLINE# version_file = f . read ( ) #NEWLINE# f . close ( ) #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# raise RuntimeError ( 'Unable to find version string.' ) #NEWLINE# #UNINDENT# version_match = re . search ( '^__version__ = [\'\\"]([^\'\\"]*)[\'\\"]' , version_file , re . M ) #NEWLINE# if version_match : #NEWLINE# #INDENT# return version_match . group ( 1 ) #NEWLINE# #UNINDENT# raise RuntimeError ( 'Unable to find version string.' )