mirror of
https://github.com/tribufu/ServerManagers
synced 2026-05-06 15:17:34 +00:00
World Save Backup Changes
- fixed the timestamps associated with the file, so they are the same as the timestamps in the directory. - changed the ZipUtils ZipFile method to accept a directory, not an entry name.
This commit is contained in:
parent
0f845d535c
commit
2c84798a02
7 changed files with 66 additions and 68 deletions
|
|
@ -1962,7 +1962,7 @@ namespace ServerManagerTool.Lib
|
|||
var saveFolderInfo = new DirectoryInfo(saveFolder);
|
||||
|
||||
// backup the world save file
|
||||
ZipUtils.ZipFile(backupFile, worldFileName, worldFile, comment.ToString());
|
||||
ZipUtils.ZipFile(backupFile, "", worldFile, comment.ToString());
|
||||
|
||||
if (Config.Default.AutoBackup_IncludeSaveGamesFolder)
|
||||
{
|
||||
|
|
@ -1976,7 +1976,7 @@ namespace ServerManagerTool.Lib
|
|||
var saveGamesFiles = saveGamesFolderInfo.GetFiles(saveGamesFileFilter, SearchOption.AllDirectories);
|
||||
foreach (var file in saveGamesFiles)
|
||||
{
|
||||
ZipUtils.ZipFile(backupFile, file.FullName.Replace(saveGamesFolder, Config.Default.SaveGamesRelativePath), file.FullName);
|
||||
ZipUtils.ZipFile(backupFile, file.DirectoryName.Replace(saveGamesFolder, Config.Default.SaveGamesRelativePath), file.FullName);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue