From 200499aad41ce589a86688b025c904c6152094e9 Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Fri, 16 Jun 2023 09:18:44 +0800 Subject: [PATCH] :art: Improve boot --- kernel/model/conf.go | 3 +++ kernel/util/pandoc.go | 2 +- kernel/util/tesseract.go | 2 +- kernel/util/working.go | 2 -- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/kernel/model/conf.go b/kernel/model/conf.go index 2de6e212d..e5bb9f268 100644 --- a/kernel/model/conf.go +++ b/kernel/model/conf.go @@ -389,6 +389,9 @@ func InitConf() { } util.SetNetworkProxy(Conf.System.NetworkProxy.String()) + + go util.InitPandoc() + go util.InitTesseract() } func initLang() { diff --git a/kernel/util/pandoc.go b/kernel/util/pandoc.go index ca8f3279e..845bb0484 100644 --- a/kernel/util/pandoc.go +++ b/kernel/util/pandoc.go @@ -82,7 +82,7 @@ var ( PandocBinPath string // Pandoc 可执行文件路径 ) -func initPandoc() { +func InitPandoc() { if ContainerStd != Container { return } diff --git a/kernel/util/tesseract.go b/kernel/util/tesseract.go index 058b93061..13ac6ed00 100644 --- a/kernel/util/tesseract.go +++ b/kernel/util/tesseract.go @@ -129,7 +129,7 @@ func Tesseract(imgAbsPath string) string { return ret } -func initTesseract() { +func InitTesseract() { ver := getTesseractVer() if "" == ver { return diff --git a/kernel/util/working.go b/kernel/util/working.go index e4d5d6be2..b235e6a86 100644 --- a/kernel/util/working.go +++ b/kernel/util/working.go @@ -110,8 +110,6 @@ func Boot() { } initPathDir() - go initPandoc() - go initTesseract() bootBanner := figure.NewColorFigure("SiYuan", "isometric3", "green", true) logging.LogInfof("\n" + bootBanner.String())