andrewferrier / debugprint.nvim

Debugging in NeoVim the print() way!
MIT License
313 stars 17 forks source link

How to use <leader> in keymaps #111

Closed nobleach closed 2 months ago

nobleach commented 2 months ago

With the previous versions this plugin was using NeoVim's default keymaps with global functions. I realize this package now uses its own internal keymap functionality:

    opts = {
        keymaps = {
            normal = {
                plain_below = "g?p",
                plain_above = "g?P",
                variable_below = "g?v",
                variable_above = "g?V",

I've tried using variable_below = "<leader>cl", but it doesn't seem to work. Is there some other way?

andrewferrier commented 2 months ago

@nobleach thanks for spotting this. This was due to a recent change I made where I clumsily defaulted to lazy-loading by mistake. I've put in a temporary workaround for this, so if you pull the latest version, this should start working.

I'll work on a more permanent fix later.

andrewferrier commented 2 months ago

(Note to self: add tests for this also using lazy)

nobleach commented 2 months ago

The temporary workaround appears to work. Thank you for looking at it!

andrewferrier commented 2 months ago

Thanks, re-opening just because I want to fix it properly :)

nobleach commented 2 months ago

Understandable. Thanks again.