From c18422ad3a09cfabd86eb86403a77a6c720980f0 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Wed, 25 Nov 2009 16:02:47 +0000 Subject: Implement oar merging An oar can now be merged with existing region contents by using the --merge option For example, load oar --merge my.oar Existing terrain, region settings and parcel data is left in place when an oar is merged. See http://opensimulator.org/wiki/OpenSim_Archives#Usage for more information --- .../Region/CoreModules/World/Archiver/ArchiverModule.cs | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs b/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs index 98fdec3..27763bb 100644 --- a/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs +++ b/OpenSim/Region/CoreModules/World/Archiver/ArchiverModule.cs @@ -93,19 +93,23 @@ namespace OpenSim.Region.CoreModules.World.Archiver /// public void HandleLoadOarConsoleCommand(string module, string[] cmdparams) { - OptionSet options = new OptionSet() {}; + bool mergeOar = false; + + OptionSet options = new OptionSet().Add("m|merge", delegate (string v) { mergeOar = v != null; }); List mainParams = options.Parse(cmdparams); - - foreach (string param in mainParams) - m_log.DebugFormat("Found param [{0}]", param); + +// m_log.DebugFormat("MERGE OAR IS [{0}]", mergeOar); +// +// foreach (string param in mainParams) +// m_log.DebugFormat("GOT PARAM [{0}]", param); if (mainParams.Count > 2) { - DearchiveRegion(cmdparams[2]); + DearchiveRegion(mainParams[2], mergeOar, Guid.Empty); } else { - DearchiveRegion(DEFAULT_OAR_BACKUP_FILENAME); + DearchiveRegion(DEFAULT_OAR_BACKUP_FILENAME, mergeOar, Guid.Empty); } } -- cgit v1.1