diff options
Diffstat (limited to 'lua/conform')
-rw-r--r-- | lua/conform/health.lua | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lua/conform/health.lua b/lua/conform/health.lua index 3a1c9f6..bf7f51c 100644 --- a/lua/conform/health.lua +++ b/lua/conform/health.lua @@ -87,7 +87,12 @@ M.show_window = function() if vim.fn.filereadable(logfile) == 1 then local f = io.open(logfile, "r") if f then - f:seek("end", -1024) + local context = -1024 + -- Show more logs if the log level is set to trace. + if log.level == vim.log.levels.TRACE then + context = 3 * context + end + f:seek("end", context) local text = f:read("*a") f:close() local log_lines = vim.split(text, "\n", { plain = true, trimempty = true }) |