diff options
author | Soispha <soispha@vhack.eu> | 2023-10-08 13:12:44 +0200 |
---|---|---|
committer | Soispha <soispha@vhack.eu> | 2023-10-08 13:12:44 +0200 |
commit | 8fbcfc8698f97fc4701d09cb3de3e095d5ddd7c7 (patch) | |
tree | 90530153a36e969569115c6e06ea17c473826670 /hm/soispha/conf/nvim/plgs/debugprint/default.nix | |
parent | chore(version): v1.15.0 (diff) | |
download | nixos-config-8fbcfc8698f97fc4701d09cb3de3e095d5ddd7c7.zip |
fix(hm/conf/nvim): Update to new keymap format
Diffstat (limited to 'hm/soispha/conf/nvim/plgs/debugprint/default.nix')
-rw-r--r-- | hm/soispha/conf/nvim/plgs/debugprint/default.nix | 119 |
1 files changed, 58 insertions, 61 deletions
diff --git a/hm/soispha/conf/nvim/plgs/debugprint/default.nix b/hm/soispha/conf/nvim/plgs/debugprint/default.nix index 522965ac..b0d72339 100644 --- a/hm/soispha/conf/nvim/plgs/debugprint/default.nix +++ b/hm/soispha/conf/nvim/plgs/debugprint/default.nix @@ -12,66 +12,63 @@ pkgs.vimExtraPlugins.debugprint-nvim ]; - maps = let - visualNormal = { - "g?v" = { - action = '' - function() - return require('debugprint').debugprint({variable = true;}); - end - ''; - lua = true; - expr = true; - desc = '' - 'variable' debug line below the current line - ''; - }; - "g?V" = { - action = '' - function() - return require('debugprint').debugprint({above = true; variable = true;}) ; - end - ''; - lua = true; - expr = true; - desc = '' - 'variable' debug line above the current line - ''; - }; - }; - in { - normal = - { - "g?p" = { - action = '' - function() - return require('debugprint').debugprint(); - end - ''; - lua = true; - expr = true; - desc = '' - 'plain' debug line below the current line - ''; - }; - "g?P" = { - action = '' - function() - return require('debugprint').debugprint({above = true;}); - end - ''; - lua = true; - expr = true; - desc = '' - 'plain' debug line above the current line - ''; - }; - } - // visualNormal; - visual = - { - } - // visualNormal; - }; + keymaps = [ + { + key = "g?v"; + mode = ["v" "n"]; + action = '' + function() + return require('debugprint').debugprint({variable = true;}); + end + ''; + lua = true; + options.expr = true; + options.desc = '' + 'variable' debug line below the current line + ''; + } + { + key = "g?V"; + mode = ["v" "n"]; + action = '' + function() + return require('debugprint').debugprint({above = true; variable = true;}) ; + end + ''; + lua = true; + options.expr = true; + options.desc = '' + 'variable' debug line above the current line + ''; + } + { + key = "g?p"; + mode = "n"; + action = '' + function() + return require('debugprint').debugprint(); + end + ''; + lua = true; + options.expr = true; + options.desc = '' + 'plain' debug line below the current line + ''; + } + { + key = "g?P"; + mode = "n"; + action = '' + function() + return require('debugprint').debugprint({above = true;}); + end + ''; + lua = true; + options.expr = true; + options.desc = '' + 'plain' debug line above the current line + ''; + } + ]; }; } |