Merge pull request #191 from jt70471/regex-patch-2

store compiled regex patterns for performance optimization
This commit is contained in:
gilbertchen
2017-09-18 22:46:12 -04:00
committed by GitHub
3 changed files with 46 additions and 19 deletions

View File

@@ -710,6 +710,8 @@ func restoreRepository(context *cli.Context) {
}
duplicacy.LOG_DEBUG("REGEX_DEBUG", "There are %d compiled regular expressions stored", len(duplicacy.RegexMap))
storage.SetRateLimits(context.Int("limit-rate"), 0)
backupManager := duplicacy.CreateBackupManager(preference.SnapshotID, storage, repository, password)
duplicacy.SavePassword(*preference, "password", password)