#NEWLINE# def command_start( args ) : #NEWLINE# #INDENT# procfile_path = _procfile_path ( args . app_root , _choose_procfile ( args ) ) #NEWLINE# procfile = _procfile ( procfile_path ) #NEWLINE# concurrency = _parse_concurrency ( args . concurrency ) #NEWLINE# env = _read_env ( args . app_root , args . env ) #NEWLINE# quiet = _parse_quiet ( args . quiet ) #NEWLINE# port = _choose_port ( args , env ) #NEWLINE# if args . processes : #NEWLINE# #INDENT# processes = compat . OrderedDict ( ) #NEWLINE# for name in args . processes : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# processes [ name ] = procfile . processes [ name ] #NEWLINE# #UNINDENT# except KeyError : #NEWLINE# #INDENT# raise CommandError ( "Process type '{0}' does not exist in Procfile" . format ( name ) ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# processes = procfile . processes #NEWLINE# #UNINDENT# manager = Manager ( ) #NEWLINE# for p in environ . expand_processes ( processes , concurrency = concurrency , env = env , quiet = quiet , port = port ) : #NEWLINE# #INDENT# e = os . environ . copy ( ) #NEWLINE# e . update ( p . env ) #NEWLINE# manager . add_process ( p . name , p . cmd , quiet = p . quiet , env = e ) #NEWLINE# #UNINDENT# manager . loop ( ) #NEWLINE# sys . exit ( manager . returncode )