Skip to content

paulfrische/mode.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Mode.nvim

Group keybinds together and enable/disable them on the fly

What?

This plugin allows you to easily build your own modes. It is heavily inspired by stackmap.nvim.

Why?

You could build a "debugging-mode" for example so you don't clutter your keymap with keybinds you don't use when not debugging

require('mode').add('n', 'Debugging', {
  ['<leader>b'] = require'dap'.toggle_breakpoint,
  ['<leader>c'] = require'dap'.continue,
  ['<leader>so'] = require'dap'.step_over,
  ['<leader>si'] = require'dap'.step_into,
  ['<leader>ro'] = require'dap'.repl.open,
})

which could be dynamically activated and deactivated by using the on and off functions:

-- activate
require('mode').on('Debugging')

-- deactivate when finished with debugging
require('mode').off('Debugging')

This plugin is:

  • 🐒 easy to use
  • 🪨 small and stupid
  • 🚀 BLAZINGLY FAST (I think)

Why Not?

I am very new to plugin development so there is a good chance that this plugin contains some nasty bugs.

Alternatives

Here are some alternatives:

About

Group keybinds together and enable/disable them on the fly

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages