mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 17:05:55 +08:00
Allow Tools.Configger to take -inifile as argument
This commit is contained in:
@@ -64,14 +64,14 @@ namespace OpenSim.Tools.Configger
|
||||
/// <param name="configSettings"></param>
|
||||
/// <param name="networkInfo"></param>
|
||||
/// <returns>A configuration that gets passed to modules</returns>
|
||||
public IConfigSource LoadConfigSettings()
|
||||
public IConfigSource LoadConfigSettings(IConfig startupConfig)
|
||||
{
|
||||
bool iniFileExists = false;
|
||||
|
||||
List<string> sources = new List<string>();
|
||||
|
||||
string iniFileName = "OpenSim.ini";
|
||||
string iniFilePath = Path.Combine(".", iniFileName);
|
||||
string iniFileName = startupConfig.GetString("inifile", Path.Combine(".", "OpenSim.ini"));
|
||||
Console.WriteLine("---> " + iniFileName + " <---");
|
||||
|
||||
if (IsUri(iniFileName))
|
||||
{
|
||||
@@ -80,10 +80,10 @@ namespace OpenSim.Tools.Configger
|
||||
}
|
||||
else
|
||||
{
|
||||
if (File.Exists(iniFilePath))
|
||||
if (File.Exists(iniFileName))
|
||||
{
|
||||
if (!sources.Contains(iniFilePath))
|
||||
sources.Add(iniFilePath);
|
||||
if (!sources.Contains(iniFileName))
|
||||
sources.Add(iniFileName);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user