我正在尝试使用https://github.com/ptaoussanis/timbre登录到文件而不是控制台。这是我找到的一些有关如何执行此操作的文档:
; The default setup is simple console logging. We with to turn off console logging and
; turn on file logging to our chosen filename.
(timbre/set-config! [:appenders :standard-out :enabled?] false)
(timbre/set-config! [:appenders :spit :enabled?] true)
(timbre/set-config! [:shared-appender-config :spit-filename] log-file-name)
(timbre/set-config! [:shared-appender-config :spit-filename] log-file-name)
这适用于以前版本的 sente,但不适用于版本 [com.taoensso/timbre "4.3.1"]。(出于不相关的原因,我需要使用最新的)。上面代码的问题是set-config!
现在需要一个参数 - 哈希映射。而且我找不到任何可以帮助我将上述“两个参数”代码转换为新的“一个参数”代码的文档。