Added a -v|verbose option to save iar.
parent
9d9a170571
commit
35a2961ccd
|
@ -139,6 +139,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
|
|
||||||
protected void SaveInvItem(InventoryItemBase inventoryItem, string path, Dictionary<string, object> options, IUserAccountService userAccountService)
|
protected void SaveInvItem(InventoryItemBase inventoryItem, string path, Dictionary<string, object> options, IUserAccountService userAccountService)
|
||||||
{
|
{
|
||||||
|
if (options.ContainsKey("verbose"))
|
||||||
|
m_log.InfoFormat("[INVENTORY ARCHIVER]: Saving item {0} with asset {1}", inventoryItem.ID, inventoryItem.AssetID);
|
||||||
|
|
||||||
string filename = path + CreateArchiveItemName(inventoryItem);
|
string filename = path + CreateArchiveItemName(inventoryItem);
|
||||||
|
|
||||||
// Record the creator of this item for user record purposes (which might go away soon)
|
// Record the creator of this item for user record purposes (which might go away soon)
|
||||||
|
@ -162,6 +165,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
InventoryFolderBase inventoryFolder, string path, bool saveThisFolderItself,
|
InventoryFolderBase inventoryFolder, string path, bool saveThisFolderItself,
|
||||||
Dictionary<string, object> options, IUserAccountService userAccountService)
|
Dictionary<string, object> options, IUserAccountService userAccountService)
|
||||||
{
|
{
|
||||||
|
if (options.ContainsKey("verbose"))
|
||||||
|
m_log.InfoFormat("[INVENTORY ARCHIVER]: Saving folder {0}", inventoryFolder.Name);
|
||||||
|
|
||||||
if (saveThisFolderItself)
|
if (saveThisFolderItself)
|
||||||
{
|
{
|
||||||
path += CreateArchiveFolderName(inventoryFolder);
|
path += CreateArchiveFolderName(inventoryFolder);
|
||||||
|
|
|
@ -122,12 +122,13 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
|
|
||||||
scene.AddCommand(
|
scene.AddCommand(
|
||||||
this, "save iar",
|
this, "save iar",
|
||||||
"save iar [--p|-profile=<url>] <first> <last> <inventory path> <password> [<IAR path>]",
|
"save iar [--p|-profile=<url>] <first> <last> <inventory path> <password> [<IAR path>] [--v|-verbose]",
|
||||||
"Save user inventory archive (IAR).",
|
"Save user inventory archive (IAR).",
|
||||||
"<first> is the user's first name." + Environment.NewLine
|
"<first> is the user's first name." + Environment.NewLine
|
||||||
+ "<last> is the user's last name." + Environment.NewLine
|
+ "<last> is the user's last name." + Environment.NewLine
|
||||||
+ "<inventory path> is the path inside the user's inventory for the folder/item to be saved." + Environment.NewLine
|
+ "<inventory path> is the path inside the user's inventory for the folder/item to be saved." + Environment.NewLine
|
||||||
+ "-p|--profile=<url> adds the url of the profile service to the saved user information." + Environment.NewLine
|
+ "-p|--profile=<url> adds the url of the profile service to the saved user information." + Environment.NewLine
|
||||||
|
+ "-v|--verbose extra debug messages." + Environment.NewLine
|
||||||
+ "<IAR path> is the filesystem path at which to save the IAR."
|
+ "<IAR path> is the filesystem path at which to save the IAR."
|
||||||
+ string.Format(" If this is not given then the filename {0} in the current directory is used", DEFAULT_INV_BACKUP_FILENAME),
|
+ string.Format(" If this is not given then the filename {0} in the current directory is used", DEFAULT_INV_BACKUP_FILENAME),
|
||||||
HandleSaveInvConsoleCommand);
|
HandleSaveInvConsoleCommand);
|
||||||
|
@ -394,6 +395,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
OptionSet ops = new OptionSet();
|
OptionSet ops = new OptionSet();
|
||||||
//ops.Add("v|version=", delegate(string v) { options["version"] = v; });
|
//ops.Add("v|version=", delegate(string v) { options["version"] = v; });
|
||||||
ops.Add("p|profile=", delegate(string v) { options["profile"] = v; });
|
ops.Add("p|profile=", delegate(string v) { options["profile"] = v; });
|
||||||
|
ops.Add("v|verbose", delegate(string v) { options["verbose"] = v; });
|
||||||
|
|
||||||
List<string> mainParams = ops.Parse(cmdparams);
|
List<string> mainParams = ops.Parse(cmdparams);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue