From b9ef701ff1e8219933d7c6db205ee7ca8c5ea124 Mon Sep 17 00:00:00 2001 From: GJ Date: Tue, 5 Feb 2013 19:02:56 -0500 Subject: [PATCH] Changed backup task to include ALL config files --- Changelog.txt | 1 + .../net/shatteredlands/shatt/backup/ZipLibrary.java | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Changelog.txt b/Changelog.txt index 59af3c0c2..2f1c8f373 100644 --- a/Changelog.txt +++ b/Changelog.txt @@ -63,6 +63,7 @@ Version 1.4.00-dev ! Changed Excavation to have individual XP values for each block type, rather than a base XP value. ! Changed the way party teleportation works. When using /ptp, the target player needs to confirm the teleport before it takes place. (Configurable) ! Changed BeastLore: Now also displays offline player names + ! Changed backup task to include ALL config files - Removed Party "master/apprentice" system. Replaced with the new party XP share feature. - Removed unused "healthbar" files from the resources - Removed config options for disabling commands from the config.yml. This should instead be done through permissions. diff --git a/src/main/java/net/shatteredlands/shatt/backup/ZipLibrary.java b/src/main/java/net/shatteredlands/shatt/backup/ZipLibrary.java index c069a8f1e..17f212e55 100644 --- a/src/main/java/net/shatteredlands/shatt/backup/ZipLibrary.java +++ b/src/main/java/net/shatteredlands/shatt/backup/ZipLibrary.java @@ -20,9 +20,11 @@ public class ZipLibrary { private static File BackupDir = new File(BackupDirectory); private static File FlatFileDirectory = new File(mcMMO.getFlatFileDirectory()); private static File ModFileDirectory = new File(mcMMO.getModDirectory()); - private static File UsersFile = new File(mcMMO.getUsersFilePath()); private static File ConfigFile = new File(mcMMO.getMainDirectory() + "config.yml"); private static File TreasuresFile = new File(mcMMO.getMainDirectory() + "treasures.yml"); + private static File AdvancedConfigFile = new File(mcMMO.getMainDirectory() + "advanced.yml"); + private static File SpoutFile = new File(mcMMO.getMainDirectory() + "spout.yml"); + private static File RepairFile = new File(mcMMO.getMainDirectory() + "repair.vanilla.yml"); public static void mcMMObackup() throws IOException { if (Config.getInstance().getUseMySQL()) { @@ -46,14 +48,19 @@ public class ZipLibrary { //Create the Source List, and add directories/etc to the file. List sources = new ArrayList(); sources.add(FlatFileDirectory); - sources.add(UsersFile); sources.add(ConfigFile); sources.add(TreasuresFile); + sources.add(AdvancedConfigFile); + sources.add(RepairFile); if (ModFileDirectory.exists()) { sources.add(ModFileDirectory); } + if (SpoutFile.exists()) { + sources.add(SpoutFile); + } + //Actually do something System.out.println("Backing up your mcMMO Configuration... ");