mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🎨 加入升级信息日志
This commit is contained in:
parent
81fa346073
commit
9ce3cb75c6
1 changed files with 7 additions and 1 deletions
|
|
@ -19,7 +19,6 @@ package model
|
||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/88250/lute/ast"
|
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"runtime"
|
"runtime"
|
||||||
|
|
@ -31,6 +30,7 @@ import (
|
||||||
|
|
||||||
"github.com/88250/gulu"
|
"github.com/88250/gulu"
|
||||||
"github.com/88250/lute"
|
"github.com/88250/lute"
|
||||||
|
"github.com/88250/lute/ast"
|
||||||
"github.com/Xuanwo/go-locale"
|
"github.com/Xuanwo/go-locale"
|
||||||
humanize "github.com/dustin/go-humanize"
|
humanize "github.com/dustin/go-humanize"
|
||||||
"github.com/getsentry/sentry-go"
|
"github.com/getsentry/sentry-go"
|
||||||
|
|
@ -40,6 +40,7 @@ import (
|
||||||
"github.com/siyuan-note/siyuan/kernel/sql"
|
"github.com/siyuan-note/siyuan/kernel/sql"
|
||||||
"github.com/siyuan-note/siyuan/kernel/treenode"
|
"github.com/siyuan-note/siyuan/kernel/treenode"
|
||||||
"github.com/siyuan-note/siyuan/kernel/util"
|
"github.com/siyuan-note/siyuan/kernel/util"
|
||||||
|
"golang.org/x/mod/semver"
|
||||||
"golang.org/x/text/language"
|
"golang.org/x/text/language"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -213,6 +214,11 @@ func InitConf() {
|
||||||
Conf.System = conf.NewSystem()
|
Conf.System = conf.NewSystem()
|
||||||
Conf.OpenHelp = true
|
Conf.OpenHelp = true
|
||||||
} else {
|
} else {
|
||||||
|
if 0 < semver.Compare("v"+util.Ver, "v"+Conf.System.KernelVersion) {
|
||||||
|
logging.LogInfof("upgraded from version [%s] to [%s]", Conf.System.KernelVersion, util.Ver)
|
||||||
|
} else {
|
||||||
|
logging.LogInfof("downgraded from version [%s] to [%s]", Conf.System.KernelVersion, util.Ver)
|
||||||
|
}
|
||||||
Conf.OpenHelp = Conf.System.KernelVersion != util.Ver
|
Conf.OpenHelp = Conf.System.KernelVersion != util.Ver
|
||||||
Conf.System.KernelVersion = util.Ver
|
Conf.System.KernelVersion = util.Ver
|
||||||
Conf.System.IsInsider = util.IsInsider
|
Conf.System.IsInsider = util.IsInsider
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue