Skip to content
Snippets Groups Projects
Commit c5bc59c6 authored by Jonathan Ehret's avatar Jonathan Ehret
Browse files

print which config is used

parent 17434222
Branches
No related tags found
No related merge requests found
......@@ -10,12 +10,16 @@ sCurrentScriptsDirectory = os.path.dirname( os.path.realpath( sys.argv[0] ) )
if os.path.isfile( sHostConfigurationFile ):
exec( compile( open( sHostConfigurationFile, "rb" ).read(), sHostConfigurationFile, 'exec' ) )
print("Using config: " + sHostConfigurationFile)
elif os.path.isfile( sCurrentScriptsDirectory + "/" + sHostConfigurationFile ):
exec( compile( open( sCurrentScriptsDirectory + "/" + sHostConfigurationFile, "rb" ).read(), sCurrentScriptsDirectory + "/" + sHostConfigurationFile, 'exec' ) )
print("Using config: " + sCurrentScriptsDirectory + "/" + sHostConfigurationFile)
elif os.path.isfile( sGeneralConfigurationFile ):
exec( compile( open( sGeneralConfigurationFile, "rb" ).read(), sGeneralConfigurationFile, 'exec' ) )
print("Using config: " + sGeneralConfigurationFile)
elif os.path.isfile( sCurrentScriptsDirectory + "/" + sGeneralConfigurationFile ):
exec( compile( open( sCurrentScriptsDirectory + "/" + sGeneralConfigurationFile, "rb" ).read(), sCurrentScriptsDirectory + "/" + sGeneralConfigurationFile, 'exec' ) )
print("Using config: " + sCurrentScriptsDirectory + "/" + sGeneralConfigurationFile)
else:
print( "ERROR: No configuration file found - please create " + sHostConfigurationFile + " or " + sGeneralConfigurationFile )
sys.exit( 4 )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment