File logging (#1053)
* add file logging infrastructure * log git runner operations * log configuration and mappings * document file logging infrastructure * style fixes * stylua fixes * document log file locations
This commit is contained in:
committed by
GitHub
parent
0816064a8b
commit
19075f41e8
@@ -2,6 +2,7 @@ local luv = vim.loop
|
||||
local api = vim.api
|
||||
|
||||
local lib = require "nvim-tree.lib"
|
||||
local log = require "nvim-tree.log"
|
||||
local colors = require "nvim-tree.colors"
|
||||
local renderer = require "nvim-tree.renderer"
|
||||
local view = require "nvim-tree.view"
|
||||
@@ -390,6 +391,14 @@ local DEFAULT_OPTS = {
|
||||
},
|
||||
},
|
||||
},
|
||||
log = {
|
||||
enable = false,
|
||||
types = {
|
||||
all = false,
|
||||
config = false,
|
||||
git = false,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
local function merge_options(conf)
|
||||
@@ -415,6 +424,11 @@ function M.setup(conf)
|
||||
|
||||
manage_netrw(opts.disable_netrw, opts.hijack_netrw)
|
||||
|
||||
require("nvim-tree.log").setup(opts)
|
||||
|
||||
log.line("config", "default config + user")
|
||||
log.raw("config", "%s\n", vim.inspect(opts))
|
||||
|
||||
require("nvim-tree.actions").setup(opts)
|
||||
require("nvim-tree.colors").setup()
|
||||
require("nvim-tree.diagnostics").setup(opts)
|
||||
|
||||
Reference in New Issue
Block a user