mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-31 05:48:49 +01:00
⚡ 优化云端同步上传资源占用 https://github.com/siyuan-note/siyuan/issues/5093
This commit is contained in:
parent
bceb37b108
commit
207e83a05b
3 changed files with 122 additions and 59 deletions
|
|
@ -278,7 +278,7 @@ func CreateLocalBackup() (err error) {
|
|||
return
|
||||
}
|
||||
|
||||
err = genCloudIndex(newBackupDir, map[string]bool{})
|
||||
err = genFullCloudIndex(newBackupDir, map[string]bool{})
|
||||
if nil != err {
|
||||
return
|
||||
}
|
||||
|
|
@ -364,7 +364,7 @@ func UploadBackup() (err error) {
|
|||
util.PushEndlessProgress(Conf.Language(61))
|
||||
util.LogInfof("uploading backup...")
|
||||
start := time.Now()
|
||||
wroteFiles, transferSize, err := ossUpload(localDirPath, "backup", "", false)
|
||||
wroteFiles, transferSize, err := ossUpload(localDirPath, "backup", "not exist", false, map[string]bool{}, map[string]bool{})
|
||||
if nil == err {
|
||||
elapsed := time.Now().Sub(start).Seconds()
|
||||
util.LogInfof("uploaded backup [wroteFiles=%d, transferSize=%s] in [%.2fs]", wroteFiles, humanize.Bytes(transferSize), elapsed)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue