diff options
author | Grail Finder <wohilas@gmail.com> | 2024-11-20 13:21:51 +0300 |
---|---|---|
committer | Grail Finder <wohilas@gmail.com> | 2024-11-20 13:21:51 +0300 |
commit | 8ae4d075c4d043eae604af9cad0cf5e571420a61 (patch) | |
tree | 3b0eb7689a598e25dac67d889e037f3bc08c19a1 /bot.go | |
parent | 74669b58fe7b58b3d2fd4ad88c03890bc53a7a1a (diff) |
Feat: migration on startup
Diffstat (limited to 'bot.go')
-rw-r--r-- | bot.go | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -276,10 +276,9 @@ func init() { if err := os.MkdirAll(historyDir, os.ModePerm); err != nil { panic(err) } - store = storage.NewProviderSQL("test.db") - // defer file.Close() logger = slog.New(slog.NewTextHandler(file, nil)) logger.Info("test msg") + store = storage.NewProviderSQL("test.db", logger) // https://github.com/coreydaley/ggerganov-llama.cpp/blob/master/examples/server/README.md // load all chats in memory loadHistoryChats() |