🎨 云端同步发生冲突时生成副本 https://github.com/siyuan-note/siyuan/issues/5687

This commit is contained in:
Liang Ding 2022-08-21 13:01:54 +08:00
parent 8ee5c07231
commit 581c1b4942
No known key found for this signature in database
GPG key ID: 136F30F901A2231D
7 changed files with 110 additions and 62 deletions

View file

@ -36,8 +36,7 @@ import (
"github.com/siyuan-note/logging"
)
//var Mode = "dev"
//
// var Mode = "dev"
var Mode = "prod"
const (
@ -267,6 +266,7 @@ func initWorkspaceDir(workspaceArg string) {
if err := os.MkdirAll(osTmpDir, 0755); nil != err {
log.Fatalf("create os tmp dir [%s] failed: %s", osTmpDir, err)
}
os.RemoveAll(filepath.Join(TempDir, "repo"))
os.Setenv("TMPDIR", osTmpDir)
os.Setenv("TEMP", osTmpDir)
os.Setenv("TMP", osTmpDir)