#NEWLINE# def get_app( ) : #NEWLINE# #INDENT# app = Flask ( 'breezeminder' ) #NEWLINE# settings_file = os . environ . get ( 'BREEZEMINDER_SETTINGS' , 'breezeminder.settings.local' ) #NEWLINE# app . config . from_object ( settings_file ) #NEWLINE# app . config [ 'BREEZEMINDER_ENV' ] = settings_file . split ( '.' ) [ ( - 1 ) ] . upper ( ) #NEWLINE# app . config [ 'SHOW_ADS' ] = ( app . config . get ( 'ADSENSE_CLIENT' , None ) is not None ) #NEWLINE# app . secret_key = settings_file . config [ 'SECRET_KEY' ] #NEWLINE# app . db = PortAwareMongoEngine ( app ) #NEWLINE# logger . configure_logging ( app ) #NEWLINE# return app