From cb14e1d2720fdee0c77280d7c397c02116c278ca Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 21 Jan 2011 23:59:55 +0000 Subject: Update the "config get
" command to "config get [
] []" The config get command shows a current config value on the console. Now, if is omitted then all the values for the given section are printed. If
is ommitted then all sections and all keys are printed. Current config can also be dumped to a file using "config save ". This can be handy for resolving or eliminating config issues --- OpenSim/Framework/Console/ConsoleBase.cs | 5 +++++ OpenSim/Framework/Servers/BaseOpenSimServer.cs | 14 ++++++++++++++ 2 files changed, 19 insertions(+) (limited to 'OpenSim/Framework') diff --git a/OpenSim/Framework/Console/ConsoleBase.cs b/OpenSim/Framework/Console/ConsoleBase.cs index 22ce880..3ef76cf 100755 --- a/OpenSim/Framework/Console/ConsoleBase.cs +++ b/OpenSim/Framework/Console/ConsoleBase.cs @@ -75,6 +75,11 @@ namespace OpenSim.Framework.Console { System.Console.WriteLine(text); } + + public virtual void OutputFormat(string format, params string[] components) + { + Output(string.Format(format, components)); + } public string CmdPrompt(string p) { diff --git a/OpenSim/Framework/Servers/BaseOpenSimServer.cs b/OpenSim/Framework/Servers/BaseOpenSimServer.cs index 147fbd5..b28ad69 100644 --- a/OpenSim/Framework/Servers/BaseOpenSimServer.cs +++ b/OpenSim/Framework/Servers/BaseOpenSimServer.cs @@ -411,6 +411,7 @@ namespace OpenSim.Framework.Servers /// That is something that cannot be determined within this class. So /// all attempts to use the console MUST be verified. /// + /// protected void Notice(string msg) { if (m_console != null) @@ -418,6 +419,19 @@ namespace OpenSim.Framework.Servers m_console.Output(msg); } } + + /// + /// Console output is only possible if a console has been established. + /// That is something that cannot be determined within this class. So + /// all attempts to use the console MUST be verified. + /// + /// + /// + protected void Notice(string format, params string[] components) + { + if (m_console != null) + m_console.OutputFormat(format, components); + } /// /// Enhance the version string with extra information if it's available. -- cgit v1.1