mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 14:40:12 +01:00
🎨 Support setting automatic sync interval https://github.com/siyuan-note/siyuan/issues/13448
This commit is contained in:
parent
152fa6e6e0
commit
45a6f7e29d
18 changed files with 100 additions and 12 deletions
|
|
@ -21,6 +21,7 @@ type Sync struct {
|
|||
Enabled bool `json:"enabled"` // 是否开启同步
|
||||
Perception bool `json:"perception"` // 是否开启感知
|
||||
Mode int `json:"mode"` // 同步模式,0:未设置(为兼容已有配置,initConf 函数中会转换为 1),1:自动,2:手动 https://github.com/siyuan-note/siyuan/issues/5089,3:完全手动 https://github.com/siyuan-note/siyuan/issues/7295
|
||||
Interval int `json:"interval"` // 自动同步间隔,单位:秒
|
||||
Synced int64 `json:"synced"` // 最近同步时间
|
||||
Stat string `json:"stat"` // 最近同步统计信息
|
||||
GenerateConflictDoc bool `json:"generateConflictDoc"` // 云端同步冲突时是否生成冲突文档
|
||||
|
|
@ -37,6 +38,7 @@ func NewSync() *Sync {
|
|||
Mode: 1,
|
||||
GenerateConflictDoc: false,
|
||||
Provider: ProviderSiYuan,
|
||||
Interval: 30,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue