🎨 Ignore hidden files when generating asset history https://github.com/siyuan-note/siyuan/issues/11253

This commit is contained in:
Daniel 2024-05-05 17:14:36 +08:00
parent 73790cca17
commit b5289208a7
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
3 changed files with 20 additions and 16 deletions

View file

@ -633,7 +633,11 @@ func recentModifiedAssets() (ret []string) {
assets := cache.GetAssets()
for _, asset := range assets {
if asset.Updated > assetsLatestHistoryTime {
ret = append(ret, filepath.Join(util.DataDir, asset.Path))
absPath := filepath.Join(util.DataDir, asset.Path)
if filelock.IsHidden(absPath) {
continue
}
ret = append(ret, absPath)
}
}
assetsLatestHistoryTime = time.Now().Unix()