From 71049c3e2ba49dcfed00660ae4faf8422bb759d3 Mon Sep 17 00:00:00 2001 From: zhaominyong Date: Thu, 28 Jul 2022 18:49:35 +0800 Subject: [PATCH] =?UTF-8?q?=E8=87=AA=E5=8A=A8=E5=A4=87=E4=BB=BD=E7=82=B9?= =?UTF-8?q?=E8=BF=98=E5=8E=9F=E5=90=8E=E6=9C=89=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backup-daemon/data/backup-auto-efi | 2 +- backup-daemon/mybackupmanager.cpp | 4 ++++ backup-daemon/parsebackuplist.cpp | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/backup-daemon/data/backup-auto-efi b/backup-daemon/data/backup-auto-efi index b4caa18..094e67a 100755 --- a/backup-daemon/data/backup-auto-efi +++ b/backup-daemon/data/backup-auto-efi @@ -1038,7 +1038,7 @@ restoreAuto() { #还原 exit 7 #备份文件不存在,不能还原系统 fi - if [ "$uuid" = "$auto_uuid" ]; then + if [ "$uuid" = "{$auto_uuid}" ]; then m_isRetainUserData=true fi diff --git a/backup-daemon/mybackupmanager.cpp b/backup-daemon/mybackupmanager.cpp index bb5a071..a2d521c 100755 --- a/backup-daemon/mybackupmanager.cpp +++ b/backup-daemon/mybackupmanager.cpp @@ -332,6 +332,10 @@ void MyBackupManager::autoBackUpForSystemUpdate_noreturn(const QString& autoback } backupWrapper.m_backupPaths << "/"; backupWrapper.m_backupExcludePaths = Utils::getFromExcludePathsFile(); + backupWrapper.m_backupExcludePaths << "/home"; + backupWrapper.m_backupExcludePaths << "/root"; + backupWrapper.m_backupExcludePaths << "/data/home"; + backupWrapper.m_backupExcludePaths << "/data/root"; backupWrapper.m_type = BackupType::BACKUP_SYSTEM; backupWrapper.m_iPosition = BackupPosition::LOCAL; backupWrapper.m_frontUserName = frontUserName; diff --git a/backup-daemon/parsebackuplist.cpp b/backup-daemon/parsebackuplist.cpp index 6208c58..e5cbbb7 100755 --- a/backup-daemon/parsebackuplist.cpp +++ b/backup-daemon/parsebackuplist.cpp @@ -299,7 +299,7 @@ void ParseBackupList::getCustomizePaths(QStringList &customizePaths) QDomElement elePrefixPath = node.firstChildElement(PREFIXDESTPATH); if (!elePrefixPath.isNull()) { - customizePaths << elePrefixPath.text(); + customizePaths << elePrefixPath.text() + BACKUP_SNAPSHOTS_PATH; } } }