#NEWLINE# def start( configfile ) : #NEWLINE# #INDENT# print ( 'Starting ...' ) #NEWLINE# args = SYNAPSE #NEWLINE# args . extend ( [ '--daemonize' , '-c' , configfile ] ) #NEWLINE# try : #NEWLINE# #INDENT# subprocess . check_call ( args ) #NEWLINE# print ( ( ( GREEN + 'started' ) + NORMAL ) ) #NEWLINE# #UNINDENT# except subprocess . CalledProcessError as e : #NEWLINE# #INDENT# print ( ( ( RED + ( 'error starting (exit code: %d); see above for logs' % e . returncode ) ) + NORMAL ) )