feat: add logger (#64)
* refactor(health): keep in mind new way of health check (#63) * feat(log): add logger module * refactor(utils): remove unused code * refactor(log, utils): get plugin name from config * refactor(logger): add some type annotations * refactor(utils): log notifications * feat: LOGGER™ * feat(config): TYPES * refactor(log): dont give a thing about var that is not even declared * feat(log): add easy way to open log * refactor(log): some types * update types * docs: regen * fix(log): make setting log level by config work * feat(iferr): write error to log file if occur * feat(gotests): add logger
This commit is contained in:
parent
65fa148661
commit
fbf6441f3d
10 changed files with 213 additions and 31 deletions
|
|
@ -20,13 +20,15 @@ Table of Contents
|
|||
|
||||
------------------------------------------------------------------------------
|
||||
*gopher.nvim-setup*
|
||||
`gopher.setup`
|
||||
`gopher.setup`({user_config})
|
||||
Setup function. This method simply merges default configs with opts table.
|
||||
You can read more about configuration at |gopher.nvim-config|
|
||||
Calling this function is optional, if you ok with default settings. Look |gopher.nvim.config-defaults|
|
||||
|
||||
Usage ~
|
||||
`require("gopher").setup {}` (replace `{}` with your `config` table)
|
||||
Parameters ~
|
||||
{user_config} gopher.Config
|
||||
|
||||
------------------------------------------------------------------------------
|
||||
*gopher.nvim-install-deps*
|
||||
|
|
@ -50,6 +52,10 @@ You can look at default options |gopher.nvim-config-defaults|
|
|||
local default_config = {
|
||||
--minidoc_replace_end
|
||||
|
||||
-- log level, you might consider using DEBUG or TRACE for degugging the plugin
|
||||
---@type number
|
||||
log_level = vim.log.levels.INFO,
|
||||
|
||||
-- user specified paths to binaries
|
||||
---@class gopher.ConfigCommand
|
||||
commands = {
|
||||
|
|
@ -81,12 +87,6 @@ You can look at default options |gopher.nvim-config-defaults|
|
|||
Class ~
|
||||
{gopher.Config}
|
||||
|
||||
------------------------------------------------------------------------------
|
||||
*config.setup()*
|
||||
`config.setup`({user_config})
|
||||
Parameters ~
|
||||
{user_config} `(optional)` gopher.Config
|
||||
|
||||
|
||||
==============================================================================
|
||||
------------------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue