diff --git a/lua/gopher/_utils/init.lua b/lua/gopher/_utils/init.lua index d78ea86..a3b567c 100644 --- a/lua/gopher/_utils/init.lua +++ b/lua/gopher/_utils/init.lua @@ -9,7 +9,7 @@ function utils.deferred_notify(msg, lvl) vim.notify(msg, lvl, { title = c.___plugin_name, }) - log.info(msg) + log.debug(msg) end, 0) end @@ -20,7 +20,7 @@ function utils.notify(msg, lvl) vim.notify(msg, lvl, { title = c.___plugin_name, }) - log.info(msg) + log.debug(msg) end -- safe require diff --git a/lua/gopher/comment.lua b/lua/gopher/comment.lua index 002894c..8754405 100644 --- a/lua/gopher/comment.lua +++ b/lua/gopher/comment.lua @@ -3,6 +3,8 @@ ---@usage Execute `:GoCmt` to generate a comment for the current function/method/struct/etc on this line. ---@text This module provides a way to generate comments for Go code. +local log = require "gopher._utils.log" + local function generate(row, col) local ts_utils = require "gopher._utils.ts" local comment, ns = nil, nil @@ -38,6 +40,8 @@ return function() local row, col = unpack(vim.api.nvim_win_get_cursor(0)) local comment, ns = generate(row + 1, col + 1) + log.debug("generated comment: " .. comment) + vim.api.nvim_win_set_cursor(0, { ns.dim.s.r, ns.dim.s.c,