Selaa lähdekoodia

:art: 退出时自动删除超过 7 天的安装包 Fix https://github.com/siyuan-note/siyuan/issues/6128

Liang Ding 2 vuotta sitten
vanhempi
commit
890bc3188d
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      kernel/model/conf.go

+ 2 - 2
kernel/model/conf.go

@@ -614,10 +614,10 @@ func clearWorkspaceTemp() {
 	os.RemoveAll(filepath.Join(util.TempDir, "repo"))
 	os.RemoveAll(filepath.Join(util.TempDir, "repo"))
 	os.RemoveAll(filepath.Join(util.TempDir, "os"))
 	os.RemoveAll(filepath.Join(util.TempDir, "os"))
 
 
-	// 退出时自动删除超过 30 天的安装包 https://github.com/siyuan-note/siyuan/issues/5957
+	// 退出时自动删除超过 7 天的安装包 https://github.com/siyuan-note/siyuan/issues/6128
 	install := filepath.Join(util.TempDir, "install")
 	install := filepath.Join(util.TempDir, "install")
 	if gulu.File.IsDir(install) {
 	if gulu.File.IsDir(install) {
-		monthAgo := time.Now().Add(-time.Hour * 24 * 30)
+		monthAgo := time.Now().Add(-time.Hour * 24 * 7)
 		entries, err := os.ReadDir(install)
 		entries, err := os.ReadDir(install)
 		if nil != err {
 		if nil != err {
 			logging.LogErrorf("read dir [%s] failed: %s", install, err)
 			logging.LogErrorf("read dir [%s] failed: %s", install, err)