Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: Support local file system sync & backup https://github.com/siyuan-note/siyuan/pull/13663

Daniel278a8f127d48
diff --git a/kernel/model/sync.go b/kernel/model/sync.go
index 51522f3805..8aedef9827 100644
--- a/kernel/model/sync.go
+++ b/kernel/model/sync.go
@@ -483,13 +483,13 @@ func SetSyncProviderLocal(local *conf.Local) (err error) {
return
}
if !gulu.File.IsExist(absPath) {
- msg := fmt.Sprintf("endpoint [%s] not exist", local.Endpoint+" ("+absPath+")")
+ msg := fmt.Sprintf("endpoint [%s] not exist", local.Endpoint)
logging.LogErrorf(msg)
err = errors.New(fmt.Sprintf(Conf.Language(77), msg))
return
}
- if util.IsAbsPathInWorkspace(absPath) {
- msg := fmt.Sprintf("endpoint [%s] is in workspace", local.Endpoint+" ("+absPath+")")
+ if util.IsAbsPathInWorkspace(absPath) || filepath.Clean(absPath) == filepath.Clean(util.WorkspaceDir) {
+ msg := fmt.Sprintf("endpoint [%s] is in workspace", local.Endpoint)
logging.LogErrorf(msg)
err = errors.New(fmt.Sprintf(Conf.Language(77), msg))
return