#NEWLINE# def update_head_file( config ) : #NEWLINE# #INDENT# script = alembic_script . ScriptDirectory . from_config ( config ) #NEWLINE# if ( len ( script . get_heads ( ) ) > 1 ) : #NEWLINE# #INDENT# alembic_util . err ( 'Timeline branches unable to generate timeline' ) #NEWLINE# #UNINDENT# head_path = os . path . join ( script . versions , HEAD_FILENAME ) #NEWLINE# with open ( head_path , 'w+' ) as f : #NEWLINE# #INDENT# f . write ( script . get_current_head ( ) )