* For no good reason (since there are a hundred million other things to fix), change formatting of version information printed to the log
* Push printing down into OpenSimMain so both console and consoleless configurations will get it0.6.0-stable
parent
e49bdd2628
commit
d8aaf2ccf1
|
@ -53,6 +53,11 @@ namespace OpenSim
|
||||||
{
|
{
|
||||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Holds a human readable build version for this server.
|
||||||
|
/// </summary>
|
||||||
|
protected string buildVersion;
|
||||||
|
|
||||||
protected string proxyUrl;
|
protected string proxyUrl;
|
||||||
protected int proxyOffset = 0;
|
protected int proxyOffset = 0;
|
||||||
|
|
||||||
|
@ -337,12 +342,56 @@ namespace OpenSim
|
||||||
{
|
{
|
||||||
WorldHasComeToAnEnd.Set();
|
WorldHasComeToAnEnd.Set();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Print the version information available to the library. This include a subversion number if the root
|
||||||
|
/// .svn/entries file is present.
|
||||||
|
/// </summary>
|
||||||
|
protected void printAvailableVersionInformation()
|
||||||
|
{
|
||||||
|
// Set BuildVersion String for Show version command
|
||||||
|
string svnFileName = "../.svn/entries";
|
||||||
|
string inputLine = null;
|
||||||
|
int strcmp;
|
||||||
|
|
||||||
|
if (File.Exists(svnFileName))
|
||||||
|
{
|
||||||
|
StreamReader EntriesFile = File.OpenText(svnFileName);
|
||||||
|
inputLine = EntriesFile.ReadLine();
|
||||||
|
while (inputLine != null)
|
||||||
|
{
|
||||||
|
// using the dir svn revision at the top of entries file
|
||||||
|
strcmp = String.Compare(inputLine, "dir");
|
||||||
|
if (strcmp == 0)
|
||||||
|
{
|
||||||
|
buildVersion = EntriesFile.ReadLine();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
inputLine = EntriesFile.ReadLine();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
EntriesFile.Close();
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((buildVersion != null) && (buildVersion.Length > 0))
|
||||||
|
{
|
||||||
|
m_log.Info("[STARTUP]: OpenSim version: " + VersionInfo.Version + ", SVN build r" + buildVersion + "\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
m_log.Info("[STARTUP]: OpenSim version: " + VersionInfo.Version + "\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Performs initialisation of the scene, such as loading configuration from disk.
|
/// Performs initialisation of the scene, such as loading configuration from disk.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected void InternalStartUp()
|
protected void InternalStartUp()
|
||||||
{
|
{
|
||||||
|
printAvailableVersionInformation();
|
||||||
|
|
||||||
StatsManager.StartCollectingSimExtraStats();
|
StatsManager.StartCollectingSimExtraStats();
|
||||||
|
|
||||||
// Do baseclass startup sequence: OpenSim.Region.ClientStack.RegionApplicationBase.StartUp
|
// Do baseclass startup sequence: OpenSim.Region.ClientStack.RegionApplicationBase.StartUp
|
||||||
|
|
|
@ -55,7 +55,6 @@ namespace OpenSim
|
||||||
|
|
||||||
private string m_timedScript = "disabled";
|
private string m_timedScript = "disabled";
|
||||||
private Timer m_scriptTimer;
|
private Timer m_scriptTimer;
|
||||||
private string buildVersion = null;
|
|
||||||
|
|
||||||
public OpenSimMainConsole(IConfigSource configSource)
|
public OpenSimMainConsole(IConfigSource configSource)
|
||||||
: base(configSource)
|
: base(configSource)
|
||||||
|
@ -112,42 +111,8 @@ namespace OpenSim
|
||||||
m_scriptTimer.Interval = 1200 * 1000;
|
m_scriptTimer.Interval = 1200 * 1000;
|
||||||
m_scriptTimer.Elapsed += RunAutoTimerScript;
|
m_scriptTimer.Elapsed += RunAutoTimerScript;
|
||||||
}
|
}
|
||||||
|
|
||||||
PrintFileToConsole("startuplogo.txt");
|
PrintFileToConsole("startuplogo.txt");
|
||||||
|
|
||||||
// Set BuildVersion String for Show version command
|
|
||||||
string svnFileName = "../.svn/entries";
|
|
||||||
string inputLine = null;
|
|
||||||
int strcmp;
|
|
||||||
|
|
||||||
if (File.Exists(svnFileName))
|
|
||||||
{
|
|
||||||
StreamReader EntriesFile = File.OpenText(svnFileName);
|
|
||||||
inputLine = EntriesFile.ReadLine();
|
|
||||||
while (inputLine != null)
|
|
||||||
{
|
|
||||||
// using the dir svn revision at the top of entries file
|
|
||||||
strcmp = String.Compare(inputLine, "dir");
|
|
||||||
if (strcmp == 0)
|
|
||||||
{
|
|
||||||
buildVersion = EntriesFile.ReadLine();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
inputLine = EntriesFile.ReadLine();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
EntriesFile.Close();
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((buildVersion != null) && (buildVersion.Length > 0))
|
|
||||||
{
|
|
||||||
m_log.Info("OpenSim " + VersionInfo.Version + " r" + buildVersion + "\n");
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
m_log.Info("OpenSim " + VersionInfo.Version + "\n");
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected ConsoleBase CreateConsole()
|
protected ConsoleBase CreateConsole()
|
||||||
|
|
|
@ -31,6 +31,6 @@ namespace OpenSim
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class VersionInfo
|
public class VersionInfo
|
||||||
{
|
{
|
||||||
public static string Version = "0.5, SVN build ";
|
public static string Version = "trunk (0.5.6 and additional code)";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue