<s> """<STR_LIT>""" <EOL> import sys <EOL> import time <EOL> from subprocess import call as subcall <EOL> DEBUG = False <EOL> app = '<STR_LIT>' <EOL> version = __import__ ( app ) . __version__ <EOL> tag_dir = '<STR_LIT>' % app <EOL> def call ( cmd ) : <EOL> if DEBUG : <EOL> print '<STR_LIT>' % cmd <EOL> else : <EOL> try : <EOL> response = subcall ( cmd , shell = True ) <EOL> print <EOL> time . sleep ( <NUM_LIT:1> ) <EOL> if response < <NUM_LIT:0> : <EOL> sys . exit ( response ) <EOL> except OSError , E : <EOL> sys . exit ( E ) <EOL> def cleanup ( ) : <EOL> call ( '<STR_LIT>' ) <EOL> def tag ( ) : <EOL> call ( '<STR_LIT>' % ( app , app , version , app , version ) ) <EOL> def package ( ) : <EOL> call ( '<STR_LIT>' ) <EOL> call ( '<STR_LIT>' % ( app , version , tag_dir ) ) <EOL> call ( '<STR_LIT>' % ( tag_dir , app , version ) ) <EOL> def commit ( ) : <EOL> call ( '<STR_LIT>' % ( tag_dir , app , version ) ) <EOL> def main ( ) : <EOL> cleanup ( ) <EOL> tag ( ) <EOL> package ( ) <EOL> cleanup ( ) <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> main ( ) </s>
